• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Http 500 error

 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello All
could anyone help me out.
whenever i am trying to run my tomcat server to invoke a servlet,it always displays this error

HTTP Status 500 -

--------------------------------------------------------------------------------

type Exception report

message

description The server encountered an internal error () that prevented it from fulfilling this request.

exception

javax.servlet.ServletException: Error instantiating servlet class MyServlet
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:825)
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:738)
org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:526)
org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
java.lang.Thread.run(Unknown Source)


root cause

java.lang.IllegalAccessException: Class org.apache.catalina.core.StandardWrapper can not access a member of class MyServlet with modifiers ""
sun.reflect.Reflection.ensureMemberAccess(Unknown Source)
java.lang.Class.newInstance0(Unknown Source)
java.lang.Class.newInstance(Unknown Source)
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:825)
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:738)
org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:526)
org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
java.lang.Thread.run(Unknown Source)


note The full stack trace of the root cause is available in the Apache Tomcat/5.5.7 logs.


--------------------------------------------------------------------------------

Apache Tomcat/5.5.7
if anyone knows the solution of this please mail me the answer on meenakshi.ahuja02@gmail.com
 
Ranch Hand
Posts: 107
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I think your servlet class or one of its member has wrong access modifier.

I'm not sure what is wrong without viewing your code,
but I think your servlet class and/or its member(s) have package-private (=default) access,
and container is complaining about that.
[ September 02, 2008: Message edited by: Bupjae Lee ]
 
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
check all required class files available and having proper access modifiers
 
Ranch Hand
Posts: 52
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Dear,

From stack trace i can say that your MyServlet servlet have access modifier problem. Please check any default method access modifier, they all need to be public.
 
Ranch Hand
Posts: 51
Eclipse IDE Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello All,
I had a similar problem but the reason which I found out was quite different.I work on the same project from two different locations one from home and other from office through different systems.I am using Eclipse as IDE on both locations. I exported my servlets and jsp from office to home. Then I changed Server Settings(Apache 7) and my servlets were running fine. But when I created a new servlet it failed to instantiate. It was showing the same error code and message as your problem suggests. It took me some time to solve the problem by hit and trial method by when I excluded the earlier version and location of Apache ( Jar file from Java Build Path-Library in Eclipse) the problem solved for me miraculously. I wish it can be useful for you only if you are having same problem scenario.

Thanks
Vivek Agrawal
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic