Setting the environment
We need to download and install JDeveloper 11 g Studio edition and WebLogic
Server 11 g , both of which are components of Oracle Fusion Middleware 11 g
index.html ). We will also need to create a new WebLogic domain with the Fusion
Middleware Configuration Wizard. As for the entity bean persistence, we need
to download and install Oracle Database 10 g XE ( http://www.oracle.com/
technology/software/products/database/index.html ). Create a user OE with
the following SQL commands:
CREATE USER OE IDENTIFIED BY pw;
GRANT CREATE SESSION, DBA to OE;
Create a test table CATALOG in database schema OE with the following SQL script:
CREATE TABLE Catalog (id INTEGER PRIMARY KEY NOT NULL,
journal VARCHAR(100), publisher VARCHAR(100),
edition VARCHAR(100), title VARCHAR(100),
Creating a JDeveloper application
First, we create an EJB 3.0 Application in JDeveloper. Here is how to do it:
1. Select New Application .
2. Specify an Application Name ( EJB3WebService ), select the Java EE
Web Application template, which consists of a Model project and a
ViewController project, and click on Next .
3. Next, specify the name ( ViewController ) for the View and Controller project.
4. In the Project Technologies tab, transfer the EJB project technology from the
Available list to the Selected list using the > button.
5. Click on Next .
6. Select the default Java settings for the View project and click on Next .
7. Configure the EJB Settings for the View project.
8. Select EJB Version as Enterprise JavaBeans 3.0 and select Using
9. Click on Next .
10. Next, create the Model project. Specify the Project Name ( EJB3Model ,
for example) and in the Project Technologies tab, transfer the EJB project
technology from the Available list to the Selected list using the > button.
Click on Next .