camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Gedaliya <dk...@schonfeld.com>
Subject Re: java.lang.VerifyError: Cannot inherit from final class
Date Fri, 18 Dec 2009 21:43:09 GMT

Thanks for your reply!

The only remaining stack trace entries are as follows:
[...]
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
	at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:597)
	at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeCustomInitMethod(AbstractAutowireCapableBeanFactory.java:1414)
	at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1375)
	at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1335)
	... 18 more

I started the stack trace from the point where it enters the init method of
the PollFileController class, since I can debug the code into that method
until it calls the getBean method, when it throws the exception.

Again, the odd thing is that it works under 2.0-M2 and fails under 2.1.0.
Thanks...

- David

Stephen Gargan wrote:
> 
> Is that the entire stack trace? Does it mention the name of the class
> is it complaining about?
> 
> On Fri, Dec 18, 2009 at 1:20 PM, Gedaliya <dkatz@schonfeld.com> wrote:
>>
>> I am trying to upgrade from Camel 2.0-M2 to 2.1.0
>>
>> In 2.0-M2 the following code works just fine. In 2.1.0 it does not:
>>
>> [...]
>>
>> CamelContext c = (CamelContext)applicationContext.getBean("camel");
>> // Get the endpoints for this camel context
>> String endPoints[] =
>> applicationContext.getBeanNamesForType(Endpoint.class);
>> // Find the time endpoints
>> for (int i=0; i< endPoints.length; i++)
>> {
>>   // If the endpoint is a timerendpoint, create a file object for it
>>   // and put it in the array
>>   endPoint = (Endpoint)applicationContext.getBean(endPoints[i]);
>>
>> [...]
>>
>> In Camel 2.1.0 it throws an exception:
>>
>> Caused by: java.lang.VerifyError: Cannot inherit from final class
>>        at java.lang.ClassLoader.defineClass1(Native Method)
>>        at java.lang.ClassLoader.defineClass(ClassLoader.java:621)
>>        at
>> java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124)
>>        at java.net.URLClassLoader.defineClass(URLClassLoader.java:260)
>>        at java.net.URLClassLoader.access$000(URLClassLoader.java:56)
>>        at java.net.URLClassLoader$1.run(URLClassLoader.java:195)
>>        at java.security.AccessController.doPrivileged(Native Method)
>>        at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
>>        at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
>>        at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
>>        at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
>>        at
>> org.apache.camel.impl.DefaultPackageScanClassResolver.addIfMatching(DefaultPackageScanClassResolver.java:405)
>>        at
>> org.apache.camel.impl.DefaultPackageScanClassResolver.loadImplementationsInDirectory(DefaultPackageScanClassResolver.java:347)
>>        at
>> org.apache.camel.impl.DefaultPackageScanClassResolver.find(DefaultPackageScanClassResolver.java:256)
>>        at
>> org.apache.camel.impl.DefaultPackageScanClassResolver.find(DefaultPackageScanClassResolver.java:180)
>>        at
>> org.apache.camel.impl.DefaultPackageScanClassResolver.findAnnotated(DefaultPackageScanClassResolver.java:100)
>>        at
>> org.apache.camel.impl.converter.AnnotationTypeConverterLoader.load(AnnotationTypeConverterLoader.java:63)
>>        at
>> org.apache.camel.impl.converter.DefaultTypeConverter.checkLoaded(DefaultTypeConverter.java:379)
>>        at
>> org.apache.camel.impl.converter.DefaultTypeConverter.doConvertTo(DefaultTypeConverter.java:160)
>>        at
>> org.apache.camel.impl.converter.DefaultTypeConverter.mandatoryConvertTo(DefaultTypeConverter.java:120)
>>        at
>> org.apache.camel.impl.converter.DefaultTypeConverter.mandatoryConvertTo(DefaultTypeConverter.java:113)
>>        at
>> org.apache.camel.util.IntrospectionSupport.convert(IntrospectionSupport.java:277)
>>        at
>> org.apache.camel.util.IntrospectionSupport.setProperty(IntrospectionSupport.java:233)
>>        at
>> org.apache.camel.util.IntrospectionSupport.setProperties(IntrospectionSupport.java:200)
>>        at
>> org.apache.camel.util.EndpointHelper.setProperties(EndpointHelper.java:152)
>>        at
>> org.apache.camel.impl.DefaultComponent.setProperties(DefaultComponent.java:229)
>>        at
>> org.apache.camel.component.jetty.JettyHttpComponent.createEndpoint(JettyHttpComponent.java:125)
>>        at
>> org.apache.camel.impl.DefaultComponent.createEndpoint(DefaultComponent.java:78)
>>        at
>> org.apache.camel.impl.DefaultCamelContext.getEndpoint(DefaultCamelContext.java:416)
>>        at
>> org.apache.camel.spring.CamelEndpointFactoryBean.createEndpoint(CamelEndpointFactoryBean.java:96)
>>        at
>> org.apache.camel.spring.CamelEndpointFactoryBean.isSingleton(CamelEndpointFactoryBean.java:62)
>>        at
>> org.springframework.beans.factory.support.FactoryBeanRegistrySupport.getObjectFromFactoryBean(FactoryBeanRegistrySupport.java:87)
>>        at
>> org.springframework.beans.factory.support.AbstractBeanFactory.getObjectForBeanInstance(AbstractBeanFactory.java:1288)
>>        at
>> org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:217)
>>        at
>> org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:185)
>>        at
>> org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:164)
>>        at
>> org.springframework.context.support.AbstractApplicationContext.getBean(AbstractApplicationContext.java:880)
>>        at
>> com.schonfeld.eventhub.controller.PollFileController.init(PollFileController.java:68)
>>
>> [...]
>>
>> --
>> View this message in context:
>> http://old.nabble.com/java.lang.VerifyError%3A-Cannot-inherit-from-final-class-tp26849871p26849871.html
>> Sent from the Camel - Users mailing list archive at Nabble.com.
>>
>>
> 
> 

-- 
View this message in context: http://old.nabble.com/java.lang.VerifyError%3A-Cannot-inherit-from-final-class-tp26849871p26850112.html
Sent from the Camel - Users mailing list archive at Nabble.com.


Mime
View raw message