Win a copy of Programming with Types this week in the Angular and TypeScript forum
or The Design of Web APIs in the Web Services forum!
  • 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 all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Bear Bibeault
  • Paul Clapham
  • Jeanne Boyarsky
Sheriffs:
  • Junilu Lacar
  • Knute Snortum
  • Henry Wong
Saloon Keepers:
  • Ron McLeod
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
Bartenders:
  • Frits Walraven
  • Joe Ess
  • salvin francis

java.lang.NoSuchMethodError

 
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i am working with EJB20 using weblogic6.1
I successfully could run my servlet which was retrieving my session bean.
Now i added a new method in my session bean ,and compiled it successfully and deployed it .
But at run time an error come up saying
java.lang.NoSuchMethodError.

java.lang.NoSuchMethodError
at numbergroup.client.Client_cascadeDelete.doGet(Client_cascadeDelete.java:86)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:265)
at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:200)

This error is coming when i call my newly added remote method in the session bean.Other methods called in the session bean are working fine in the same code.
2) Which ID is best suited for debuggind EJB's and which can integrate with Weblogic6.1?
can somebody guide me !
Thanx
Nuts
 
Greenhorn
Posts: 17
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

This problem is usually caused if you have an older version of class file lying somewhere in your directory structure. It seems that your CLASSPATH is such that Class Loader is giving preference to the older version of the class file where the method you are trying to invoke does not exist and hence java.lang.NoSuchMethodError is raised.
Search for the older version of the class file in your directory structure and delete it to solve this problem.
HTH,
Milind
[ July 28, 2002: Message edited by: Milind V. Kulkarni ]
 
Nitin Raodeo
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi milind,
I have generated a jar file , with all the container required files (using ant utility).What i did was extracted that jar file , and saw if the new method was in that bean class to check if the older version of my class file was lying there. But the bean and the container generated both have the new method.
I can't figure out the problem.
can u please elaborate what u meant in ur previous mail.
Thanx in advance
Nitin.
 
Nitin Raodeo
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I could solve the problem , thanx to milind.
Nuts
 
She'll be back. I'm just gonna wait here. With this tiny ad:
Java file APIs (DOC, XLS, PDF, and many more)
https://products.aspose.com/total/java
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!