aspose file tools*
The moose likes Websphere and the fly likes Error at Deployment of my Stateful Session Bean in WAS 4.0 Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Products » Websphere
Bookmark "Error at Deployment of my Stateful Session Bean in WAS 4.0 " Watch "Error at Deployment of my Stateful Session Bean in WAS 4.0 " New topic
Author

Error at Deployment of my Stateful Session Bean in WAS 4.0

Harish
Greenhorn

Joined: Feb 18, 2002
Posts: 1
Hi Friends,
I'm encountering a very unique problem when im trying to deploy a
executable jar file using the Application Deployment tool provided by
WAS4.0. I'm trying to deploy using just 3 class files zipped into jar,
which contains the remote, home and the bean classes. when i try to
verify the code it's giving me the following error. i tried compiling
the 3 java files using j2ee.jar( i'm using ejb 1.1), provided bi both
sun as well as IBM but still im not able to generate the executable
jar file.
im really not sure where the error is occuring, the bean is a stateful
session bean, which i mention in the application assembly tool.
i will also send the 3 java files so if u can find any basic error
that im doing which ejb 1.1 doesnt allow...
this is the error that im encountering.
-------------------------------------------------
Validating EJB module deployment descriptor
Validating card.Card.
CHKJ2012E: The interface class card.Card for enterprise bean CardEJB
is not a valid interface. Possible cause: The interface class is not
public or is an abstract class.
CHKJ2017E: Interface CardEJB of enterprise bean card.Card does not
extend the javax.ejb.EJBObject interface. Read section 6.10.5 (session
beans) or 9.2.7 (entity beans) of the EJB 1.1 specification for
details.
Validating card.CardBean.
CHKJ2013E: The card.CardBean enterprise bean does not implement the
javax.ejb.SessionBean interface. Read section 6.10.2 (session beans)
or 9.2.2 (entity beans) of the EJB 1.1 specification for details.
CHKJ2022E: The card.CardBean enterprise bean is not defined as public.
Read section 6.10.2 (session bean) or 9.2.2 (entity bean) of the EJB
1.1 specification for details.
CHKJ2008E: The card.CardBean enterprise bean must contain at least one
ejbCreate method. Read section 6.10.3 of the EJB 1.1 specification
for details.
Validating card.CardHome.
CHKJ2010E: The home interface card.CardHome for session bean CardEJB
must contain at least one create method. Read section 6.10.6 of the
EJB 1.1 specification for details.
Validating EJB module extensions
--------------------------------------------------------------------

//EJB REMOTE INTERFACE
package card;
import javax.ejb.*;
import java.rmi.RemoteException;
public interface Card extends EJBObject {
public void markCard (int holeNumber, int numShots) throws
RemoteException;

public int getScore (int holeNumber) throws RemoteException;

public String getPlayerName () throws RemoteException;

}
//EJB HOME INTERFACE
package card;
import javax.ejb.*;
import java.rmi.*;
public interface CardHome extends EJBHome {

public Card create(String playerName) throws CreateException,
RemoteException;

public Card create(String playerName, int [] scores) throws
CreateException, RemoteException;
}
//EJB BEAN CLASS
package card;
import javax.naming.*;
import javax.ejb.*;
public class CardBean implements SessionBean {
String playerName;
int[] scores;
SessionContext ctx;
public CardBean()
{}
public void markCard (int holeNumber, int numShots) {
scores[holeNumber] = numShots;
}
public int getScore (int holeNumber) {
return scores[holeNumber];
}

public String getPlayerName () {
return playerName;
}

public void ejbCreate (String playerName) {
this.playerName = playerName;
scores = new int[18];
}

public void ejbCreate (String playerName, int[] scores) {
this.playerName = playerName;
this.scores = scores;
}
public void ejbActivate () {}

public void ejbPassivate () {}
public void ejbRemove () {
playerName = null;
scores = null;
}
public void setSessionContext (SessionContext ctx) {
this.ctx = ctx;
}
}
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Error at Deployment of my Stateful Session Bean in WAS 4.0