JavaOne 2007 is History; so back to Work
After I could build the bundle and the repository I am now able to do what I wanted to do a year ago. Bug 6313849 is an enhancement request to add a disconnect() method to the URLConnection class so that one can close any URLConnection without having to know which protocol is used and without any fancy upcasts. This is a generalization of my previous contribution to the JDK and so I wanted to tackle it a long time ago but never found time to go through the hassle of building the entire JDK.
So far I went through all the different sub classes of URLConnection and implemented the disconnect() method. Then I needed to create a test with jtreg which is not that trivial. The first problem is to decide where to place it. I could add it to the URLConnection or to the sub classes. I would thing it would make more sense to place it with the sub classes but I am not quite sure. Then I don't know if the test should be named after the bug number or after the newly added method disconnect.
If that is successful then I can send a patch to Sun so that they can evaluate and test it. So far so good but the entire experience with building the JDK and then go through the contribution process as of now is not very satisfying. First I had to build the entire JDK including the JVM etc even though I was only working on the Java source files. After the changes I had to execute a rebuilt and even though I tried to do that only inside the J2SE folder it deleted the entire build directory forcing a total rebuilt including the JVM etc. This is not very user friendly and will discourage some developers to start working on the JDK. A solution to this problem is to create a separate built system only for the Java source using most likely Ant so that I can rebuilt on the part I need speeding up a build cycle quite a lot. Together with a binary build snapshot of OpenJDK we can free the developers from building the whole enchillada if they are only interested in the Java code.
Have fun - Andy