Skip Headers

# Session Configuration and the sessions.xml File

Previous

Next

TopLink provides two ways to configure your sessions: through Java code using the `Session` API, or using TopLink Workbench to build a session configuration file, the `sessions.xml` file.

In most cases, you configure sessions for the application using the `sessions.xml` file. This file is an Extensible Markup Language (XML) file that contains all sessions that are associated with the application. The `sessions.xml` file can contain any number of sessions and session types.

Oracle recommends that you use the `sessions.xml` file to deploy a TopLink application, because it provides the following advantages:

- It is easy to create and maintain in TopLink Workbench.

- It is easy to troubleshoot.

- It provides access to most session configuration options.

- It offers excellent flexibility, including the ability to modify deployed applications without recompiling.

For more information on creating a session in the `sessions.xml` file, see "Session Creation Overview".