geronimo-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michael Chau <mtqc2...@yahoo.com>
Subject Re: Geronino 3 beta Servlet issue
Date Wed, 18 Apr 2012 16:43:24 GMT
I have my SampleApi (interface) exported it.  I don't believe I'm suppose to export the implementation
(SampleServer) and web bundle(Sample Web).  But, i just tried exporting them both just to
see if it will work and I'm still getting the same error.  I'm somewhat following the CounterApp
example.  My web bundle is pretty much the same as the CounterWebBundle (same required import
packages and no exports).


On Apr 18, 2012, at 12:55 AM, Forrest Xia wrote:

> Have you exported your application classes in Export-Package of MANIFEST.MF?
> 
> On Wed, Apr 18, 2012 at 3:42 AM, Michael Chau <mtqc2000@yahoo.com> wrote:
> Thanks, Ivan.
> 
> I added the javax.naming to the import and now getting this error:
> 
> 2012-04-18 00:40:53,484 ERROR [WebApplication] Unable to start web application for bundle
sample-web
> org.apache.geronimo.common.DeploymentException: Fail to load servlet class
> 	at org.apache.geronimo.web25.deployment.merge.annotation.ServletSecurityAnnotationMergeHandler.postProcessWebXmlElement(ServletSecurityAnnotationMergeHandler.java:79)
> 	at org.apache.geronimo.web25.deployment.merge.MergeHelper.processWebFragmentsAndAnnotations(MergeHelper.java:418)
> 	at org.apache.geronimo.web25.deployment.AbstractWebModuleBuilder.basicInitContext(AbstractWebModuleBuilder.java:493)
> 	at org.apache.geronimo.web25.deployment.AbstractWebModuleBuilder.initContext(AbstractWebModuleBuilder.java:436)
> 	at org.apache.geronimo.osgi.web.extender.WebApplication.doRun(WebApplication.java:213)
> 	at org.apache.geronimo.osgi.web.extender.WebApplication.run(WebApplication.java:125)
> 	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
> 	at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
> 	at java.util.concurrent.FutureTask.run(FutureTask.java:138)
> 	at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
> 	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
> 	at java.lang.Thread.run(Thread.java:680)
> Caused by: java.lang.ClassNotFoundException: com.sample.client.web.SampleServlet
> 	at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:513)
> 	at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:429)
> 	at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:417)
> 	at org.apache.geronimo.hook.equinox.GeronimoClassLoader.loadClass(GeronimoClassLoader.java:85)
> 	at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
> 	at org.eclipse.osgi.internal.loader.BundleLoader.loadClass(BundleLoader.java:345)
> 	at org.eclipse.osgi.framework.internal.core.BundleHost.loadClass(BundleHost.java:229)
> 	at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadClass(AbstractBundle.java:1207)
> 	at org.apache.geronimo.web25.deployment.merge.annotation.ServletSecurityAnnotationMergeHandler.postProcessWebXmlElement(ServletSecurityAnnotationMergeHandler.java:52)
> 	... 11 more
> 
> 
> On Apr 17, 2012, at 11:09 PM, Ivan wrote:
> 
>> From the log files, it seems that javax.naming should be added in the import-package
list for the wab ?
>> 
>> 2012/4/18 Michael Chau <mchau01@gmail.com>
>> I've created a SampleApi(interface), SampleServer(implementation) and SampleWeb(servlet)
bundles.  It's using Blueprint.  I ran it in the Apache Aries container and it was fine. 
I tried to run it in Geronimo and got 
>> 
>> 2012-04-17 14:44:52,759 ERROR [WebApplication] Unable to start web application for
bundle sample-web
>> java.lang.NoClassDefFoundError: Could not fully load class: com.sample.client.web.SampleServlet
>>  due to:javax/naming/NamingException
>>  in classLoader: 
>> org.apache.geronimo.hook.equinox.GeronimoClassLoader@10993991
>> 	at org.apache.xbean.finder.ClassFinder.<init>(ClassFinder.java:136)
>> 	at org.apache.geronimo.web25.deployment.AbstractWebModuleBuilder.createWebAppClassFinder(AbstractWebModuleBuilder.java:663)
>> 	at org.apache.geronimo.web25.deployment.AbstractWebModuleBuilder.configureBasicWebModuleAttributes(AbstractWebModuleBuilder.java:698)
>> 	at org.apache.geronimo.tomcat.deployment.TomcatModuleBuilder.addGBeans(TomcatModuleBuilder.java:483)
>> 	at org.apache.geronimo.osgi.web.extender.WebApplication.doRun(WebApplication.java:218)
>> 	at org.apache.geronimo.osgi.web.extender.WebApplication.run(WebApplication.java:125)
>> 	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
>> 	at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
>> 	at java.util.concurrent.FutureTask.run(FutureTask.java:138)
>> 	at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
>> 	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
>> 	at java.lang.Thread.run(Thread.java:680)
>> 
>> Any help is appreciated.
>> 
>> Michael
>> 
>> 
>> 
>> -- 
>> Ivan
> 
> 
> 
> 
> -- 
> Thanks!
> 
> Regards, Forrest
> 


Mime
View raw message