File tree Expand file tree Collapse file tree 1 file changed +3
-4
lines changed
src/test/java/org/apache/commons/pool2/impl Expand file tree Collapse file tree 1 file changed +3
-4
lines changed Original file line number Diff line number Diff line change @@ -1031,10 +1031,10 @@ void testReturnObjectConcurrentCallsRespectsMaxIdleLimit() throws Exception {
10311031 for (int i = 0 ; i < numThreads ; i ++) {
10321032 tasks .add (() -> {
10331033 try {
1034- String pooledObject = pool .borrowObject ();
1034+ final String pooledObject = pool .borrowObject ();
10351035 barrier .await (); // Wait for all threads to be ready
10361036 pool .returnObject (pooledObject );
1037- } catch (Exception e ) {
1037+ } catch (final Exception e ) {
10381038 // do nothing
10391039 } finally {
10401040 doneLatch .countDown ();
@@ -1049,8 +1049,7 @@ void testReturnObjectConcurrentCallsRespectsMaxIdleLimit() throws Exception {
10491049 executorService .shutdown ();
10501050 assertTrue (executorService .awaitTermination (60 , TimeUnit .SECONDS ),
10511051 "Executor did not terminate in time" );
1052- }
1053- finally {
1052+ } finally {
10541053 executorService .shutdownNow (); // Ensure cleanup
10551054 }
10561055
You can’t perform that action at this time.
0 commit comments