You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by "Majin_Clodan@t-online.de" <Ma...@t-online.de> on 2012/10/10 11:11:40 UTC

INFO: Marking servlet jsp as unavailable

Hello,

well I have the following problem:
I use kornak-api which provides a simple servlet-based recommender
application available under the Apache license.
Wenn I want to start the webservice I get the following error:

[INFO] Scanning for projects...
[INFO]                                                                
        
[INFO]
------------------------------------------------------------------------
[INFO] Building kornakapi 1.0
[INFO]
------------------------------------------------------------------------
[INFO] 
[INFO] >>> tomcat-maven-plugin:1.1:run (default-cli) @ kornakapi >>>
[INFO] 
[INFO] --- maven-resources-plugin:2.3:resources (default-resources) @
kornakapi ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory
/home/vagrant/kornakapi/kornakapi/src/main/resources
[INFO] 
[INFO] --- maven-compiler-plugin:2.3.2:compile (default-compile) @
kornakapi ---
[INFO] Nothing to compile - all classes are up to date
[INFO] 
[INFO] <<< tomcat-maven-plugin:1.1:run (default-cli) @ kornakapi <<<
[INFO] 
[INFO] --- tomcat-maven-plugin:1.1:run (default-cli) @ kornakapi ---
[INFO] Running war on http://localhost:8080/kornakapi
[INFO] Using existing Tomcat server configuration at
/home/vagrant/kornakapi/kornakapi/target/tomcat
Oct 10, 2012 8:25:05 AM org.apache.catalina.startup.Embedded start
INFO: Starting tomcat server
Oct 10, 2012 8:25:05 AM org.apache.catalina.core.StandardEngine start
INFO: Starting Servlet Engine: Apache Tomcat/6.0.29
12/10/10 08:25:06 INFO mortbay.log: Logging to
org.slf4j.impl.Log4jLoggerAdapter(org.mortbay.log) via
org.mortbay.log.Slf4jLog
Oct 10, 2012 8:25:06 AM org.apache.catalina.core.ApplicationContext
log
INFO: Marking servlet jsp as unavailable
Oct 10, 2012 8:25:06 AM org.apache.catalina.core.StandardContext
loadOnStartup
SEVERE: Servlet /kornakapi threw load() exception
java.lang.ClassCastException: org.apache.jasper.servlet.JspServlet
cannot be cast to javax.servlet.Servlet
    at
org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1116)
    at
org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:993)
    at
org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:4350)
    at
org.apache.catalina.core.StandardContext.start(StandardContext.java:4659)
    at
org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045)
    at
org.apache.catalina.core.StandardHost.start(StandardHost.java:785)
    at
org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045)
    at
org.apache.catalina.core.StandardEngine.start(StandardEngine.java:445)
    at org.apache.catalina.startup.Embedded.start(Embedded.java:825)
    at
org.codehaus.mojo.tomcat.AbstractRunMojo.startContainer(AbstractRunMojo.java:558)
    at
org.codehaus.mojo.tomcat.AbstractRunMojo.execute(AbstractRunMojo.java:255)
    at
org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:101)
    at
org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:209)
    at
org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
    at
org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
    at
org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:84)
    at
org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:59)
    at
org.apache.maven.lifecycle.internal.LifecycleStarter.singleThreadedBuild(LifecycleStarter.java:183)
    at
org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:161)
    at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:320)
    at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:156)
    at org.apache.maven.cli.MavenCli.execute(MavenCli.java:537)
    at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:196)
    at org.apache.maven.cli.MavenCli.main(MavenCli.java:141)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:616)
    at
org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:290)
    at
org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:230)
    at
org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:409)
    at
org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:352)
Oct 10, 2012 8:25:06 AM org.apache.tomcat.util.modeler.Registry
registerComponent
SEVERE: Null component
localEngine:type=JspMonitor,name=jsp,WebModule=//localhost/kornakapi,J2EEApplication=none,J2EEServer=none
Oct 10, 2012 8:25:06 AM org.apache.coyote.http11.Http11Protocol init
INFO: Initializing Coyote HTTP/1.1 on http-8080
Oct 10, 2012 8:25:06 AM org.apache.coyote.http11.Http11Protocol start
INFO: Starting Coyote HTTP/1.1 on http-8080

