IntelliJ Java IDE
The moose likes Websphere and the fly likes Cannot find method Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Products » Websphere
Reply Bookmark "Cannot find method" Watch "Cannot find method" New topic
Author

Cannot find method

ssv
Greenhorn

Joined: Dec 06, 2001
Posts: 2
Hi,
I have added a method to an already existing Session Bean using Visual Age for Java. I generated the Deployed Code and this EJB is called from a Servlet. I found this working as desired using the WebSphere Test Environment in VAJ. But when i deploy the EJB to a Websphere Application Server and request the servlet .. I get an error message saying that the method I created newly is not found.
Its quite confusing to me to understand why the servlet and ejb that work in VAJ test environment do not work in WAS.
Please tell me if I am doing anything wrong or missing anything.
Any help/suggestion is appreciated.
Also please find a copy of the error message that I find.

Original Error:
Error Message: Server caught unhandled exception from servlet [PlaceOrder]: com.thermo.commerce.OrderProcess: method placeOrderPO(JJLjava/lang/String I not found
Error Code: 500
Target Servlet: PlaceOrder
Error Stack:

--------------------------------------------------------------------------------
Root Error-1: com.thermo.commerce.OrderProcess: method placeOrderPO(JJLjava/lang/String I not found
java.lang.NoSuchMethodError: com.thermo.commerce.OrderProcess: method placeOrderPO(JJLjava/lang/String I not found
at com.thermo.commerce.PlaceOrderServlet.performTaskConcrete(PlaceOrderServlet.java:86)
at com.thermo.commerce.CommerceServlet.performTask(Compiled Code)
at com.thermo.commerce.PlaceOrderServlet.doGet(Compiled Code)
at javax.servlet.http.HttpServlet.service(Compiled Code)
at javax.servlet.http.HttpServlet.service(Compiled Code)
at com.ibm.servlet.engine.webapp.StrictServletInstance.doService(Compiled Code)
at com.ibm.servlet.engine.webapp.StrictLifecycleServlet._service(Compiled Code)
at com.ibm.servlet.engine.webapp.IdleServletState.service(Compiled Code)
at com.ibm.servlet.engine.webapp.StrictLifecycleServlet.service(Compiled Code)
at com.ibm.servlet.engine.webapp.ServletInstance.service(Compiled Code)
at com.ibm.servlet.engine.webapp.ValidServletReferenceState.dispatch(Compiled Code)
at com.ibm.servlet.engine.webapp.ServletInstanceReference.dispatch(Compiled Code)
at com.ibm.servlet.engine.webapp.WebAppRequestDispatcher.handleWebAppDispatch(Compiled Code)
at com.ibm.servlet.engine.webapp.WebAppRequestDispatcher.dispatch(Compiled Code)
at com.ibm.servlet.engine.webapp.WebAppRequestDispatcher.forward(Compiled Code)
at com.ibm.servlet.engine.srt.WebAppInvoker.handleInvocationHook(Compiled Code)
at com.ibm.servlet.engine.invocation.CachedInvocation.handleInvocation(Compiled Code)
at com.ibm.servlet.engine.invocation.CacheableInvocationContext.invoke(Compiled Code)
at com.ibm.servlet.engine.srp.ServletRequestProcessor.dispatchByURI(Compiled Code)
at com.ibm.servlet.engine.oselistener.OSEListenerDispatcher.service(Compiled Code)
at com.ibm.servlet.engine.oselistener.SQEventListenerImp$ServiceRunnable.run(Compiled Code)
at com.ibm.servlet.engine.oselistener.SQEventListenerImp.notifySQEvent(Compiled Code)
at com.ibm.servlet.engine.oselistener.serverqueue.SQEventSource.notifyEvent(Compiled Code)
at com.ibm.servlet.engine.oselistener.serverqueue.SQWrapperEventSource$SelectRunnable.notifyService(Compiled Code)
at com.ibm.servlet.engine.oselistener.serverqueue.SQWrapperEventSource$SelectRunnable.run(Compiled Code)
at com.ibm.servlet.engine.oselistener.outofproc.OutOfProcThread$CtlRunnable.run(Compiled Code)
at java.lang.Thread.run(Compiled Code)
Matthew X. Brown
Ranch Hand

Joined: Nov 08, 2000
Posts: 165
How are you calling the method- the easiest way would be to use VAJ's "Access Beans" functionality, that basically creates a facade type pattern with you EJBs-basically your access bean can hide much of the EJB's functionality from clients like servlets- but it allows you to expose what you want. That way you don't have to do any type of lookup using jndi.
ssv
Greenhorn

Joined: Dec 06, 2001
Posts: 2
Thanks Mathew,
I was not too familiar with VAJ. I figured out what the problem was, I did not have my updated client jar in WAS. Thats the reason the new method I added was not to be found.
Thanks
sakthi
 
 
subject: Cannot find method
 
Threads others viewed
class switcheroo
Ljava error
dom4j errors with Websphere Application Server 3.5.7
error in converting XML to HTML using xalan
setAttribute / getAttribute
IntelliJ Java IDE

cast iron skillet 49er

more from paul wheaton's glorious empire of web junk: cast iron skillet diatomaceous earth rocket mass heater sepp holzer raised garden beds raising chickens lawn care CFL flea control missoula heat permaculture