class com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable implements java.lang.Runnable
minor version: 0
major version: 59
flags: flags: (0x0020) ACC_SUPER
this_class: com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable
super_class: java.lang.Object
{
private final com.mongodb.internal.connection.ExponentiallyWeightedMovingAverage averageRoundTripTime;
descriptor: Lcom/mongodb/internal/connection/ExponentiallyWeightedMovingAverage;
flags: (0x0012) ACC_PRIVATE, ACC_FINAL
final com.mongodb.internal.connection.DefaultServerMonitor this$0;
descriptor: Lcom/mongodb/internal/connection/DefaultServerMonitor;
flags: (0x1010) ACC_FINAL, ACC_SYNTHETIC
void <init>(com.mongodb.internal.connection.DefaultServerMonitor);
descriptor: (Lcom/mongodb/internal/connection/DefaultServerMonitor;)V
flags: (0x0000)
Code:
stack=5, locals=2, args_size=2
start local 0 0: aload 0
aload 1
putfield com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable.this$0:Lcom/mongodb/internal/connection/DefaultServerMonitor;
aload 0
invokespecial java.lang.Object.<init>:()V
1: aload 0
new com.mongodb.internal.connection.ExponentiallyWeightedMovingAverage
dup
ldc 0.2
invokespecial com.mongodb.internal.connection.ExponentiallyWeightedMovingAverage.<init>:(D)V
putfield com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable.averageRoundTripTime:Lcom/mongodb/internal/connection/ExponentiallyWeightedMovingAverage;
2: return
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 3 0 this Lcom/mongodb/internal/connection/DefaultServerMonitor$ServerMonitorRunnable;
MethodParameters:
Name Flags
this$0 final
public synchronized void run();
descriptor: ()V
flags: (0x0021) ACC_PUBLIC, ACC_SYNCHRONIZED
Code:
stack=5, locals=6, args_size=1
start local 0 0: aconst_null
astore 1
start local 1 1: aload 0
aconst_null
invokevirtual com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable.getConnectingServerDescription:(Ljava/lang/Throwable;)Lcom/mongodb/connection/ServerDescription;
astore 2
start local 2 2: goto 41
3: StackMap locals: com.mongodb.internal.connection.InternalConnection com.mongodb.connection.ServerDescription
StackMap stack:
aload 2
astore 3
start local 3 4: aload 1
ifnonnull 11
5: aload 0
getfield com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable.this$0:Lcom/mongodb/internal/connection/DefaultServerMonitor;
getfield com.mongodb.internal.connection.DefaultServerMonitor.internalConnectionFactory:Lcom/mongodb/internal/connection/InternalConnectionFactory;
aload 0
getfield com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable.this$0:Lcom/mongodb/internal/connection/DefaultServerMonitor;
getfield com.mongodb.internal.connection.DefaultServerMonitor.serverId:Lcom/mongodb/connection/ServerId;
invokeinterface com.mongodb.internal.connection.InternalConnectionFactory.create:(Lcom/mongodb/connection/ServerId;)Lcom/mongodb/internal/connection/InternalConnection;
astore 1
6: aload 1
invokeinterface com.mongodb.internal.connection.InternalConnection.open:()V
7: goto 11
StackMap locals: com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable com.mongodb.internal.connection.InternalConnection com.mongodb.connection.ServerDescription com.mongodb.connection.ServerDescription
StackMap stack: java.lang.Throwable
8: astore 4
start local 4 9: aconst_null
astore 1
10: aload 4
athrow
end local 4 11: StackMap locals:
StackMap stack:
aload 0
aload 1
invokevirtual com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable.lookupServerDescription:(Lcom/mongodb/internal/connection/InternalConnection;)Lcom/mongodb/connection/ServerDescription;
astore 2
12: goto 32
StackMap locals:
StackMap stack: com.mongodb.MongoSocketException
13: pop
14: aload 0
getfield com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable.this$0:Lcom/mongodb/internal/connection/DefaultServerMonitor;
getfield com.mongodb.internal.connection.DefaultServerMonitor.connectionPool:Lcom/mongodb/internal/connection/ConnectionPool;
invokeinterface com.mongodb.internal.connection.ConnectionPool.invalidate:()V
15: aload 1
invokeinterface com.mongodb.internal.connection.InternalConnection.close:()V
16: aconst_null
astore 1
17: aload 0
getfield com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable.this$0:Lcom/mongodb/internal/connection/DefaultServerMonitor;
getfield com.mongodb.internal.connection.DefaultServerMonitor.internalConnectionFactory:Lcom/mongodb/internal/connection/InternalConnectionFactory;
aload 0
getfield com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable.this$0:Lcom/mongodb/internal/connection/DefaultServerMonitor;
getfield com.mongodb.internal.connection.DefaultServerMonitor.serverId:Lcom/mongodb/connection/ServerId;
invokeinterface com.mongodb.internal.connection.InternalConnectionFactory.create:(Lcom/mongodb/connection/ServerId;)Lcom/mongodb/internal/connection/InternalConnection;
astore 1
18: aload 1
invokeinterface com.mongodb.internal.connection.InternalConnection.open:()V
19: goto 23
StackMap locals:
StackMap stack: java.lang.Throwable
20: astore 4
start local 4 21: aconst_null
astore 1
22: aload 4
athrow
end local 4 23: StackMap locals:
StackMap stack:
aload 0
aload 1
invokevirtual com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable.lookupServerDescription:(Lcom/mongodb/internal/connection/InternalConnection;)Lcom/mongodb/connection/ServerDescription;
astore 2
24: goto 32
StackMap locals:
StackMap stack: com.mongodb.MongoSocketException
25: astore 4
start local 4 26: aload 1
invokeinterface com.mongodb.internal.connection.InternalConnection.close:()V
27: aconst_null
astore 1
28: aload 4
athrow
end local 4 29: StackMap locals:
StackMap stack: java.lang.Throwable
astore 4
start local 4 30: aload 0
getfield com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable.averageRoundTripTime:Lcom/mongodb/internal/connection/ExponentiallyWeightedMovingAverage;
invokevirtual com.mongodb.internal.connection.ExponentiallyWeightedMovingAverage.reset:()V
31: aload 0
aload 4
invokevirtual com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable.getConnectingServerDescription:(Ljava/lang/Throwable;)Lcom/mongodb/connection/ServerDescription;
astore 2
end local 4 32: StackMap locals:
StackMap stack:
aload 0
getfield com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable.this$0:Lcom/mongodb/internal/connection/DefaultServerMonitor;
getfield com.mongodb.internal.connection.DefaultServerMonitor.isClosed:Z
ifne 41
33: aload 0
aload 3
aload 2
invokevirtual com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable.logStateChange:(Lcom/mongodb/connection/ServerDescription;Lcom/mongodb/connection/ServerDescription;)V
34: aload 0
getfield com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable.this$0:Lcom/mongodb/internal/connection/DefaultServerMonitor;
getfield com.mongodb.internal.connection.DefaultServerMonitor.serverStateListener:Lcom/mongodb/internal/connection/ChangeListener;
new com.mongodb.internal.connection.ChangeEvent
dup
aload 3
35: aload 2
invokespecial com.mongodb.internal.connection.ChangeEvent.<init>:(Ljava/lang/Object;Ljava/lang/Object;)V
36: invokeinterface com.mongodb.internal.connection.ChangeListener.stateChanged:(Lcom/mongodb/internal/connection/ChangeEvent;)V
37: goto 40
StackMap locals:
StackMap stack: java.lang.Throwable
38: astore 4
start local 4 39: getstatic com.mongodb.internal.connection.DefaultServerMonitor.LOGGER:Lcom/mongodb/diagnostics/logging/Logger;
ldc "Exception in monitor thread during notification of server description state change"
aload 4
invokeinterface com.mongodb.diagnostics.logging.Logger.warn:(Ljava/lang/String;Ljava/lang/Throwable;)V
end local 4 40: StackMap locals:
StackMap stack:
aload 0
invokevirtual com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable.waitForNext:()V
end local 3 41: StackMap locals:
StackMap stack:
aload 0
getfield com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable.this$0:Lcom/mongodb/internal/connection/DefaultServerMonitor;
getfield com.mongodb.internal.connection.DefaultServerMonitor.isClosed:Z
ifeq 3
end local 2 42: goto 47
StackMap locals: com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable com.mongodb.internal.connection.InternalConnection
StackMap stack: java.lang.Throwable
43: astore 5
44: aload 1
ifnull 46
45: aload 1
invokeinterface com.mongodb.internal.connection.InternalConnection.close:()V
46: StackMap locals: com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable com.mongodb.internal.connection.InternalConnection top top top java.lang.Throwable
StackMap stack:
aload 5
athrow
47: StackMap locals: com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable com.mongodb.internal.connection.InternalConnection
StackMap stack:
aload 1
ifnull 49
48: aload 1
invokeinterface com.mongodb.internal.connection.InternalConnection.close:()V
49: StackMap locals:
StackMap stack:
return
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 50 0 this Lcom/mongodb/internal/connection/DefaultServerMonitor$ServerMonitorRunnable;
1 50 1 connection Lcom/mongodb/internal/connection/InternalConnection;
2 42 2 currentServerDescription Lcom/mongodb/connection/ServerDescription;
4 41 3 previousServerDescription Lcom/mongodb/connection/ServerDescription;
9 11 4 t Ljava/lang/Throwable;
21 23 4 t Ljava/lang/Throwable;
26 29 4 e1 Lcom/mongodb/MongoSocketException;
30 32 4 t Ljava/lang/Throwable;
39 40 4 t Ljava/lang/Throwable;
Exception table:
from to target type
6 7 8 Class java.lang.Throwable
11 12 13 Class com.mongodb.MongoSocketException
18 19 20 Class java.lang.Throwable
23 24 25 Class com.mongodb.MongoSocketException
4 29 29 Class java.lang.Throwable
33 37 38 Class java.lang.Throwable
1 43 43 any
private com.mongodb.connection.ServerDescription getConnectingServerDescription(java.lang.Throwable);
descriptor: (Ljava/lang/Throwable;)Lcom/mongodb/connection/ServerDescription;
flags: (0x0002) ACC_PRIVATE
Code:
stack=2, locals=2, args_size=2
start local 0 start local 1 0: invokestatic com.mongodb.connection.ServerDescription.builder:()Lcom/mongodb/connection/ServerDescription$Builder;
getstatic com.mongodb.connection.ServerType.UNKNOWN:Lcom/mongodb/connection/ServerType;
invokevirtual com.mongodb.connection.ServerDescription$Builder.type:(Lcom/mongodb/connection/ServerType;)Lcom/mongodb/connection/ServerDescription$Builder;
getstatic com.mongodb.connection.ServerConnectionState.CONNECTING:Lcom/mongodb/connection/ServerConnectionState;
invokevirtual com.mongodb.connection.ServerDescription$Builder.state:(Lcom/mongodb/connection/ServerConnectionState;)Lcom/mongodb/connection/ServerDescription$Builder;
aload 0
getfield com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable.this$0:Lcom/mongodb/internal/connection/DefaultServerMonitor;
getfield com.mongodb.internal.connection.DefaultServerMonitor.serverId:Lcom/mongodb/connection/ServerId;
invokevirtual com.mongodb.connection.ServerId.getAddress:()Lcom/mongodb/ServerAddress;
invokevirtual com.mongodb.connection.ServerDescription$Builder.address:(Lcom/mongodb/ServerAddress;)Lcom/mongodb/connection/ServerDescription$Builder;
aload 1
invokevirtual com.mongodb.connection.ServerDescription$Builder.exception:(Ljava/lang/Throwable;)Lcom/mongodb/connection/ServerDescription$Builder;
invokevirtual com.mongodb.connection.ServerDescription$Builder.build:()Lcom/mongodb/connection/ServerDescription;
areturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lcom/mongodb/internal/connection/DefaultServerMonitor$ServerMonitorRunnable;
0 1 1 exception Ljava/lang/Throwable;
MethodParameters:
Name Flags
exception final
private com.mongodb.connection.ServerDescription lookupServerDescription(com.mongodb.internal.connection.InternalConnection);
descriptor: (Lcom/mongodb/internal/connection/InternalConnection;)Lcom/mongodb/connection/ServerDescription;
flags: (0x0002) ACC_PRIVATE
Code:
stack=8, locals=7, args_size=2
start local 0 start local 1 0: getstatic com.mongodb.internal.connection.DefaultServerMonitor.LOGGER:Lcom/mongodb/diagnostics/logging/Logger;
invokeinterface com.mongodb.diagnostics.logging.Logger.isDebugEnabled:()Z
ifeq 2
1: getstatic com.mongodb.internal.connection.DefaultServerMonitor.LOGGER:Lcom/mongodb/diagnostics/logging/Logger;
ldc "Checking status of %s"
iconst_1
anewarray java.lang.Object
dup
iconst_0
aload 0
getfield com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable.this$0:Lcom/mongodb/internal/connection/DefaultServerMonitor;
getfield com.mongodb.internal.connection.DefaultServerMonitor.serverId:Lcom/mongodb/connection/ServerId;
invokevirtual com.mongodb.connection.ServerId.getAddress:()Lcom/mongodb/ServerAddress;
aastore
invokestatic java.lang.String.format:(Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/String;
invokeinterface com.mongodb.diagnostics.logging.Logger.debug:(Ljava/lang/String;)V
2: StackMap locals:
StackMap stack:
aload 0
getfield com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable.this$0:Lcom/mongodb/internal/connection/DefaultServerMonitor;
getfield com.mongodb.internal.connection.DefaultServerMonitor.serverMonitorListener:Lcom/mongodb/event/ServerMonitorListener;
new com.mongodb.event.ServerHeartbeatStartedEvent
dup
aload 1
invokeinterface com.mongodb.internal.connection.InternalConnection.getDescription:()Lcom/mongodb/connection/ConnectionDescription;
invokevirtual com.mongodb.connection.ConnectionDescription.getConnectionId:()Lcom/mongodb/connection/ConnectionId;
invokespecial com.mongodb.event.ServerHeartbeatStartedEvent.<init>:(Lcom/mongodb/connection/ConnectionId;)V
invokeinterface com.mongodb.event.ServerMonitorListener.serverHearbeatStarted:(Lcom/mongodb/event/ServerHeartbeatStartedEvent;)V
3: invokestatic java.lang.System.nanoTime:()J
lstore 2
start local 2 4: ldc "admin"
new org.bson.BsonDocument
dup
ldc "ismaster"
new org.bson.BsonInt32
dup
iconst_1
invokespecial org.bson.BsonInt32.<init>:(I)V
invokespecial org.bson.BsonDocument.<init>:(Ljava/lang/String;Lorg/bson/BsonValue;)V
aload 0
getfield com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable.this$0:Lcom/mongodb/internal/connection/DefaultServerMonitor;
getfield com.mongodb.internal.connection.DefaultServerMonitor.clusterClock:Lcom/mongodb/internal/connection/ClusterClock;
aload 1
invokestatic com.mongodb.internal.connection.CommandHelper.executeCommand:(Ljava/lang/String;Lorg/bson/BsonDocument;Lcom/mongodb/internal/connection/ClusterClock;Lcom/mongodb/internal/connection/InternalConnection;)Lorg/bson/BsonDocument;
5: astore 4
start local 4 6: invokestatic java.lang.System.nanoTime:()J
lload 2
lsub
lstore 5
start local 5 7: aload 0
getfield com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable.averageRoundTripTime:Lcom/mongodb/internal/connection/ExponentiallyWeightedMovingAverage;
lload 5
invokevirtual com.mongodb.internal.connection.ExponentiallyWeightedMovingAverage.addSample:(J)J
pop2
8: aload 0
getfield com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable.this$0:Lcom/mongodb/internal/connection/DefaultServerMonitor;
getfield com.mongodb.internal.connection.DefaultServerMonitor.serverMonitorListener:Lcom/mongodb/event/ServerMonitorListener;
9: new com.mongodb.event.ServerHeartbeatSucceededEvent
dup
aload 1
invokeinterface com.mongodb.internal.connection.InternalConnection.getDescription:()Lcom/mongodb/connection/ConnectionDescription;
invokevirtual com.mongodb.connection.ConnectionDescription.getConnectionId:()Lcom/mongodb/connection/ConnectionId;
aload 4
lload 5
invokespecial com.mongodb.event.ServerHeartbeatSucceededEvent.<init>:(Lcom/mongodb/connection/ConnectionId;Lorg/bson/BsonDocument;J)V
10: invokeinterface com.mongodb.event.ServerMonitorListener.serverHeartbeatSucceeded:(Lcom/mongodb/event/ServerHeartbeatSucceededEvent;)V
11: aload 0
getfield com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable.this$0:Lcom/mongodb/internal/connection/DefaultServerMonitor;
getfield com.mongodb.internal.connection.DefaultServerMonitor.serverId:Lcom/mongodb/connection/ServerId;
invokevirtual com.mongodb.connection.ServerId.getAddress:()Lcom/mongodb/ServerAddress;
aload 4
aload 1
invokeinterface com.mongodb.internal.connection.InternalConnection.getDescription:()Lcom/mongodb/connection/ConnectionDescription;
invokevirtual com.mongodb.connection.ConnectionDescription.getServerVersion:()Lcom/mongodb/connection/ServerVersion;
12: aload 0
getfield com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable.averageRoundTripTime:Lcom/mongodb/internal/connection/ExponentiallyWeightedMovingAverage;
invokevirtual com.mongodb.internal.connection.ExponentiallyWeightedMovingAverage.getAverage:()J
13: invokestatic com.mongodb.internal.connection.DescriptionHelper.createServerDescription:(Lcom/mongodb/ServerAddress;Lorg/bson/BsonDocument;Lcom/mongodb/connection/ServerVersion;J)Lcom/mongodb/connection/ServerDescription;
14: areturn
end local 5 end local 4 15: StackMap locals: com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable com.mongodb.internal.connection.InternalConnection long
StackMap stack: java.lang.RuntimeException
astore 4
start local 4 16: aload 0
getfield com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable.this$0:Lcom/mongodb/internal/connection/DefaultServerMonitor;
getfield com.mongodb.internal.connection.DefaultServerMonitor.serverMonitorListener:Lcom/mongodb/event/ServerMonitorListener;
17: new com.mongodb.event.ServerHeartbeatFailedEvent
dup
aload 1
invokeinterface com.mongodb.internal.connection.InternalConnection.getDescription:()Lcom/mongodb/connection/ConnectionDescription;
invokevirtual com.mongodb.connection.ConnectionDescription.getConnectionId:()Lcom/mongodb/connection/ConnectionId;
invokestatic java.lang.System.nanoTime:()J
lload 2
lsub
aload 4
invokespecial com.mongodb.event.ServerHeartbeatFailedEvent.<init>:(Lcom/mongodb/connection/ConnectionId;JLjava/lang/Throwable;)V
18: invokeinterface com.mongodb.event.ServerMonitorListener.serverHeartbeatFailed:(Lcom/mongodb/event/ServerHeartbeatFailedEvent;)V
19: aload 4
athrow
end local 4 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 20 0 this Lcom/mongodb/internal/connection/DefaultServerMonitor$ServerMonitorRunnable;
0 20 1 connection Lcom/mongodb/internal/connection/InternalConnection;
4 20 2 start J
6 15 4 isMasterResult Lorg/bson/BsonDocument;
7 15 5 elapsedTimeNanos J
16 20 4 e Ljava/lang/RuntimeException;
Exception table:
from to target type
4 14 15 Class java.lang.RuntimeException
MethodParameters:
Name Flags
connection final
private void logStateChange(com.mongodb.connection.ServerDescription, com.mongodb.connection.ServerDescription);
descriptor: (Lcom/mongodb/connection/ServerDescription;Lcom/mongodb/connection/ServerDescription;)V
flags: (0x0002) ACC_PRIVATE
Code:
stack=6, locals=3, args_size=3
start local 0 start local 1 start local 2 0: aload 1
aload 2
invokestatic com.mongodb.internal.connection.DefaultServerMonitor.shouldLogStageChange:(Lcom/mongodb/connection/ServerDescription;Lcom/mongodb/connection/ServerDescription;)Z
ifeq 7
1: aload 2
invokevirtual com.mongodb.connection.ServerDescription.getException:()Ljava/lang/Throwable;
ifnull 6
2: getstatic com.mongodb.internal.connection.DefaultServerMonitor.LOGGER:Lcom/mongodb/diagnostics/logging/Logger;
ldc "Exception in monitor thread while connecting to server %s"
iconst_1
anewarray java.lang.Object
dup
iconst_0
aload 0
getfield com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable.this$0:Lcom/mongodb/internal/connection/DefaultServerMonitor;
getfield com.mongodb.internal.connection.DefaultServerMonitor.serverId:Lcom/mongodb/connection/ServerId;
invokevirtual com.mongodb.connection.ServerId.getAddress:()Lcom/mongodb/ServerAddress;
aastore
invokestatic java.lang.String.format:(Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/String;
3: aload 2
invokevirtual com.mongodb.connection.ServerDescription.getException:()Ljava/lang/Throwable;
4: invokeinterface com.mongodb.diagnostics.logging.Logger.info:(Ljava/lang/String;Ljava/lang/Throwable;)V
5: goto 7
6: StackMap locals:
StackMap stack:
getstatic com.mongodb.internal.connection.DefaultServerMonitor.LOGGER:Lcom/mongodb/diagnostics/logging/Logger;
ldc "Monitor thread successfully connected to server with description %s"
iconst_1
anewarray java.lang.Object
dup
iconst_0
aload 2
aastore
invokestatic java.lang.String.format:(Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/String;
invokeinterface com.mongodb.diagnostics.logging.Logger.info:(Ljava/lang/String;)V
7: StackMap locals:
StackMap stack:
return
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 8 0 this Lcom/mongodb/internal/connection/DefaultServerMonitor$ServerMonitorRunnable;
0 8 1 previousServerDescription Lcom/mongodb/connection/ServerDescription;
0 8 2 currentServerDescription Lcom/mongodb/connection/ServerDescription;
MethodParameters:
Name Flags
previousServerDescription final
currentServerDescription final
private void waitForNext();
descriptor: ()V
flags: (0x0002) ACC_PRIVATE
Code:
stack=5, locals=9, args_size=1
start local 0 0: aload 0
invokevirtual com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable.waitForSignalOrTimeout:()J
lstore 1
start local 1 1: lload 1
lconst_0
lcmp
ifle 10
2: aload 0
getfield com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable.this$0:Lcom/mongodb/internal/connection/DefaultServerMonitor;
getfield com.mongodb.internal.connection.DefaultServerMonitor.serverSettings:Lcom/mongodb/connection/ServerSettings;
getstatic java.util.concurrent.TimeUnit.NANOSECONDS:Ljava/util/concurrent/TimeUnit;
invokevirtual com.mongodb.connection.ServerSettings.getHeartbeatFrequency:(Ljava/util/concurrent/TimeUnit;)J
lload 1
lsub
lstore 3
start local 3 3: aload 0
getfield com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable.this$0:Lcom/mongodb/internal/connection/DefaultServerMonitor;
getfield com.mongodb.internal.connection.DefaultServerMonitor.serverSettings:Lcom/mongodb/connection/ServerSettings;
getstatic java.util.concurrent.TimeUnit.NANOSECONDS:Ljava/util/concurrent/TimeUnit;
invokevirtual com.mongodb.connection.ServerSettings.getMinHeartbeatFrequency:(Ljava/util/concurrent/TimeUnit;)J
lstore 5
start local 5 4: lload 3
lload 5
lcmp
ifge 10
5: getstatic java.util.concurrent.TimeUnit.MILLISECONDS:Ljava/util/concurrent/TimeUnit;
lload 5
lload 3
lsub
getstatic java.util.concurrent.TimeUnit.NANOSECONDS:Ljava/util/concurrent/TimeUnit;
invokevirtual java.util.concurrent.TimeUnit.convert:(JLjava/util/concurrent/TimeUnit;)J
lstore 7
start local 7 6: lload 7
lconst_0
lcmp
ifle 10
7: lload 7
invokestatic java.lang.Thread.sleep:(J)V
end local 7 end local 5 end local 3 end local 1 8: goto 10
StackMap locals:
StackMap stack: java.lang.InterruptedException
9: pop
10: StackMap locals:
StackMap stack:
return
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 11 0 this Lcom/mongodb/internal/connection/DefaultServerMonitor$ServerMonitorRunnable;
1 8 1 timeRemaining J
3 8 3 timeWaiting J
4 8 5 minimumNanosToWait J
6 8 7 millisToSleep J
Exception table:
from to target type
0 8 9 Class java.lang.InterruptedException
private long waitForSignalOrTimeout();
descriptor: ()J
flags: (0x0002) ACC_PRIVATE
Code:
stack=3, locals=4, args_size=1
start local 0 0: aload 0
getfield com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable.this$0:Lcom/mongodb/internal/connection/DefaultServerMonitor;
getfield com.mongodb.internal.connection.DefaultServerMonitor.lock:Ljava/util/concurrent/locks/Lock;
invokeinterface java.util.concurrent.locks.Lock.lock:()V
1: aload 0
getfield com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable.this$0:Lcom/mongodb/internal/connection/DefaultServerMonitor;
getfield com.mongodb.internal.connection.DefaultServerMonitor.condition:Ljava/util/concurrent/locks/Condition;
aload 0
getfield com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable.this$0:Lcom/mongodb/internal/connection/DefaultServerMonitor;
getfield com.mongodb.internal.connection.DefaultServerMonitor.serverSettings:Lcom/mongodb/connection/ServerSettings;
getstatic java.util.concurrent.TimeUnit.NANOSECONDS:Ljava/util/concurrent/TimeUnit;
invokevirtual com.mongodb.connection.ServerSettings.getHeartbeatFrequency:(Ljava/util/concurrent/TimeUnit;)J
invokeinterface java.util.concurrent.locks.Condition.awaitNanos:(J)J
lstore 2
2: aload 0
getfield com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable.this$0:Lcom/mongodb/internal/connection/DefaultServerMonitor;
getfield com.mongodb.internal.connection.DefaultServerMonitor.lock:Ljava/util/concurrent/locks/Lock;
invokeinterface java.util.concurrent.locks.Lock.unlock:()V
3: lload 2
lreturn
4: StackMap locals:
StackMap stack: java.lang.Throwable
astore 1
5: aload 0
getfield com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable.this$0:Lcom/mongodb/internal/connection/DefaultServerMonitor;
getfield com.mongodb.internal.connection.DefaultServerMonitor.lock:Ljava/util/concurrent/locks/Lock;
invokeinterface java.util.concurrent.locks.Lock.unlock:()V
6: aload 1
athrow
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 7 0 this Lcom/mongodb/internal/connection/DefaultServerMonitor$ServerMonitorRunnable;
Exception table:
from to target type
1 2 4 any
Exceptions:
throws java.lang.InterruptedException
}
SourceFile: "DefaultServerMonitor.java"
NestHost: com.mongodb.internal.connection.DefaultServerMonitor
InnerClasses:
public Builder = com.mongodb.connection.ServerDescription$Builder of com.mongodb.connection.ServerDescription
ServerMonitorRunnable = com.mongodb.internal.connection.DefaultServerMonitor$ServerMonitorRunnable of com.mongodb.internal.connection.DefaultServerMonitor