I think that I get the error because of:
INFO: Marking servlet jsp as unavailable
but  I don't know how to fix this. Does anyone know this error and how
to  fix this? I try it the last 2 days but I can't fix it. :( I tried
so  much things but without success... :(

I will be happy about every help. :) 

Greetings, Clodan

Re: INFO: Marking servlet jsp as unavailable

Posted by Konstantin Kolinko <kn...@gmail.com>.
2012/10/11 Majin_Clodan@t-online.de <Ma...@t-online.de>:
> Hello,
>
>         thanks for your reply.
>
>         But I don't think that this is the solution. I could make this on my
> system without errors. Then I installed a virtual machine (Vagrant)
> and in this machine it isn't working. I have everything installed,
> Path's and Codes are the same. Do you have any idea why it work on my
> system but not in my virtual machine (Vagrant)? It is the same OS as
> well.
>
>         Greetings, Clodan
>
>           Von: Konstantin Kolinko <kn...@gmail.com>
>  An: Tomcat Users List <us...@tomcat.apache.org>
>  Betreff: Re: INFO: Marking servlet jsp as unavailable
>  Datum: Thu, 11 Oct 2012 12:30:55 +0200
>
>  2012/10/10 Majin_Clodan@t-online.de [1] <Majin_Clodan@t-online.de
> [2]>:
>  > INFO: Marking servlet jsp as unavailable
>  > Oct 10, 2012 8:25:06 AM org.apache.catalina.core.StandardContext
>  > loadOnStartup
>  > SEVERE: Servlet /kornakapi threw load() exception
>  > java.lang.ClassCastException: org.apache.jasper.servlet.JspServlet
>  > cannot be cast to javax.servlet.Servlet
>  >
>
>  > I think that I get the error because of:
>  > INFO: Marking servlet jsp as unavailable
>  > but  I don't know how to fix this. Does anyone know this error and
> how
>  > to  fix this? I try it the last 2 days but I can't fix it. :( I
> tried
>  > so  much things but without success... :(
>  >
>
>  The servlet was marked as unavailable because it failed to
> initialize.
>
>  This:
>  > java.lang.ClassCastException: org.apache.jasper.servlet.JspServlet
>  > cannot be cast to javax.servlet.Servlet
>
>  means that your libraries are messed up.
>
>  Specifically, that classes named
>  "org.apache.jasper.servlet.JspServlet" and "javax.servlet.Servlet"
>  were loaded by different classloaders and thus are not compatible.
>
>  Read
>  http://tomcat.apache.org/tomcat-7.0-doc/class-loader-howto.html [3]
>
>  and make sure that your web application does not redistribute Tomcat
>  libraries inside of its WEB-INF/lib directory.
>
>  I see that you are using Maven to build the project. It is known that
>  it can pull in a lot of odd stuff if not used correctly. There were
>  other users experiencing similar issue before, so search the archives
>  of this mailing list.
>
>  Best regards,
>  Konstantin Kolinko
>

1. Do not top-post
2. That server where it fails is your system. We do not have access to
it and we do not know anything about its actual configuration.
http://www.catb.org/~esr/faqs/smart-questions.html

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: INFO: Marking servlet jsp as unavailable

Posted by "Majin_Clodan@t-online.de" <Ma...@t-online.de>.
Hello, 

	thanks for your reply. 

	But I don't think that this is the solution. I could make this on my
system without errors. Then I installed a virtual machine (Vagrant)
and in this machine it isn't working. I have everything installed,
Path's and Codes are the same. Do you have any idea why it work on my
system but not in my virtual machine (Vagrant)? It is the same OS as
well. 

	Greetings, Clodan  

	  Von: Konstantin Kolinko <kn...@gmail.com>
 An: Tomcat Users List <us...@tomcat.apache.org>
 Betreff: Re: INFO: Marking servlet jsp as unavailable
 Datum: Thu, 11 Oct 2012 12:30:55 +0200

 2012/10/10 Majin_Clodan@t-online.de [1] <Majin_Clodan@t-online.de
[2]>:
 > INFO: Marking servlet jsp as unavailable
 > Oct 10, 2012 8:25:06 AM org.apache.catalina.core.StandardContext
 > loadOnStartup
 > SEVERE: Servlet /kornakapi threw load() exception
 > java.lang.ClassCastException: org.apache.jasper.servlet.JspServlet
 > cannot be cast to javax.servlet.Servlet
 >

 > I think that I get the error because of:
 > INFO: Marking servlet jsp as unavailable
 > but  I don't know how to fix this. Does anyone know this error and
how
 > to  fix this? I try it the last 2 days but I can't fix it. :( I
tried
 > so  much things but without success... :(
 >

 The servlet was marked as unavailable because it failed to
initialize.

 This:
 > java.lang.ClassCastException: org.apache.jasper.servlet.JspServlet
 > cannot be cast to javax.servlet.Servlet

 means that your libraries are messed up.

 Specifically, that classes named
 "org.apache.jasper.servlet.JspServlet" and "javax.servlet.Servlet"
 were loaded by different classloaders and thus are not compatible.

 Read
 http://tomcat.apache.org/tomcat-7.0-doc/class-loader-howto.html [3]

 and make sure that your web application does not redistribute Tomcat
 libraries inside of its WEB-INF/lib directory.

 I see that you are using Maven to build the project. It is known that
 it can pull in a lot of odd stuff if not used correctly. There were
 other users experiencing similar issue before, so search the archives
 of this mailing list.

 Best regards,
 Konstantin Kolinko

 ---------------------------------------------------------------------
 To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org [4]
 For additional commands, e-mail: users-help@tomcat.apache.org [5]

Links:
------
[1] javascript:void(0)
[2] javascript:void(0)
[3]
?ctl=dereferer&amp;to=aHR0cDovL3RvbWNhdC5hcGFjaGUub3JnL3RvbWNhdC03LjAtZG9jL2NsYXNzLWxvYWRlci1ob3d0by5odG1s
[4] javascript:void(0)
[5] javascript:void(0)

Re: INFO: Marking servlet jsp as unavailable

Posted by Konstantin Kolinko <kn...@gmail.com>.
2012/10/10 Majin_Clodan@t-online.de <Ma...@t-online.de>:
> INFO: Marking servlet jsp as unavailable
> Oct 10, 2012 8:25:06 AM org.apache.catalina.core.StandardContext
> loadOnStartup
> SEVERE: Servlet /kornakapi threw load() exception
> java.lang.ClassCastException: org.apache.jasper.servlet.JspServlet
> cannot be cast to javax.servlet.Servlet
>

> I think that I get the error because of:
> INFO: Marking servlet jsp as unavailable
> but  I don't know how to fix this. Does anyone know this error and how
> to  fix this? I try it the last 2 days but I can't fix it. :( I tried
> so  much things but without success... :(
>

The servlet was marked as unavailable because it failed to initialize.

This:
> java.lang.ClassCastException: org.apache.jasper.servlet.JspServlet
> cannot be cast to javax.servlet.Servlet

means that your libraries are messed up.

Specifically, that classes named
"org.apache.jasper.servlet.JspServlet" and "javax.servlet.Servlet"
were loaded by different classloaders and thus are not compatible.

Read
http://tomcat.apache.org/tomcat-7.0-doc/class-loader-howto.html

and make sure that your web application does not redistribute Tomcat
libraries inside of its WEB-INF/lib directory.

I see that you are using Maven to build the project. It is known that
it can pull in a lot of odd stuff if not used correctly. There were
other users experiencing similar issue before, so search the archives
of this mailing list.


Best regards,
Konstantin Kolinko

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org