I’ve got a somewhat odd problem that I’ve run across with a custom Servoy plugin I’ve developed, and I was wondering if anyone might be able to shed any light on what might be going wrong or how I could debug it.
Basically, the plugin in question uses the eBay Java SDK, and hence includes the Apache Jakarta lib and AXIS as part of the JAR file. This has worked fine until very recently, but one of either the Mac OS Java update or Servoy update to 3.5.10 has caused something to break.
The symptoms I get post-update are that Servoy (Developer) itself loads, but hangs on the splash screen with “Application Server Init” in the status panel. The system log reports that the VM has run out of memory (log below). Increasing the -Xmx and --launcher.XXMaxPermSize makes the problem take slightly longer to appear (as in it gets as far as “Opening Solution”), but it seems that something is simply eating memory at a colossal rate because even with a couple of Gb available it still dies before getting beyond the loading phase.
Now, what’s curious about this is that if I go into my JAR builder script and remove the Apache libraries, everything works fine - memory usage is within normal bounds, the solution works perfectly… the only hiccup is that (for obvious reasons) my plugin fails when it’s invoked as the libraries aren’t there. The plugin itself just exports a couple of JS functions, so it shouldn’t be doing anything other than the boilerplate plugin init code on startup - certainly nothing that would consume large amounts of RAM, as far as I know.
Suspecting that AXIS might be the problem in some fashion (version-clash?), I tried upgrading to the latest eBay SDK which uses JAXWS, but with exactly the same results. Has anyone got any suggestions as to what might be going wrong here? I’m at a bit of a loss as to why things should suddenly break, or indeed how to debug them since the problem appears to be an incompatibility between Servoy and the libraries, neither of which I can really meaningfully poke about in… any ideas would be greatly appreciated!
Thanks!
Here’s the stack trace from the out-of-memory error:
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: java.lang.reflect.InvocationTargetException
May 30 22:49:09: --- last message repeated 1 time ---
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at java.lang.reflect.Method.invoke(Method.java:597)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at com.servoy.j2db.startup.Bootstrap.main(Unknown Source)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at java.lang.reflect.Method.invoke(Method.java:597)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at apple.launcher.LaunchRunner.run(LaunchRunner.java:115)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at apple.launcher.LaunchRunner.callMain(LaunchRunner.java:50)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at apple.launcher.JavaApplicationLauncher.launch(JavaApplicationLauncher.java:52)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: Caused by: java.lang.OutOfMemoryError: PermGen space
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at java.lang.Class.forName0(Native Method)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at java.lang.Class.forName(Class.java:169)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at sun.security.x509.OIDMap$OIDInfo.getClazz(OIDMap.java:190)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at sun.security.x509.OIDMap.getClass(OIDMap.java:273)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at sun.security.x509.CertificateExtensions.parseExtension(CertificateExtensions.java:79)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at sun.security.x509.CertificateExtensions.init(CertificateExtensions.java:70)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at sun.security.x509.CertificateExtensions.<init>(CertificateExtensions.java:60)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at sun.security.x509.X509CertInfo.parse(X509CertInfo.java:723)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at sun.security.x509.X509CertInfo.<init>(X509CertInfo.java:152)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at sun.security.x509.X509CertImpl.parse(X509CertImpl.java:1729)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at sun.security.x509.X509CertImpl.<init>(X509CertImpl.java:179)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at sun.security.provider.X509Factory.engineGenerateCertificate(X509Factory.java:90)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at java.security.cert.CertificateFactory.generateCertificate(CertificateFactory.java:305)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at sun.security.provider.JavaKeyStore.engineLoad(JavaKeyStore.java:746)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at sun.security.provider.JavaKeyStore$JKS.engineLoad(JavaKeyStore.java:38)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at java.security.KeyStore.load(KeyStore.java:1185)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at com.sun.net.ssl.internal.ssl.TrustManagerFactoryImpl.getCacertsKeyStore(TrustManagerFactoryImpl.java:202)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at com.sun.net.ssl.internal.ssl.TrustManagerFactoryImpl.engineInit(TrustManagerFactoryImpl.java:31)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at javax.net.ssl.TrustManagerFactory.init(TrustManagerFactory.java:230)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at com.sun.net.ssl.internal.ssl.SSLContextImpl.engineInit(SSLContextImpl.java:54)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at javax.net.ssl.SSLContext.init(SSLContext.java:248)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at com.servoy.j2db.util.SecuritySupport.getSSLContext(Unknown Source)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at com.servoy.j2db.util.SecuritySupport.getSSLServerSocketFactory(Unknown Source)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at com.servoy.j2db.server.ApplicationServer.a(Unknown Source)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at com.servoy.j2db.server.ApplicationServer.initFromDeveloper(Unknown Source)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at com.servoy.j2db.develop.J2DBDeveloper.dataBaseInit(Unknown Source)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at com.servoy.j2db.develop.J2DBDeveloper.if(Unknown Source)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at com.servoy.j2db.develop.J2DBDeveloper.main(Unknown Source)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
May 30 22:49:09 Kotoko [0x0-0x48c48c].SRVY[70410]: at java.lang.reflect.Method.invoke(Method.java:597)
May 30 22:49:11 Kotoko [0x0-0x48c48c].SRVY[70410]: Exception in thread "AWT-EventQueue-0" java.lang.OutOfMemoryError: PermGen space