Win a copy of Learn Spring Security (video course) this week in the Spring forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

How can i resolve this exception

 
nagaraj reddy
Ranch Hand
Posts: 43
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi ,

I am new to servlets. when i was trying to deploy my servlet in weblogic. i am invoking servlet through html page.

when i click submit in html page i am getting the fallowing exception..




Error 500--Internal Server Error
javax.servlet.ServletException: Servlet class: 'myserv' couldn't be instantiated
at weblogic.servlet.internal.ServletStubImpl.createServlet(ServletStubImpl.java:879)
at weblogic.servlet.internal.ServletStubImpl.createInstances(ServletStubImpl.java:842)
at weblogic.servlet.internal.ServletStubImpl.prepareServlet(ServletStubImpl.java:782)
at weblogic.servlet.internal.ServletStubImpl.getServlet(ServletStubImpl.java:504)
at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:349)
at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:305)
at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:6310)
at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:317)
at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:118)
at weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServletContext.java:3622)
at weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl.java:2569)
at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:197)
at weblogic.kernel.ExecuteThread.run(ExecuteThread




plz tell me where i am going wrong
 
Sergey Tyulkin
Ranch Hand
Posts: 87
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Maybe, your servlet
1) has no default constructor (i.e. constructor without parameters)
2) or, your forgot to implement Servlet (the easiest way - by extending GenericServlet or HttpServlet classes) interface?
 
nagaraj reddy
Ranch Hand
Posts: 43
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks for reply.


I got solution , i need to attach PUBLIC to the servlet class
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic