10.12.2012 Views

The Java EE 5 Tutorial (PDF) - Oracle Software Downloads

The Java EE 5 Tutorial (PDF) - Oracle Software Downloads

The Java EE 5 Tutorial (PDF) - Oracle Software Downloads

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Further Information aboutWeb Applications<br />

Creating a Data Source in the Application Server<br />

A DataSource object has a set of properties that identify and describe the real world data source<br />

that it represents. <strong>The</strong>se properties include information such as the location of the database<br />

server, the name of the database, the network protocol to use to communicate with the server,<br />

and so on.<br />

Data sources in the Application Server implement connection pooling. To define the Duke’s<br />

Bookstore data source, you use the installed Derby connection pool named DerbyPool.<br />

You create the data source using the Application Server Admin Console, following this<br />

procedure:<br />

1. Expand the Resources node.<br />

2. Expand the JDBC node.<br />

3. Select the JDBC Resources node.<br />

4. Click the New... button.<br />

5. Type jdbc/BookDB in the JNDI Name field.<br />

6. Choose DerbyPool for the Pool Name.<br />

7. Click OK.<br />

Further Information aboutWeb Applications<br />

98<br />

For more information on web applications, see:<br />

■ <strong>The</strong> <strong>Java</strong> Servlet specification:<br />

http://java.sun.com/products/servlet/download.html#specs<br />

■ <strong>The</strong> <strong>Java</strong> Servlet web site:<br />

http://java.sun.com/products/servlet<br />

<strong>The</strong> <strong>Java</strong> <strong>EE</strong> 5<strong>Tutorial</strong> • June 2010

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!