I am developing a SOE for ArcGIS Server 10 SP 5 in Java. The SOE makes use of some GeoTools functionality - specifically the HeatmapProcess.
I have written a small api (with all GeoTools, no ArcObjects) and packaged it as a standalone jar. The standalone jar works perfect in projects outside of ArcGIS Server. However, when used inside the SOE, I am eventually get hit with a "Provider com.sun.media.jai.imageioimpl.ImageReadWriteSpi not found" error message.
I am traditionally a .NET guy, so Java's class loading mechanisms are a little alien to me. I am fairly confident I have the class-path of my SOE set properly - as all other GeoTools classes instantiate just fine. Looking at the ESRI install, I can see that some version of JAI is included in the java/lib/shared directory - but it is an older version than what I have included in the class-path of my SOE.
Again admitting my lack of knowledge about all things Java to include the JVM, I am assuming that the version of JAI shipped with ArcGIS Server is taking precedence over the version I have included in the class-path of my SOE - through how ArcGIS Server starts the JVM.
So I have a couple of questions for you Java guru's out there:
- Is there some way I can update the version of JAI loaded by ArcGIS Server?
- Is there some way I can make ArcGIS Server start the JVM giving precedence to the class-path I define?