On Mon, May 14, 2001 at 07:38:25PM +0530, Madhu wrote:
> Hi All,
> I have a SessionBean, in which I have the method addNet(). The
> deployment process went on fine. When I try to access, first I try to get the
> Home Interface of the SessionBean, That works fine. I am able to get the
> Interface of the SessionBean. When I try to access a method of the SessionBean
> through my client, I am getting a java.lang.NoSuchMethodError. I am able to see
> this Error in the Client console. Nothing is happening in my Jboss Server
> console, It just stops there after this Error Occurs.
> In the ejb-jar.xml, I have the entry for this method addNet()
> pertaining to the SessionBean. I am unable to understand as to why I am getting
> this problem.
>
> My Client Code call the method using the following code:
> xxx home = (xxx)ctx.lookup("xyz");
> home.addNet( abc,bbc);
You're trying to invoke the method on the home interface. I think you
want to invoke it on the remote interface. You need to call create on
the home interface in order to get the remote interface.
The fact that this code compiled for you implies that you put the method
in the home interface. I'm not sure if you can define home methods for
session beans, but that doesn't seem to be what you want anyway.
> where abc is a String Parameter and bbc is a Serailizable object.
>
> Code inside the Session Bean is as follows
> public void addNE(String abc, NetData bbc) throws RemoteException
> {
> few lines of code
> }
Please try to be a little bit more careful when including bits of code. The
thing that stands out there is that the method is called "addNE", not
"addNet". This isn't the problem, though.
Get your home/remote interfaces sorted out.
Toby.
_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/jboss-user