Skip to content

Commit

Permalink
Merge pull request #25270 from dmiya3/br-improve-lookup-messages
Browse files Browse the repository at this point in the history
Improve the connection pool lookup messages
  • Loading branch information
dmatej authored Dec 11, 2024
2 parents b0489aa + a388c86 commit 71df878
Showing 1 changed file with 3 additions and 4 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2022 Contributors to the Eclipse Foundation
* Copyright (c) 2022, 2024 Contributors to the Eclipse Foundation
* Copyright (c) 1997, 2018 Oracle and/or its affiliates. All rights reserved.
*
* This program and the accompanying materials are made available under the
Expand Down Expand Up @@ -66,15 +66,14 @@ public void createConnectorResource(ResourceInfo resourceInfo, PoolInfo poolInfo
try {
ccp = (ConnectorConnectionPool) namingService.lookup(poolInfo, jndiNameForPool);
} catch (NamingException ne) {
_logger.log(Level.WARNING,
_logger.log(Level.INFO,
"Probably the pool {0} is not yet initialized (lazy-loading), trying to check ...", poolInfo);
try {
checkAndLoadPool(poolInfo);
ccp = (ConnectorConnectionPool) namingService.lookup(poolInfo, jndiNameForPool);
} catch (NamingException e) {
_logger.log(Level.SEVERE, "Second lookup failed for {0}: {1}", new Object[] {poolInfo, e});
throw new ConnectorRuntimeException(
"Second lookup failed again for pool name " + jndiNameForPool + " or " + poolInfo, ne);
"Failed to lookup pool name " + jndiNameForPool + " or " + poolInfo, ne);
}
}

Expand Down

0 comments on commit 71df878

Please sign in to comment.