Hi All,
I am unable to run a simple HelloWorld
ejb .I am using websphere 4.0 .
I am get an error while deploying .
The code is as follows
**************HelloWorld .java*******************
package myejbpackage;
import javax.ejb.*;
import java.rmi.*;
public interface HelloWorldHome extends EJBHome
{
public HelloWorld create() throws RemoteException , javax.ejb.CreateException ;
}
*********HelloWorldBean ******************
package myejbpackage;
import java.rmi.RemoteException;
import java.util.Properties;
import javax.ejb.*;
public class HelloWorldBean implements SessionBean {
public void ejbActivate() {}
public void ejbCreate() {}
public void ejbPassivate() {}
public void ejbRemove() throws java.rmi.RemoteException {}
public
String getTextMessage() {
return "hello world";
}
public void setSessionContext(SessionContext ctx)
{
}
}
************HelloWorldHome .java
package myejbpackage;
import javax.ejb.*;
import java.rmi.*;
public interface HelloWorldHome extends EJBHome {
public HelloWorld create() throws RemoteException , javax.ejb.CreateException ;
}
******************************************************************
All these files reside in C:\JDK..\bin\myejbpackage
I compile these
C:\jdk1.3.1_02\bin>javac myejbpackage\*.java
C:\jdk1.3.1_02\bin>jar cvf HelloWorld.jar myejbpackage\*.class
*************************************************
I deploy these in AAT and I save archive as hello.jar in C:\jdk..\bin.
After I click Generate Now button it gives the following o/p with an error at the end.
Starting workbench.
Creating the project.
Creating EJB Project...
Creating EJB Project... Opening: /Deployed_hello.jar.
Creating EJB Project...
Creating EJB Project... Setting classpath...
Creating EJB Project...
Updating.
Importing EJB Jar.. Importing Jar..
Importing file..
Updating.
Generating deployment code
Processing session bean: HelloWorld
Committing working copy...
Updating.
Committing working copy...
Updating.
Committing working copy...
Updating.
Building: /Deployed_hello.jar.
Invoking
Java Builder on /Deployed_hello.jar.
Scrubbing output folder
Analyzing packages
Analyzing sources
Compiling content of ejbModule/myejbpackage
(1 problem found) Copying all resources on the classpath
(1 problem found) Build done
Java build completed
Invoking Validation on /Deployed_hello.jar.
ejbModule/myejbpackage/EJSRemoteStatefulHelloWorld.java(-1): This compilation
unit indirectly references the missing type myejbpackage.HelloWorld (typically some required class file is referencing a type outside the classpath)
Shutting down workbench.
Execution Halted: Compilation Errors Reported
1 Errors, 0 Warnings, 0 Informational Messages.
Please advice where am I going wrong???
Thanks in advance.
Buggi.