facebook

XFire on JRockit

  1. MyEclipse Archived
  2.  > 
  3. Web Services
Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #271112 Reply

    djheath
    Member

    I have successfully deployed an XFire web service that connects to an Oracle 10g database through hibernate, using the Sun JRE 1.5.0_10. It works on both Windows and 32-bit Linux.

    Our production environment, however, uses JRockit-R27.2.0-jdk1.5.0_10 and I’m finding that Tomcat core dumps when trying to start my web service. This happens on 32-bit Linux, 64-bit Linux and Windows XP.

    Stack trace:

    5d090000-5d129fff C:\WINDOWS\system32\comctl32.dll
    00860000-00adcfff *D:\Program Files\Java\jrockit-R27.2.0-jre1.6.0\bin\jrockit\jvm.dll
    76b40000-76b6cfff C:\WINDOWS\system32\WINMM.dll
    71ab0000-71ac6fff C:\WINDOWS\system32\WS2_32.dll
    71aa0000-71aa7fff C:\WINDOWS\system32\WS2HELP.dll
    7c340000-7c395fff C:\WINDOWS\system32\MSVCR71.dll
    77fe0000-77ff0fff C:\WINDOWS\system32\Secur32.dll
    6d820000-6d82bfff D:\Program Files\Java\jrockit-R27.2.0-jre1.6.0\bin\verify.dll
    6d460000-6d47efff D:\Program Files\Java\jrockit-R27.2.0-jre1.6.0\bin\java.dll
    6d3c0000-6d3c7fff D:\Program Files\Java\jrockit-R27.2.0-jre1.6.0\bin\hpi.dll
    6d860000-6d86efff D:\Program Files\Java\jrockit-R27.2.0-jre1.6.0\bin\zip.dll
    6d620000-6d632fff D:\Program Files\Java\jrockit-R27.2.0-jre1.6.0\bin\net.dll
    31480000-314effff C:\WINDOWS\system32\bmnet.dll
    71a50000-71a8efff C:\WINDOWS\system32\mswsock.dll
    662b0000-66307fff C:\WINDOWS\system32\hnetcfg.dll
    71a90000-71a97fff C:\WINDOWS\System32\wshtcpip.dll
    76bf0000-76bfafff C:\WINDOWS\system32\psapi.dll
    74720000-7476afff C:\WINDOWS\system32\MSCTF.dll
    605d0000-605d8fff C:\WINDOWS\system32\mslbui.dll
    77120000-771abfff C:\WINDOWS\system32\OLEAUT32.DLL
    774e0000-7761cfff C:\WINDOWS\system32\ole32.dll
    32060000-32114fff C:\WINDOWS\system32\bmutil.dll
    77c00000-77c07fff C:\WINDOWS\system32\VERSION.dll
    32220000-32332fff D:\Program Files\Java\jrockit-R27.2.0-jre1.6.0\bin\dbghelp.dll

    “Thread-1” id=12 idx=0x34 tid=2996 lastJavaFrame=0x3103E1AC

    Stack 0: start=0x31000000, end=0x31040000, guards=0x31003000 (ok), forbidden=0x31001000
    Thread Stack Trace:
    at _dynArrayGetPtr+8()@0x00A0A778
    at _bcFinishLocalVarTables+65()@0x009A5BE1
    at _bcFinishLocalVarTables+3131()@0x009A67DB
    at _bcParseMethods+656()@0x009A6D90
    at _bcFinishAttribute+3729()@0x009A34D1
    at _bcCheckValidClassName+138()@0x0086A14A
    at _bc2Class+217()@0x0086A309
    at _defineClass0+89()@0x0089D5A9
    at _defineClass+151()@0x0089D697
    at _libSetCurrentDefining+82()@0x009452E2
    at _libDefineClass+38()@0x00945526
    at _libDefineClass2+58()@0x0094565A
    at _JVM_DefineClassWithSource@28+43()@0x0091957B
    at _Java_java_lang_ClassLoader_defineClass1@32+235()@0x6D4615DA
    — Java stack —
    at java/lang/ClassLoader.defineClass1(Ljava/lang/String;[BIILjava/security/ProtectionDomain;Ljava/lang/String;)Ljava/lang/Class;
    (Native Method)
    at java/lang/ClassLoader.defineClass(ClassLoader.java:620)
    at java/security/SecureClassLoader.defineClass(SecureClassLoader.java:124)
    at org/apache/catalina/loader/WebappClassLoader.findClassInternal(WebappClassLoader.java:1847)
    ^– Holding lock: org/apache/catalina/loader/WebappClassLoader@0x03A88718[thin lock]
    at org/apache/catalina/loader/WebappClassLoader.findClass(WebappClassLoader.java:873)
    at org/apache/catalina/loader/WebappClassLoader.loadClass(WebappClassLoader.java:1326)
    at org/apache/catalina/loader/WebappClassLoader.loadClass(WebappClassLoader.java:1205)
    at jrockit/vm/Classes.loadClassInternal(Ljava/lang/ClassLoader;Ljava/lang/String;)Ljava/lang/Class;(Unknown Source)
    at jrockit/vm/RNI.c2java(IIII)V(Native Method)
    at jrockit/vm/RNI.initializeClass(I)V(Native Method)
    at org/codehaus/xfire/jaxb2/JaxbServiceFactory.<init>(JaxbServiceFactory.java:34)
    at org/codehaus/xfire/jaxb2/JaxbServiceFactory.<init>(JaxbServiceFactory.java:26)
    at jrockit/vm/RNI.c2java(IIII)V(Native Method)
    at jrockit/vm/Reflect.invokeMethod(Ljava/lang/Object;Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object;(Native Method)
    at sun/reflect/NativeConstructorAccessorImpl.newInstance0(Ljava/lang/reflect/Constructor;[Ljava/lang/Object;)Ljava/lang/Object;(
    Native Method)
    at sun/reflect/NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
    at sun/reflect/DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
    at java/lang/reflect/Constructor.newInstance(Constructor.java:513)
    at org/codehaus/xfire/spring/config/ServiceFactoryBean.loadServiceFactory(ServiceFactoryBean.java:170)
    at org/codehaus/xfire/spring/config/ServiceFactoryBean.initialize(ServiceFactoryBean.java:83)
    at org/codehaus/xfire/spring/config/ServiceFactoryBean.getObject(ServiceFactoryBean.java:66)
    at org/codehaus/xfire/spring/editors/ServiceFactoryEditor.setAsText(ServiceFactoryEditor.java:38)
    at org/springframework/beans/BeanWrapperImpl.doTypeConversionIfNecessary(BeanWrapperImpl.java:771)
    at org/springframework/beans/BeanWrapperImpl.setPropertyValue(BeanWrapperImpl.java:584)
    at org/springframework/beans/BeanWrapperImpl.setPropertyValue(BeanWrapperImpl.java:469)
    at org/springframework/beans/BeanWrapperImpl.setPropertyValue(BeanWrapperImpl.java:626)
    at org/springframework/beans/BeanWrapperImpl.setPropertyValues(BeanWrapperImpl.java:653)
    at org/springframework/beans/BeanWrapperImpl.setPropertyValues(BeanWrapperImpl.java:642)
    at org/springframework/beans/factory/support/AbstractAutowireCapableBeanFactory.applyPropertyValues(AbstractAutowireCapableBeanF
    actory.java:1023)
    ^– Holding lock: org/springframework/beans/factory/support/DefaultListableBeanFactory@0x02B7C7A8[thin lock]
    at org/springframework/beans/factory/support/AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.
    java:824)
    at org/springframework/beans/factory/support/AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.ja
    va:345)
    at org/springframework/beans/factory/support/AbstractBeanFactory.getBean(AbstractBeanFactory.java:226)
    ^– Holding lock: java/util/HashMap@0x02B7C9A8[thin lock]
    at org/springframework/beans/factory/support/AbstractBeanFactory.getBean(AbstractBeanFactory.java:147)
    at org/springframework/beans/factory/support/DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java
    :275)
    at org/springframework/context/support/AbstractApplicationContext.refresh(AbstractApplicationContext.java:320)
    at org/codehaus/xfire/spring/XFireConfigLoader.getXFireApplicationContext(XFireConfigLoader.java:107)
    at org/codehaus/xfire/spring/XFireConfigLoader.loadContext(XFireConfigLoader.java:41)
    at org/codehaus/xfire/transport/http/XFireConfigurableServlet.loadConfig(XFireConfigurableServlet.java:86)
    at org/codehaus/xfire/transport/http/XFireConfigurableServlet.createXFire(XFireConfigurableServlet.java:54)
    at org/codehaus/xfire/transport/http/XFireServlet.init(XFireServlet.java:45)
    at javax/servlet/GenericServlet.init(GenericServlet.java:212)
    at org/apache/catalina/core/StandardWrapper.loadServlet(StandardWrapper.java:1139)
    ^– Holding lock: org/apache/catalina/core/StandardWrapper@0x0269CC50[recursive]
    at org/apache/catalina/core/StandardWrapper.load(StandardWrapper.java:966)
    ^– Holding lock: org/apache/catalina/core/StandardWrapper@0x0269CC50[thin lock]
    at org/apache/catalina/core/StandardContext.loadOnStartup(StandardContext.java:3956)
    at org/apache/catalina/core/StandardContext.start(StandardContext.java:4230)
    ^– Holding lock: org/apache/catalina/core/StandardContext@0x03FA3FA8[thin lock]
    at org/apache/catalina/core/ContainerBase.addChildInternal(ContainerBase.java:760)
    ^– Holding lock: java/util/HashMap@0x0408AEB0[thin lock]
    at org/apache/catalina/core/ContainerBase.addChild(ContainerBase.java:740)

    #271123 Reply

    djheath
    Member

    I’ve discovered exactly what is happening and it is indeed an XFire bug with the JaxbServiceFactory. If I do a bottom-up approach web service described as follows, the web service deploys to tomcat & JRockit JVM with no problem:

    <?xml version=”1.0″ encoding=”UTF-8″?>
    <beans xmlns=”http://xfire.codehaus.org/config/1.0″&gt;
    <service>
    <name>wst8</name>
    <serviceClass>localhost.service.Iwst8</serviceClass>
    <implementationClass>
    localhost.service.wst8Impl
    </implementationClass>
    <style>document</style>
    <use>literal</use>
    <scope>request</scope>
    </service>
    </beans>

    If, however, I do a top-down approach from an existing WSDL that generates the following service descriptor, the JVM crashes:

    <?xml version=”1.0″ encoding=”UTF-8″?>
    <beans xmlns=”http://xfire.codehaus.org/config/1.0″&gt;
    <service>
    <name>wst8</name>
    http://localhost/wst8/
    <serviceClass>localhost.service.wst8Impl</serviceClass>
    <serviceFactory>
    org.codehaus.xfire.jaxb2.JaxbServiceFactory
    </serviceFactory>
    <style>document</style>
    <use>literal</use>
    <scope>request</scope>
    </service>
    </beans>

    Comparing that to the above stack trace this lends one to believe that it is definitely the JaxbServiceFactory class that is crashing the JVM. The question is ‘why?’ and perhaps, ‘can i substitute a faulty JaxbServiceFactory with a different one?’

    Any help would be fantastically appreciated since this project is extremely short on time

    #271272 Reply

    tomeksz
    Member

    This is probably JRockit Bug not XFire’s :/. JRockit sometimes behave in very strange ways ( e.g. with reflections ).

    Currently i don’t know how to help. If you use top-down approach then you need jaxbfactory :/
    You can try to download XFire source and compile it with javac provided by Jrockit, its long shot, but don’t have other ideas right now :/

    #271317 Reply

    djheath
    Member

    Thanks. I already tried that without success 🙁

Viewing 4 posts - 1 through 4 (of 4 total)
Reply To: XFire on JRockit

You must be logged in to post in the forum log in