Skip to content

Commit

Permalink
Adjust logging level for JDBC resource leak warnings
Browse files Browse the repository at this point in the history
```
- Adjust JDBC resource leak logging to use debug level instead of warnings for better log granularity.
- Enhance developer experience by reducing noise in application logs.
```
  • Loading branch information
gastaldi committed Jan 14, 2025
1 parent cfd2a75 commit 089c353
Showing 1 changed file with 6 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,12 @@ public void onConnectionDestroy(Connection connection) {

@Override
public void onWarning(String warning) {
log.warnv("{0}: {1}", datasourceName, warning);
// See https://github.com/quarkusio/quarkus/issues/44047
if (warning.contains("JDBC resources leaked")) {
log.debugv("{0}: {1}", datasourceName, warning);
} else {
log.warnv("{0}: {1}", datasourceName, warning);
}
}

@Override
Expand Down

0 comments on commit 089c353

Please sign in to comment.