Note: Transfer from http://blog.9cbs.net/ezerg/archive/2004/09/30/121476.aspx releases a web application, package into a WAR file. Release an EJB component separately and package it into a JAR file. For a J2EE app, you should be packaged as an EAR file.
Deploy EJB components on JBoss-Tomcat
Deploy to the directory:
/ Related Categories / Meta-INF / EJB-jar.xml / meta-inf /jboss.xml
EJB.XML file
XML Version = "1.0" Encoding = "UTF-8"?>
JBoss.xml file
XML Version = "1.0" Encoding = "UTF-8"?>
Make a JAR package, copy the file to the publisher.
Deploy web application on JBoss-Tomcat
Keep the original directory structure, the only change should add a JBoss-web.xml file under the web-inflicity
Xml Version = "1.0" encoding = "ISO-8859-1"?>
Web.xml
XML Version = "1.0" encoding = "ISO-8859-1"?>
web-app>
In the above code, the reference to BookDbejb is declared, the
InitialContext IC = New InitialContext (); Object Objref = IC.LOOKUP ("Java: Comp / ENV / EJB / BOOKDBEJB");
Access the EJB component in the program, you can specify
Make a WAR package, copy the file to the publisher.
Deploy J2EE app on JBoss-Tomcat
/ EJB component (* .jar file) / web application (* .war file) /meta-inf/application.xml
Application.xml file
XML Version = "1.0" encoding = "UTF-8"?>
application>
Pracing the EAR package, copy the file to the publisher