This week's book giveaways are in the Java EE and JavaScript forums.
We're giving away four copies each of The Java EE 7 Tutorial Volume 1 or Volume 2(winners choice) and jQuery UI in Action and have the authors on-line!
See this thread and this one for details.
The moose likes EJB and other Java EE Technologies and the fly likes Universal Test Client with EJB Websphere Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of The Java EE 7 Tutorial Volume 1 or Volume 2 this week in the Java EE forum
or jQuery UI in Action in the JavaScript forum!
JavaRanch » Java Forums » Java » EJB and other Java EE Technologies
Bookmark "Universal Test Client with EJB Websphere" Watch "Universal Test Client with EJB Websphere" New topic
Author

Universal Test Client with EJB Websphere

pramesh babu
Greenhorn

Joined: Feb 21, 2006
Posts: 2
Hi,

I developed an ejb application. I developed a universal test client.
The business logic method which i have written is argumented. When we are testing ejb applicatin with Universal test client, i should see text box to enter value for that arguments. But i am not getting that provision.

The method definition is like this:

private long [] employeeIDs = { 10010, 10023, 10045, 10051, 10061 };
private String [] employees = {"Frank", "Sam", "Maddy", "Jack", "Lorette" };

public String getEmployeeName( long employeeID )
throws javax.ejb.CreateException, java.rmi.RemoteException
{
for ( int i=0; i < employees.length; i++ )
{
if ( employeeIDs[ i ] == employeeID )
{
return employees[ i ];
}
}
return "ramesh";
}

Please help me. Thanks in advance
Ron V.
Greenhorn

Joined: Dec 30, 2002
Posts: 5
If this is your businessmethod (so the one in the bean) than it should never throw a RemoteException. The RemoteException must be declared in the component interface (the one that extends EJBObject), but never in the actual bean (the class implementing the SessionBean/EntityBean interface).

Could be the container has some clue in it's errorlog.

Also, CreateException should be thrown from a create<method>(), not from a normal businessmethod, but I do not think this caused your problem.
pramesh babu
Greenhorn

Joined: Feb 21, 2006
Posts: 2
Originally posted by Ron V.:
If this is your businessmethod (so the one in the bean) than it should never throw a RemoteException. The RemoteException must be declared in the component interface (the one that extends EJBObject), but never in the actual bean (the class implementing the SessionBean/EntityBean interface).

Could be the container has some clue in it's errorlog.

Also, CreateException should be thrown from a create<method>(), not from a normal businessmethod, but I do not think this caused your problem.


----

Hi, thanks for reply.

I removed the RemoteException and CreateException. But still i am getting the same screen where i am not getting any provision to enter argumented values to business logic method.

Please help.

Thanks in advance.
 
Consider Paul's rocket mass heater.
 
subject: Universal Test Client with EJB Websphere