Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6579857
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T15:57:03+00:00 2026-05-25T15:57:03+00:00

I have a simple test run of some medium-complexity code that won’t terminate, i.e.

  • 0

I have a simple test run of some medium-complexity code that won’t terminate, i.e. the main method finishes but the process does not die.

Here is a rundown of the code (which is too long to be pasted here):

  • ProcessBuilder is used to create a bunch of subprocesses. They all die properly (if you can believe VisualVM).
  • We use log4j.
  • The main algorithm runs inside a FutureTask on which run and later get are called.
  • We don’t explicitly use RMI, even though the list of threads seems to suggest so.

Obviously, I can call System.exit(0), but I’d like to know what is amiss here. I have not been able to produce a minimum failing example. Also, I can not identify an obvious culprit from the thread list; maybe you can?

from VisualVM after main terminates

Edit: See here for a thread dump.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-25T15:57:03+00:00Added an answer on May 25, 2026 at 3:57 pm

    Scorpion lead me to the right answer:

    RMI Reaper is something like a garbage collector for remote objects, e.g. instances of (subclasses of) UnicastRemoteObject. It is a non-daemon thread and therefore blocks JVM termination if there are still exported objects which can not be cleaned up.

    You can explicity force remote objects to be cleaned up in this sense by passing them to UnicastRemoteObject.unexportObject(., true). If you do this on all previously exported objects, RMI Reaper terminates and JVM is free to shut down.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have some simple test code which I am trying to generate AVX optimized
I have a simple test bash script which looks like that: #!/bin/bash cmd=rsync -rv
I have a simple test application (C# console application) that does an HTTP GET
I have a simple little test app written in Flex 3 (MXML and some
I have a very simple test page that uses XHR requests with jQuery's $.getJSON
I've been writing some simple test cases for one of my assignments, and have
use case is simple: I want to run some boiler plate code before each
I have this simple test project just to test the IncludeExceptionDetailInFaults behavior. public class
I have created a simple test form with FormBorderStyle = FixedToolWindow by default and
I have a simple unit test case (extensive question here ) on a configuration

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.