Week 7 - Dependency Issues 1/2
06 Jul 2014The next time an interviewer asks me about one of my hardest bugs, I will tell her the story of my last week.
I was trying to integrate my first optaplanner solution for the operation theater scheduling problem into my openmrs module. The unit and integration tests were working perfectly. The problem began as I tried to invoke the solver from an openmrs webpage. I was confronted with various exceptions regarding slf4j library. I could resolve that by excluding all libraries from optaplanner that are provided by openmrs-core. Confident that I would be able to see some scheduling results in my calendar soon I redeployed my module. To my surprise an ArrayOutOfBoundsException was thrown during compilation of the drl file.
This stacktrace occupied me for several days. I had a look at version numbers of the libraries provided by openmrs and the ones that optaplanner depends on. There was a mismatch and I guessed that this is the reason for this error. After creating a separate project (without openmrs) but the same library versions, I found out that I was wrong. To my surprise it was working.
After comparing all dependencies between openmrs and optaplanner and trying out every configuration I could think of, I haven’t moved forward at all.
To be continued tomorrow…