# New JDBC Connection Pool: Add Connection Pool Properties

You see this page of the New File wizard when you are defining a connection pool and you have already named the connection pool and selected the database connection.

On this (and the Connection Pool Optional Settings page) you specify the properties of the connection pool. After entering the property values, you can do one of the following:

- Click Next if you want to further customize the optional pool properties such as pool size and connection validation.
- Click Finish to create the connection pool, leaving the optional settings at their default values.

The connection pool properties are added to glassfish-resources.xml. If you want to modify connection pool properties you can open glassfish-resources.xml in the Source Editor by locating the file in your project in the Projects window and double-clicking the file.

Element | Description
--- | ---
Datasource classname | The datasource class name is the JDBC driver that implements the APIs for the datasource. This name is provided according to the database connection selected in the previous screen. If you selected Other as the connection in the previous screen, you may need to add the datasource classname manually.
Resource type | The resource type reflects whether the connection pool enables XA global transactions or is restricted to local transactions. Return to the previous screen to change the resource type.
Description | You can enter a description of this connection pool.
Properties | Connection pool properties may vary according to the database vendor. Common properties include the datasource URL, user name, and password, but other properties may be suggested or required depending on the database connection. If you selected an existing source in the previous screen, some of the property values may already be provided. Properties may be changed or removed and additional properties may be added, but each property in the Properties area must have a value entered before you can proceed to the next screen or finish the connection pool configuration. To change a property, click a box in the Properties Name column, select a new property from the dropdown list and add a value for that property. To add a new property, click the Add button. A new row appears in the properties box. In the new row, click the box in the Properties Name column and select a property from the dropdown list, and add a value for that property. To remove a property click the row containing the propertyanc click the Remove button. Note: To complete the wizard you might need to supply the password for your database if the property field is empty. Use the character sequence open-parenthesis close-parenthesis, "()", to denote an empty string or blank password.

Related Topics

Developing Applications with NetBeans IDE,

Developing Applications with NetBeans IDE,

Copyright © 2016, Oracle and/or its affiliates. All rights reserved.