Re: [drlvm] sanity check - can someone build from svn and test ActiveMQ?
One of reasons of verifier/classnotfound exceptions is that classes can't be read from files after security manager is installed - please see http://issues.apache.org/jira/browse/HARMONY-1226 for minimal test case. It is the reason why class can't be loaded with second parameter == true but can be loaded with it == false. The class is already in cache but access to its disk copy is denied. On 8/18/06, Pavel Rebriy <[EMAIL PROTECTED]> wrote: Ok, I'll try to explain it. Function vf_resolve_class with true as the second parameter asks class loader to load a class with a given class name. If the second parameter equals to false, function just checks if a given class is loaded, and get it if it is. The patch claims that if class loader tries to load a given class and fails and then asks it to lookup among loaded classes it appears to be successfully loaded. That is a class is failed to load, but it is successfully loaded in VM. It could work only is a class loader is bugged. On 17/08/06, Geir Magnusson Jr. <[EMAIL PROTECTED]> wrote: > > Right - what I was worried about was that I *thought* that > HARMONY-956 got me to where Gergory is describing, but he's applying > HARMONY-1179. > > I'll just stop worrying about this for the snapshot, post it, and > move on w/ 1179 and keep going. > > Thanks all for looking into this - I could *swear* that 956 had a > visible effect, but I was clearly mistaken. > > And what is "dutty hacking"? :) > > geir > > > On Aug 17, 2006, at 8:11 AM, Pavel Rebriy wrote: > > > Anton, your patch is a dutty hacking. > > > > With and without the patch ActiveMQ crashes as Gregory described. > > > > On 17/08/06, Anton Luht <[EMAIL PROTECTED]> wrote: > >> > >> Hello, > >> > >> Please try to apply patch > >> > >> Index: vm/vmcore/src/verifier/ver_utils.cpp > >> === > >> --- vm/vmcore/src/verifier/ver_utils.cpp(revision 432184) > >> +++ vm/vmcore/src/verifier/ver_utils.cpp(working copy) > >> @@ -1391,6 +1391,9 @@ > >> > >> // get stack reference class > >> class_handler source = vf_resolve_class( constraint->source, > >> true, > >> ctex ); > >> +if(source == NULL) { > >> + source = vf_resolve_class( constraint->source, false, ctex ); > >> +} > >> if( !source ) { > >> VERIFY_DEBUG( "verifying class " << class_get_name( ctex- > >> >m_class > >> ) > >> << " (method " << method_get_name( constraint->method ) > >> > >> > >> > >> Unfortunately I cannot attach it to the JIRA issue because the > >> issue is > >> closed. > >> > >> On 8/16/06, Geir Magnusson Jr. <[EMAIL PROTECTED]> wrote: > >> > I'm trying to create snapshots, and when testing w/ ActiveMQ, I > >> still > >> > have the same problems w/ ActiveMQ as reported originally in > >> HARMONY-956. > >> > > >> > Can someone do a sanity check? it's a release build. > >> > > >> > geir > >> > > >> > > >> - > >> > Terms of use : http://incubator.apache.org/harmony/mailing.html > >> > To unsubscribe, e-mail: harmony-dev- > >> [EMAIL PROTECTED] > >> > For additional commands, e-mail: harmony-dev- > >> [EMAIL PROTECTED] > >> > > >> > > >> > >> > >> -- > >> Regards, > >> Anton Luht, > >> Intel Middleware Products Division > >> > >> - > >> Terms of use : http://incubator.apache.org/harmony/mailing.html > >> To unsubscribe, e-mail: [EMAIL PROTECTED] > >> For additional commands, e-mail: harmony-dev- > >> [EMAIL PROTECTED] > >> > >> > > > > > > -- > > Best regards, > > Pavel Rebriy > > > - > Terms of use : http://incubator.apache.org/harmony/mailing.html > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > -- Best regards, Pavel Rebriy -- Regards, Anton Luht, Intel Middleware Products Division - Terms of use : http://incubator.apache.org/harmony/mailing.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [drlvm] sanity check - can someone build from svn and test ActiveMQ?
Ok, I'll try to explain it. Function vf_resolve_class with true as the second parameter asks class loader to load a class with a given class name. If the second parameter equals to false, function just checks if a given class is loaded, and get it if it is. The patch claims that if class loader tries to load a given class and fails and then asks it to lookup among loaded classes it appears to be successfully loaded. That is a class is failed to load, but it is successfully loaded in VM. It could work only is a class loader is bugged. On 17/08/06, Geir Magnusson Jr. <[EMAIL PROTECTED]> wrote: Right - what I was worried about was that I *thought* that HARMONY-956 got me to where Gergory is describing, but he's applying HARMONY-1179. I'll just stop worrying about this for the snapshot, post it, and move on w/ 1179 and keep going. Thanks all for looking into this - I could *swear* that 956 had a visible effect, but I was clearly mistaken. And what is "dutty hacking"? :) geir On Aug 17, 2006, at 8:11 AM, Pavel Rebriy wrote: > Anton, your patch is a dutty hacking. > > With and without the patch ActiveMQ crashes as Gregory described. > > On 17/08/06, Anton Luht <[EMAIL PROTECTED]> wrote: >> >> Hello, >> >> Please try to apply patch >> >> Index: vm/vmcore/src/verifier/ver_utils.cpp >> === >> --- vm/vmcore/src/verifier/ver_utils.cpp(revision 432184) >> +++ vm/vmcore/src/verifier/ver_utils.cpp(working copy) >> @@ -1391,6 +1391,9 @@ >> >> // get stack reference class >> class_handler source = vf_resolve_class( constraint->source, >> true, >> ctex ); >> +if(source == NULL) { >> + source = vf_resolve_class( constraint->source, false, ctex ); >> +} >> if( !source ) { >> VERIFY_DEBUG( "verifying class " << class_get_name( ctex- >> >m_class >> ) >> << " (method " << method_get_name( constraint->method ) >> >> >> >> Unfortunately I cannot attach it to the JIRA issue because the >> issue is >> closed. >> >> On 8/16/06, Geir Magnusson Jr. <[EMAIL PROTECTED]> wrote: >> > I'm trying to create snapshots, and when testing w/ ActiveMQ, I >> still >> > have the same problems w/ ActiveMQ as reported originally in >> HARMONY-956. >> > >> > Can someone do a sanity check? it's a release build. >> > >> > geir >> > >> > >> - >> > Terms of use : http://incubator.apache.org/harmony/mailing.html >> > To unsubscribe, e-mail: harmony-dev- >> [EMAIL PROTECTED] >> > For additional commands, e-mail: harmony-dev- >> [EMAIL PROTECTED] >> > >> > >> >> >> -- >> Regards, >> Anton Luht, >> Intel Middleware Products Division >> >> - >> Terms of use : http://incubator.apache.org/harmony/mailing.html >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> For additional commands, e-mail: harmony-dev- >> [EMAIL PROTECTED] >> >> > > > -- > Best regards, > Pavel Rebriy - Terms of use : http://incubator.apache.org/harmony/mailing.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Best regards, Pavel Rebriy
Re: [drlvm] sanity check - can someone build from svn and test ActiveMQ?
Right - what I was worried about was that I *thought* that HARMONY-956 got me to where Gergory is describing, but he's applying HARMONY-1179. I'll just stop worrying about this for the snapshot, post it, and move on w/ 1179 and keep going. Thanks all for looking into this - I could *swear* that 956 had a visible effect, but I was clearly mistaken. And what is "dutty hacking"? :) geir On Aug 17, 2006, at 8:11 AM, Pavel Rebriy wrote: Anton, your patch is a dutty hacking. With and without the patch ActiveMQ crashes as Gregory described. On 17/08/06, Anton Luht <[EMAIL PROTECTED]> wrote: Hello, Please try to apply patch Index: vm/vmcore/src/verifier/ver_utils.cpp === --- vm/vmcore/src/verifier/ver_utils.cpp(revision 432184) +++ vm/vmcore/src/verifier/ver_utils.cpp(working copy) @@ -1391,6 +1391,9 @@ // get stack reference class class_handler source = vf_resolve_class( constraint->source, true, ctex ); +if(source == NULL) { + source = vf_resolve_class( constraint->source, false, ctex ); +} if( !source ) { VERIFY_DEBUG( "verifying class " << class_get_name( ctex- >m_class ) << " (method " << method_get_name( constraint->method ) Unfortunately I cannot attach it to the JIRA issue because the issue is closed. On 8/16/06, Geir Magnusson Jr. <[EMAIL PROTECTED]> wrote: > I'm trying to create snapshots, and when testing w/ ActiveMQ, I still > have the same problems w/ ActiveMQ as reported originally in HARMONY-956. > > Can someone do a sanity check? it's a release build. > > geir > > - > Terms of use : http://incubator.apache.org/harmony/mailing.html > To unsubscribe, e-mail: harmony-dev- [EMAIL PROTECTED] > For additional commands, e-mail: harmony-dev- [EMAIL PROTECTED] > > -- Regards, Anton Luht, Intel Middleware Products Division - Terms of use : http://incubator.apache.org/harmony/mailing.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: harmony-dev- [EMAIL PROTECTED] -- Best regards, Pavel Rebriy - Terms of use : http://incubator.apache.org/harmony/mailing.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [drlvm] sanity check - can someone build from svn and test ActiveMQ?
Anton, your patch is a dutty hacking. With and without the patch ActiveMQ crashes as Gregory described. On 17/08/06, Anton Luht <[EMAIL PROTECTED]> wrote: Hello, Please try to apply patch Index: vm/vmcore/src/verifier/ver_utils.cpp === --- vm/vmcore/src/verifier/ver_utils.cpp(revision 432184) +++ vm/vmcore/src/verifier/ver_utils.cpp(working copy) @@ -1391,6 +1391,9 @@ // get stack reference class class_handler source = vf_resolve_class( constraint->source, true, ctex ); +if(source == NULL) { + source = vf_resolve_class( constraint->source, false, ctex ); +} if( !source ) { VERIFY_DEBUG( "verifying class " << class_get_name( ctex->m_class ) << " (method " << method_get_name( constraint->method ) Unfortunately I cannot attach it to the JIRA issue because the issue is closed. On 8/16/06, Geir Magnusson Jr. <[EMAIL PROTECTED]> wrote: > I'm trying to create snapshots, and when testing w/ ActiveMQ, I still > have the same problems w/ ActiveMQ as reported originally in HARMONY-956. > > Can someone do a sanity check? it's a release build. > > geir > > - > Terms of use : http://incubator.apache.org/harmony/mailing.html > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > -- Regards, Anton Luht, Intel Middleware Products Division - Terms of use : http://incubator.apache.org/harmony/mailing.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Best regards, Pavel Rebriy
Re: [drlvm] sanity check - can someone build from svn and test ActiveMQ?
Hello, Please try to apply patch Index: vm/vmcore/src/verifier/ver_utils.cpp === --- vm/vmcore/src/verifier/ver_utils.cpp(revision 432184) +++ vm/vmcore/src/verifier/ver_utils.cpp(working copy) @@ -1391,6 +1391,9 @@ // get stack reference class class_handler source = vf_resolve_class( constraint->source, true, ctex ); +if(source == NULL) { + source = vf_resolve_class( constraint->source, false, ctex ); +} if( !source ) { VERIFY_DEBUG( "verifying class " << class_get_name( ctex->m_class ) << " (method " << method_get_name( constraint->method ) Unfortunately I cannot attach it to the JIRA issue because the issue is closed. On 8/16/06, Geir Magnusson Jr. <[EMAIL PROTECTED]> wrote: I'm trying to create snapshots, and when testing w/ ActiveMQ, I still have the same problems w/ ActiveMQ as reported originally in HARMONY-956. Can someone do a sanity check? it's a release build. geir - Terms of use : http://incubator.apache.org/harmony/mailing.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Regards, Anton Luht, Intel Middleware Products Division - Terms of use : http://incubator.apache.org/harmony/mailing.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [drlvm] sanity check - can someone build from svn and test ActiveMQ?
On Wednesday 16 August 2006 23:09 Andrey Chernyshev wrote: > I can start the ActiveMQ message broker (on Win only, though) after > applying the patch from HARMONY-1179. Though it is expressing a > complain like: > > WARN ManagementContext - Failed to start jmx connector: > javax.nami ng.NoInitialContextException: Failed to create InitialContext > using factory spec ified in hashtable > {jmx.remote.protocol.provider.class.loader=java.net.URLClassL [EMAIL > PROTECTED] > [Root exception is java.lang.ClassNotFoundException: class null not fo und] > > It still prints the resulting message: > > INFO BrokerService - ActiveMQ JMS Message Broker > (localhost, I D:aycherny-mobl2-2814-1155754517801-1:0) started > > Is this what was expected? At least it doesn't seem to throw > IncompatibleClassChangeError any longer... I don't have this, activemq doesn't start for me and here's what I have. This program looks very interesting since we all get different results :) I have the same result on both platforms with clean rebuild with JIRA 1179 applied. On Linux (and the same happened on windows until just last build I've made) there is a failed assertion like java.exec: /amd64/home/gregory/work/Harmony/harmony/enhanced/drlvm/trunk/vm/vmcore/src/jni/jni_field.cpp:304: jint GetIntField(JNIEnv*, _jobject*, _jfieldID*): Assertion `IsInstanceOf(env, obj, struct_Class_to_jclass(f->get_class()))' failed. It looks like GetIntField is used on an object of class java.lang.Boolean object for some reason and it fails assertion for the fieldID is of a java.land.Integer field. Stack trace on JIT is in [1] When running on interpreter (and most recent build on windows produces this error contrary to the above), the failure looks differently (probably because of different class resolution order on interpreter): ERROR: java.lang.RuntimeException: Failed to execute start task. Reason: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.apache.activemq.xbean.XBeanBrokerService' defined in class path resource [activemq.xml]: Initialization of bean failed; nested exception is java.lang.IllegalAccessError: null ERROR: java.lang.Exception: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.apache.activemq.xbean.XBeanBrokerService' defined in class path resource [activemq.xml]: Initialization of bean failed; nested exception is java.lang.IllegalAccessError: null The patch which adds printing of stack dump for IllegalAccessError is attached. It produces quite a lot of stacks but I thought that the last one is actually the cause of failure and it is the one which I pasted in [2]. [1] Stack Trace (0x80592c8): [0x80592c8] (nil)(n): org/apache/harmony/luni/platform/OSNetworkSystem.setSocketOptionImpl(Ljava/io/FileDescriptor;ILjava/lang/Object;)V [0x80592c8] 0x8bf0cf15(m): org/apache/harmony/luni/platform/OSNetworkSystem.setSocketOption(Ljava/io/FileDescriptor;ILjava/lang/Object;)V [0x80592c8] 0x8bf0c9ae(m): org/apache/harmony/luni/net/PlainDatagramSocketImpl.setOption(ILjava/lang/Object;)V [0x80592c8] 0x8bf0d151(m): java/net/DatagramSocket.setReuseAddress(Z)V [0x80592c8] 0x8bf0b328(m): java/net/MulticastSocket.(I)V [0x80592c8] 0x8bf08b19(m): org/apache/activemq/transport/discovery/multicast/MulticastDiscoveryAgent.start()V [0x80592c8] 0x8bf07469(m): org/apache/activemq/broker/TransportConnector.start()V [0x80592c8] 0x8bf00619(m): org/apache/activemq/broker/BrokerService.startTransportConnector(Lorg/apache/activemq/broker/TransportConnector;)V [0x80592c8] 0x8beff6ce(m): org/apache/activemq/broker/BrokerService.startAllConnectors()V [0x80592c8] 0x903cea06(m): org/apache/activemq/broker/BrokerService.start()V [0x80592c8] 0x903ce536(m): org/apache/activemq/xbean/XBeanBrokerService.afterPropertiesSet()V [0x80592c8] 0x9046a5dc(m): org/springframework/beans/factory/support/AbstractAutowireCapableBeanFactory.invokeInitMethods(Ljava/lang/String;Ljava/lang/Object;Lorg/springframework/beans/factory/support/RootBeanDefinition;)V [0x80592c8] 0x9045c333(m): org/springframework/beans/factory/support/AbstractAutowireCapableBeanFactory.createBean(Ljava/lang/String;Lorg/springframework/beans/factory/support/RootBeanDefinition; [Ljava/lang/Object;)Ljava/lang/Object; [0x80592c8] 0x9045b1b4(m): org/springframework/beans/factory/support/AbstractBeanFactory.getBean(Ljava/lang/String;Ljava/lang/Class; [Ljava/lang/Object;)Ljava/lang/Object; [0x80592c8] 0x9045aa33(m): org/springframework/beans/factory/support/AbstractBeanFactory.getBean(Ljava/lang/String;)Ljava/lang/Object; [0x80592c8] 0x90472d5a(m): org/springframework/beans/factory/support/DefaultListableBeanFactory.preInstantiateSingletons()V [0x80592c8] 0xb74903ea(m): org/springframework/context/support/AbstractApplicationContext.refresh()V [0x80592c8] 0xb746c736(m): org/apache/xbean/spring/context/ClassPathXmlApplicationContext.([Lja
Re: [drlvm] sanity check - can someone build from svn and test ActiveMQ?
Andrey Chernyshev wrote: I can start the ActiveMQ message broker (on Win only, though) after applying the patch from HARMONY-1179. Though it is expressing a complain like: WARN ManagementContext - Failed to start jmx connector: javax.nami ng.NoInitialContextException: Failed to create InitialContext using factory spec ified in hashtable {jmx.remote.protocol.provider.class.loader=java.net.URLClassL [EMAIL PROTECTED] [Root exception is java.lang.ClassNotFoundException: class null not fo und] It still prints the resulting message: INFO BrokerService - ActiveMQ JMS Message Broker (localhost, I D:aycherny-mobl2-2814-1155754517801-1:0) started Is this what was expected? At least it doesn't seem to throw IncompatibleClassChangeError any longer... Thanks, but that wasn't what I was looking for. I wanted to see if w/o 1179 it would at least stop w/ the NoClassDefFoundError, which I'm still getting. Odd. I'm confused - I thought 956 took care of that, producing the new problem geir Thanks, Andrey. On 8/16/06, Geir Magnusson Jr. <[EMAIL PROTECTED]> wrote: I'm trying to create snapshots, and when testing w/ ActiveMQ, I still have the same problems w/ ActiveMQ as reported originally in HARMONY-956. Can someone do a sanity check? it's a release build. geir - Terms of use : http://incubator.apache.org/harmony/mailing.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - Terms of use : http://incubator.apache.org/harmony/mailing.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [drlvm] sanity check - can someone build from svn and test ActiveMQ?
I can start the ActiveMQ message broker (on Win only, though) after applying the patch from HARMONY-1179. Though it is expressing a complain like: WARN ManagementContext - Failed to start jmx connector: javax.nami ng.NoInitialContextException: Failed to create InitialContext using factory spec ified in hashtable {jmx.remote.protocol.provider.class.loader=java.net.URLClassL [EMAIL PROTECTED] [Root exception is java.lang.ClassNotFoundException: class null not fo und] It still prints the resulting message: INFO BrokerService - ActiveMQ JMS Message Broker (localhost, I D:aycherny-mobl2-2814-1155754517801-1:0) started Is this what was expected? At least it doesn't seem to throw IncompatibleClassChangeError any longer... Thanks, Andrey. On 8/16/06, Geir Magnusson Jr. <[EMAIL PROTECTED]> wrote: I'm trying to create snapshots, and when testing w/ ActiveMQ, I still have the same problems w/ ActiveMQ as reported originally in HARMONY-956. Can someone do a sanity check? it's a release build. geir - Terms of use : http://incubator.apache.org/harmony/mailing.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Andrey Chernyshev Intel Middleware Products Division - Terms of use : http://incubator.apache.org/harmony/mailing.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]