@@ -292,7 +292,10 @@ TopologyListener createTopologyListener(AmqpConnectionBuilder builder) {
292
292
BiConsumer <org .apache .qpid .protonj2 .client .Connection , DisconnectionEvent > result =
293
293
(conn , event ) -> {
294
294
ClientIOException ioex = event .failureCause ();
295
- LOGGER .debug ("Disconnect handler, error is the following: {}" , ioex .getMessage ());
295
+ LOGGER .debug (
296
+ "Disconnect handler of '{}', error is the following: {}" ,
297
+ this .name (),
298
+ ioex .getMessage ());
296
299
if (this .state () == OPENING ) {
297
300
LOGGER .debug ("Connection is still opening, disconnect handler skipped" );
298
301
// the broker is not available when opening the connection
@@ -301,7 +304,7 @@ TopologyListener createTopologyListener(AmqpConnectionBuilder builder) {
301
304
}
302
305
if (this .recoveringConnection .get ()) {
303
306
LOGGER .debug (
304
- "Filtering recovery task enqueueing, connection recovery of '{}' in progress" ,
307
+ "Filtering recovery task enqueueing, connection recovery of '{}' already in progress" ,
305
308
this .name ());
306
309
return ;
307
310
}
@@ -336,18 +339,21 @@ private void recoverAfterConnectionFailure(
336
339
AtomicReference <BiConsumer <org .apache .qpid .protonj2 .client .Connection , DisconnectionEvent >>
337
340
disconnectedHandlerReference ) {
338
341
LOGGER .info (
339
- "Connection '{}' to '{}' has been disconnected, trying to recover" ,
342
+ "Connection '{}' to '{}' has been disconnected, trying to recover. " ,
340
343
this .name (),
341
344
this .currentConnectionLabel ());
345
+ LOGGER .debug ("Notifying listeners of connection '{}'." , this .name ());
342
346
this .state (RECOVERING , failureCause );
343
347
this .changeStateOfPublishers (RECOVERING , failureCause );
344
348
this .changeStateOfConsumers (RECOVERING , failureCause );
345
349
this .nativeConnection = null ;
346
350
this .nativeSession = null ;
347
351
this .connectionAddress = null ;
352
+ LOGGER .debug ("Releasing management resource of connection '{}'." , this .name ());
348
353
this .releaseManagementResources ();
349
354
try {
350
355
this .recoveringConnection .set (true );
356
+ LOGGER .debug ("Connection attempt for '{}'." , this .name ());
351
357
NativeConnectionWrapper ncw =
352
358
recoverNativeConnection (
353
359
recoveryConfiguration , connectionName , disconnectedHandlerReference );
0 commit comments