[[Creating_EclipseLink_Files_for_Deployment_%28ELUG%29#sessions.xml_File|The EclipseLink DBWS Service sessions.xml file (<tt><b>eclipselink-dbws.xml</b></tt>) is described in full in the User Guide]].

[[Creating_EclipseLink_Files_for_Deployment_%28ELUG%29#sessions.xml_File|The EclipseLink DBWS Service sessions.xml file (<tt><b>eclipselink-dbws.xml</b></tt>) is described in full in the User Guide]].

===== EclipseLink DBWS mapping files =====

===== EclipseLink DBWS mapping files =====

−

[[xxx|The EclipseLink DBWS Service mapping files (<tt><b>eclipselink-dbws-or.xml,eclipselink-dbws-ox.xml</b></tt>) are described in full in the User Guide]].

+

[[Creating_EclipseLink_Files_for_Deployment_%28ELUG%29#project.xml_File|The EclipseLink DBWS Service mapping files (<tt><b>eclipselink-dbws-or.xml,eclipselink-dbws-ox.xml</b></tt>) are described in full in the User Guide]].

A runtime provider component that takes a service descriptor (along with related deployment artifacts) and realizes it as a JAX-WS 2.0 Web service. The runtime provider uses EclipseLink to bridge between the database and the XML SOAP Messages used by Web service clients.

An EclipseLink DBWS service may include any number of the following operations:

insert - inserts into the database persistent entities described by an XML document.

delete - removes from the database persistent entities described by an XML document.

query - retrieves from the database persistent entities described by an XML document. Selection criteria for Query operations can be specified by:

custom SQL SELECT statement

Stored Procedure invocation

EclipseLink Named Query (that can use the complete range of EclipseLink ORM Expression Framework APIs)

XML-to-Relational Mapping (XRM)

EclipseLink's ORM and OXM features provides the basis for a powerful bridge between a database's relational structure(s) and XML's hierarchical structure.

Configuration

A typical EclipseLink DBWS service is packaged in an archive (.jar or .war file) with a service descriptor file in the META-INF directory (or WEB-INF/classes/META-INF when packaged in a .war file).
To bridge the relational database and XML worlds, an EclipseLink sessions.xml file points
to two Eclipse projects - one for the ORM side, the other for the OXM side. The service also requires an XML Schema Definition file (.xsd) which in conjunction with the OXM project, specifies how information from the database is to be 'shaped' into XML.

root of archive {not all files displayed ...}
\---META-INF
| eclipselink-dbws.xml
| eclipselink-dbws-sessions.xml -- name can be overriden by <sessions-file> entry in eclipselink-dbws.xml
| eclipselink-dbws-or.xml
| eclipselink-dbws-ox.xml
| eclipselink-dbws-schema.xsd -- when deployed in a .war file, located in a different directory

EclipseLink DBWS mapping files

EclipseLink DBWS Service schema file

The EclipseLink DBWS Service schema file (eclipselink-dbws-schema.xsd) can be created by hand,
or auto-generated by the DBWSBuilder utility which derives XML element-tag names from Database metadata
(column names, types, nullable, etc).

Simple XML Format (SXF)

The DBWSBuilder utility will not generate a schema file when the information returned by a query operation has no pre-determined structure:

a resultSet from a custom SQL query operation

the results from a Stored Procedure query operation

the row-count from an update operation

In these cases, the EclipseLink DBWS runtime provider uses the resultSet's metadata to build the XML element tag names: