Sometimes Java seems like a hack

Posted on March 9, 2006

I am using Java RMI to do the main IPC work for me, in a distributed number crunching application. Now the reason I’m using Java for this is another story, for another time. So, like any good developer I’ve got plenty of test cases, but one of them just never seemed to exit. So I fired it up in Eclipse and paused the execution when it should have been finished, and what did I find? 1/2 a dozen RMI related threads. But I unexported the objects, and cleaned everything up… Well according to this that isn’t enough. The only way to fully shutdown an RMI server is with System.exit(0).

Why? did the implementation get too tricky, and they decided to leave the cleanup to the operating system? Oh well, lets see if we can drop RMI now! I hear Jini is good. I just hope it doesn’t inherit this same problem.