attributes.getNamedItem(STATEMENT_LEAK_TIMEOUT_IN_SECONDS);
Node statementLeakReclaimNode =
attributes.getNamedItem(STATEMENT_LEAK_RECLAIM);
org.glassfish.resources.api.Resource jdbcConnPool = new Resource(org.glassfish.resources.api.Resource.JDBC_CONNECTION_POOL);
jdbcConnPool.setAttribute(CONNECTION_POOL_NAME, name);
if(datasourceNode != null){
String datasource = datasourceNode.getNodeValue();
jdbcConnPool.setAttribute(DATASOURCE_CLASS, datasource);
}
if (nSteadyPoolSizeNode != null) {
String sSteadyPoolSize = nSteadyPoolSizeNode.getNodeValue();
jdbcConnPool.setAttribute(STEADY_POOL_SIZE, sSteadyPoolSize);
}
if (nMaxPoolSizeNode != null) {
String sMaxPoolSize = nMaxPoolSizeNode.getNodeValue();
jdbcConnPool.setAttribute(MAX_POOL_SIZE, sMaxPoolSize);
}
if (nMaxWaitTimeInMillisNode != null) {
String sMaxWaitTimeInMillis = nMaxWaitTimeInMillisNode.getNodeValue();
jdbcConnPool.setAttribute(MAX_WAIT_TIME_IN_MILLIS, sMaxWaitTimeInMillis);
}
if (nPoolSizeQuantityNode != null) {
String sPoolSizeQuantity = nPoolSizeQuantityNode.getNodeValue();
jdbcConnPool.setAttribute(POOL_SIZE_QUANTITY, sPoolSizeQuantity);
}
if (nIdleTimeoutInSecNode != null) {
String sIdleTimeoutInSec = nIdleTimeoutInSecNode.getNodeValue();
jdbcConnPool.setAttribute(IDLE_TIME_OUT_IN_SECONDS, sIdleTimeoutInSec);
}
if (nIsConnectionValidationRequiredNode != null) {
String sIsConnectionValidationRequired = nIsConnectionValidationRequiredNode.getNodeValue();
jdbcConnPool.setAttribute(IS_CONNECTION_VALIDATION_REQUIRED, sIsConnectionValidationRequired);
}
if (nConnectionValidationMethodNode != null) {
String sConnectionValidationMethod = nConnectionValidationMethodNode.getNodeValue();
jdbcConnPool.setAttribute(CONNECTION_VALIDATION_METHOD, sConnectionValidationMethod);
}
if (nFailAllConnectionsNode != null) {
String sFailAllConnection = nFailAllConnectionsNode.getNodeValue();
jdbcConnPool.setAttribute(FAIL_ALL_CONNECTIONS, sFailAllConnection);
}
if (nValidationTableNameNode != null) {
String sValidationTableName = nValidationTableNameNode.getNodeValue();
jdbcConnPool.setAttribute(VALIDATION_TABLE_NAME, sValidationTableName);
}
if (nResType != null) {
String sResType = nResType.getNodeValue();
jdbcConnPool.setAttribute(RES_TYPE, sResType);
}
if (nTransIsolationLevel != null) {
String sTransIsolationLevel = nTransIsolationLevel.getNodeValue();
jdbcConnPool.setAttribute(TRANS_ISOLATION_LEVEL, sTransIsolationLevel);
}
if (nIsIsolationLevelQuaranteed != null) {
String sIsIsolationLevelQuaranteed =
nIsIsolationLevelQuaranteed.getNodeValue();
jdbcConnPool.setAttribute(IS_ISOLATION_LEVEL_GUARANTEED,
sIsIsolationLevelQuaranteed);
}
if (nonTransactionalConnectionsNode != null) {
jdbcConnPool.setAttribute(NON_TRANSACTIONAL_CONNECTIONS,
nonTransactionalConnectionsNode.getNodeValue());
}
if (allowNonComponentCallersNode != null) {
jdbcConnPool.setAttribute(ALLOW_NON_COMPONENT_CALLERS,
allowNonComponentCallersNode.getNodeValue());
}
if (validateAtmostOncePeriodNode != null) {
jdbcConnPool.setAttribute(VALIDATE_ATMOST_ONCE_PERIOD_IN_SECONDS,
validateAtmostOncePeriodNode.getNodeValue());
}
if (connectionLeakTimeoutNode != null) {
jdbcConnPool.setAttribute(CONNECTION_LEAK_TIMEOUT_IN_SECONDS,
connectionLeakTimeoutNode.getNodeValue());
}
if (connectionLeakReclaimNode != null) {
jdbcConnPool.setAttribute(CONNECTION_LEAK_RECLAIM,
connectionLeakReclaimNode.getNodeValue());
}
if (connectionCreationRetryAttemptsNode != null) {
jdbcConnPool.setAttribute(CONNECTION_CREATION_RETRY_ATTEMPTS,
connectionCreationRetryAttemptsNode.getNodeValue());
}
if (connectionCreationRetryIntervalNode != null) {
jdbcConnPool.setAttribute(CONNECTION_CREATION_RETRY_INTERVAL_IN_SECONDS,
connectionCreationRetryIntervalNode.getNodeValue());
}
if (statementTimeoutNode != null) {
jdbcConnPool.setAttribute(STATEMENT_TIMEOUT_IN_SECONDS,
statementTimeoutNode.getNodeValue());
}
if (lazyConnectionEnlistmentNode != null) {
jdbcConnPool.setAttribute(LAZY_CONNECTION_ENLISTMENT,
lazyConnectionEnlistmentNode.getNodeValue());
}
if (lazyConnectionAssociationNode != null) {
jdbcConnPool.setAttribute(LAZY_CONNECTION_ASSOCIATION,
lazyConnectionAssociationNode.getNodeValue());
}
if (associateWithThreadNode != null) {
jdbcConnPool.setAttribute(ASSOCIATE_WITH_THREAD,
associateWithThreadNode.getNodeValue());
}
if (matchConnectionsNode != null) {
jdbcConnPool.setAttribute(MATCH_CONNECTIONS,
matchConnectionsNode.getNodeValue());
}
if (maxConnectionUsageCountNode != null) {
jdbcConnPool.setAttribute(MAX_CONNECTION_USAGE_COUNT,
maxConnectionUsageCountNode.getNodeValue());
}
if (wrapJDBCObjectsNode != null) {
jdbcConnPool.setAttribute(WRAP_JDBC_OBJECTS,
wrapJDBCObjectsNode.getNodeValue());
}
if(poolingNode != null){
String pooling = poolingNode.getNodeValue();
jdbcConnPool.setAttribute(POOLING,pooling);
}
if(pingNode != null){
String ping = pingNode.getNodeValue();
jdbcConnPool.setAttribute(PING,ping);
}
if(initSqlNode != null){
String initSQL = initSqlNode.getNodeValue();
jdbcConnPool.setAttribute(INIT_SQL,initSQL);
}
if(sqlTraceListenersNode != null){
String sqlTraceListeners= sqlTraceListenersNode.getNodeValue();
jdbcConnPool.setAttribute(SQL_TRACE_LISTENERS, sqlTraceListeners);
}
if(customValidationNode != null){
String customValidation = customValidationNode.getNodeValue();
jdbcConnPool.setAttribute(CUSTOM_VALIDATION,customValidation);
}
if(driverClassNameNode != null){
String driverClassName = driverClassNameNode.getNodeValue();
jdbcConnPool.setAttribute(DRIVER_CLASSNAME,driverClassName);
}
if(statementCacheSizeNode != null){
String statementCacheSize = statementCacheSizeNode.getNodeValue();
jdbcConnPool.setAttribute(STATEMENT_CACHE_SIZE,statementCacheSize);
}
if (statementLeakTimeoutNode != null) {
jdbcConnPool.setAttribute(STATEMENT_LEAK_TIMEOUT_IN_SECONDS,
statementLeakTimeoutNode.getNodeValue());
}
if (statementLeakReclaimNode != null) {
jdbcConnPool.setAttribute(STATEMENT_LEAK_RECLAIM,
statementLeakReclaimNode.getNodeValue());
}
NodeList children = nextKid.getChildNodes();
generatePropertyElement(jdbcConnPool, children);