http://www.huihoo.com/jboss/examples/jaws.htm Install JAWS Example JBoss JAWS Example converted to Eclipse project.Click File, click Import..., click Existing Project into Workspace, click Next, click Browse..., navigate to C:\eclipse\workspace\jaws, click Finish. Expand jaws project in Eclipse. Right click on build.xml, click Run Ant..., check ear-dir and click Finish. Click jaws project, click Project, click Rebuild Project. You do not need to run the Ant script again unless you change a deployment descriptors in the resources folder. From My Computer navigate to %JBOSS_DIST%\server\default\conf, open jboss-service.xml in Wordpad, go to line with: <attribute name="URLs"> ./deploy </attribute>Right after ./deploy add ,C:\eclipse\workspace\jaws\jaws.ear so it should look like: <attribute name="URLs"> ./deploy, C:\eclipse\workspace\jaws\jaws.ear </attribute> Save changes and exit Wordpad. Working with the JAWS Example in Eclipse Run Eclipse, in Package Explorer you should see jaws. jaws contains all the EJBs for the Jaws Example. It uses one source folder src, has two packages org.jboss.docs.cmp.jaws.bean, org.jboss.docs.cmp.jaws.interfaces, which contain the EJB source, and an ant file build.xml to build the ear folder. Click JBoss, Start JBoss (if not already started) and wait for:10:33:48,077 INFO [Server] JBoss (MX MicroKernel) [3.0.1RC1 Date:200206291622] Started in 0m:12s:125msin the Console output. This means JBoss is up and running. Look for the following in the console: 11:36:35,806 INFO [MainDeployer] Starting deployment of package: file:/C:/eclipse/workspace/jaws/jaws.ear/jaws.jar/ 11:36:35,993 INFO [EjbModule] Creating 11:36:36,009 INFO [EjbModule] Deploying ClassBean 11:36:36,603 INFO [JDBCInitCommand] Created table 'CLASS' successfully. 11:36:36,634 INFO [EjbModule] Created 11:36:36,634 INFO [EjbModule] Starting 11:36:36,743 INFO [EjbModule] Started 11:36:36,743 INFO [MainDeployer] Deployed package: file:/C:/eclipse/workspace/jaws/jaws.ear/jaws.jar/ 11:36:36,743 INFO [MainDeployer] Starting deployment of package: file:/C:/eclipse/workspace/jaws/jaws.ear/META-INF/ 11:36:36,743 INFO [MainDeployer] Deployed package: file:/C:/eclipse/workspace/jaws/jaws.ear/META-INF/ This shows table using the JAWS mapping was created OK and the EJB deployed.
Install JAWS Example
JBoss JAWS Example converted to Eclipse project.Click File, click Import..., click Existing Project into Workspace, click Next, click Browse..., navigate to C:\eclipse\workspace\jaws, click Finish.
Expand jaws project in Eclipse.
Right click on build.xml, click Run Ant..., check ear-dir and click Finish.
Click jaws project, click Project, click Rebuild Project. You do not need to run the Ant script again unless you change a deployment descriptors in the resources folder.
From My Computer navigate to %JBOSS_DIST%\server\default\conf, open jboss-service.xml in Wordpad, go to line with:
<attribute name="URLs">
./deploy
</attribute>Right after ./deploy add ,C:\eclipse\workspace\jaws\jaws.ear so it should look like: <attribute name="URLs">
./deploy,
C:\eclipse\workspace\jaws\jaws.ear
</attribute>
Save changes and exit Wordpad.
Working with the JAWS Example in Eclipse
Run Eclipse, in Package Explorer you should see jaws. jaws contains all the EJBs for the Jaws Example. It uses one source folder src, has two packages org.jboss.docs.cmp.jaws.bean, org.jboss.docs.cmp.jaws.interfaces, which contain the EJB source, and an ant file build.xml to build the ear folder. Click JBoss, Start JBoss (if not already started) and wait for:10:33:48,077 INFO [Server] JBoss (MX MicroKernel) [3.0.1RC1 Date:200206291622] Started in 0m:12s:125msin the Console output. This means JBoss is up and running.
Look for the following in the console:
11:36:35,806 INFO [MainDeployer] Starting deployment of package: file:/C:/eclipse/workspace/jaws/jaws.ear/jaws.jar/
11:36:35,993 INFO [EjbModule] Creating
11:36:36,009 INFO [EjbModule] Deploying ClassBean
11:36:36,603 INFO [JDBCInitCommand] Created table 'CLASS' successfully.
11:36:36,634 INFO [EjbModule] Created
11:36:36,634 INFO [EjbModule] Starting
11:36:36,743 INFO [EjbModule] Started
11:36:36,743 INFO [MainDeployer] Deployed package: file:/C:/eclipse/workspace/jaws/jaws.ear/jaws.jar/
11:36:36,743 INFO [MainDeployer] Starting deployment of package: file:/C:/eclipse/workspace/jaws/jaws.ear/META-INF/
11:36:36,743 INFO [MainDeployer] Deployed package: file:/C:/eclipse/workspace/jaws/jaws.ear/META-INF/
This shows table using the JAWS mapping was created OK and the EJB deployed.
Home | JBoss Examples Last updated on 08/07/2002
我的JDK也是1.4.2的我也没有找到你说的那个文件,
好些书上说的要在环境变量里要配置的这个东东,我估计是指1.5的,不是指1.4的.