|Home > Documentation > Developing > Tutorials > Developing application clients > Deploying and running EJB application clients|
This tutorial walks you through configuring, developing and deploying an enterprise application with Eclipse and Geronimo. To run this tutorial, as a minimum you will be required to have installed the following prerequisite software.
Details on installing eclipse are provided in the Development environment section. This tutorial is organized in the following sections:
Let us briefly understand this application. This application will take you through creating a simple Stateless Session EJB. Later we will develop a Java Application client to access this EJB. EJB development will make use of annotations which are introduced in Java EE5.
This completes the setting of Eclispe IDE for EJB application development.
This completes the development of EJB application.
ApplicationClient.javaclass with the following code:
org.apache.openejb.client.RemoteInitialContextFactoryto create the InitialContext. In this case as the EJB server is the naming service provider and has naming service runnning at Port 4201. So we need to specify the location of the EJB server. In this case it is
ejbd://localhost:4201. Once this is done we have the context that provides us the ability to lookup and get objects.
org.apache.openejb.client.RemoteInitialContextFactoryclass to the build path. This is because the application client needs this class to create the InitialContext as explained above.
<GERONIMO_HOME>\repository\org\apache\openejb\openejb-client\3.0and select the jar openejb-client-3.0.jar. Select OK.
This completes the Application Client Development.
This section will take you through the deployment of the EJB application. Later we will run the application client with some sample inputs.
<GERONIMO_HOME>/var/log/geronimo.logand find the following: The OpenEJB container is now aware of both the Remote as well as the Local lookup names. In this tutorial the SimpleEJB application and Java Application Client are running under different JVM instances, so we need to have the CountryCapitalBeanRemote as the lookup name for remote access.
Sample Input #1: India
Sample Input #2: China
Sample Input #3: United States Of America
Sample Input #4: France