Identify three of these steps.

When a typical application utilizes a JDBC data source, the process involves several steps.
Identify three of these steps.

When a typical application utilizes a JDBC data source, the process involves several steps.
Identify three of these steps.

A.
The application returns the connection to the data source.

B.
The application looks up the data source using the JNDI name.

C.
The application tests the connection to verify the database’s availability.

D.
The application adds a new connection to the data source if none are available.

E.
The application requests a connection from the data source.

Explanation:
Applications look up the data source on the JNDI tree or in the local application
context (B) and then reserve a database connection with the getConnection (E) method. Data
sources and their connection pools provide connection management processes that help keep
your system running and performant.
B: JNDI Name – Enter the JNDI path to where this JDBC data source will be bound. Applications

look up the data source on the JNDI tree by this name when reserving a connection.
Note: If you’ve done any work with JDBC DataSources in a Web application, you already
understand the basic process: create an initial JNDI (Java Naming and Directory Interface)
context, then use the context to perform a “lookup” to retrieve your DataSource.
Reference: Administration Console Online Help, Create JDBC data sources
http://docs.oracle.com/cd/E15051_01/wls/docs103/ConsoleHelp/taskhelp/jdbc/jdbc_datasources/C
reateDataSources.html



Leave a Reply 6

Your email address will not be published. Required fields are marked *


Dell Minion

Dell Minion

I don’t think D is correct. The application can’t create new connections to the datasource if the connection pool is used up. Correct ans should be A- The connection is given back to the connection pool.

cnskylee

cnskylee

Yes, I agree with you. The application first look up the datasource using JNDI name,and then request a connection to the datasource to execute CURD operation, at last return the connection to the datasource .

SNLEt

SNLEt

I think correct answer is A, B, E

cnskylee

cnskylee

Each JDBC data source has a pool of JDBC connections that are created when the data source is deployed or at server startup. Applications use a connection from the pool then return it when finished using the connection. That is what I refer from Oracle official website.So I agree with you that A. is the right answer.D is wrong because a new connection of data source is produced by weblogic not the application.
So the right answer to this question is ABE

raul

raul

i think D is wrong