Code runs on code

This semester has been a rather hectic one. There is this massive Java Enterprise project that lasts throughout the entire semester. In the midst of this project, our team encountered a rather puzzling bug. Despite following the sample code snippets closely and trawling through Stack Overflow, we were unable to rectify the bug. The stack traces was of no use as well, none of the functions referenced were coded by us. Stumped, we decided to consult our lecturer who spent a considerable amount of time trying to debug and eventually suggested that we update our JDK as a last resort.

Lo and behold, the bug was with the JDK itself. Let me first qualify that we were not using an archaic version of Java released many years ago but JDK 8u5 which was released barely 5 months ago. The update to JDK 8u20 fixed the bug. It was a relatively obscure bug involving passing a long/int as a parameter to a remote interface via RMI which caused a CORBA marshalling exception.

This episode serves as a timely reminder for me that code runs on code. The methods that we rely heavily on are written by programmers who do make mistakes as well. Often times, I treat them as a black box, simply calling the methods and expecting to receive the output specified in the API. I assume that all bugs must be a result of a mistake on my part. After this episode, I would be adding an additional step into my debugging routine. If all else fails, update the SDK. If all else fails again, file a bug report?