For an EJB to access a COBOL service running on an enterprise server instance, you must have the EJB and a JSP client running on an application server. You can generate both an EJB and a JSP client from the IMTK simultaneously, and then configure your application server to run them.
The generated EJB and JSP client are packaged into archive files (.jar, .war, and .ear), together with manifest files and deployment descriptors. These files are located in the structure under your project's myService. deploy directory, where myService is the name of your service interface. You can view the contents of and/or extract individual files from these archives using the jar command or a zip utility. The following archive files are created:
ejb-jar.xml | Generic deployment descriptor, defining the EJB |
myServiceBean.class | Bean class for the EJB |
myServiceHome.class | Home interface for the EJB |
myService.class | Remote interface for the EJB |
myRecord.class | custom record, if needed by the EJB |
manifest.mf | Manifest describing this .jar file |
*.xml, such as weblogic-ejb-jar.xml | For some Java application servers (such as WebLogic), a deployment descriptor for deploying the EJB to that application server |
The source code for the EJB classes are generated in the directory com\mypackage\myService.
*.jsp | JSP files. These pass data back and forth between the end user and the servlet. |
myServiceJspBean.class | This file contains the getter and setter methods that are used to move information back and forth between the servlet and JSP. |
myServiceServlet.class | This file is the servlet. It processes the incoming requests from the JSP, invokes an instance of the stateless EJB, and forwards the response back to the JSP. |
myServiceSessionMonitor.class | This is a helper class, which stores the EJB instances for the stateful session bean. |
manifest.mf | Manifest describing this .war file |
mfejlib.jar | .. custom records |
web.xml | Generic deployment descriptor, defining the client servlet and the EJB reference |
*.xml, such as weblogic.xml | For some Java application servers (such as WebLogic), a deployment descriptor for deploying the .war file to that application server |
application.xml | Generic deployment descriptor, defining the .jar and the client .war files |
myService.jar | EJB Jar archive file |
myService.war | Client War archive file |
manifest.mf | Manifest describing this .jar file |
mfejlib.jar | Custom records |
To enhance its appearance and usability, you can optionally edit a JSP client. Before attempting to do so, you should first extract the JSP file from the myService.war archive file found in the deployment folder for your project.