public abstract class org.apache.cassandra.service.paxos.AbstractPaxosCallback<T> implements org.apache.cassandra.net.IAsyncCallback<T>
minor version: 0
major version: 59
flags: flags: (0x0421) ACC_PUBLIC, ACC_SUPER, ACC_ABSTRACT
this_class: org.apache.cassandra.service.paxos.AbstractPaxosCallback
super_class: java.lang.Object
{
protected final java.util.concurrent.CountDownLatch latch;
descriptor: Ljava/util/concurrent/CountDownLatch;
flags: (0x0014) ACC_PROTECTED, ACC_FINAL
protected final int targets;
descriptor: I
flags: (0x0014) ACC_PROTECTED, ACC_FINAL
private final org.apache.cassandra.db.ConsistencyLevel consistency;
descriptor: Lorg/apache/cassandra/db/ConsistencyLevel;
flags: (0x0012) ACC_PRIVATE, ACC_FINAL
private final long queryStartNanoTime;
descriptor: J
flags: (0x0012) ACC_PRIVATE, ACC_FINAL
public void <init>(int, org.apache.cassandra.db.ConsistencyLevel, long);
descriptor: (ILorg/apache/cassandra/db/ConsistencyLevel;J)V
flags: (0x0001) ACC_PUBLIC
Code:
stack=4, locals=5, args_size=4
start local 0 start local 1 start local 2 start local 3 0: aload 0
invokespecial java.lang.Object.<init>:()V
1: aload 0
iload 1
putfield org.apache.cassandra.service.paxos.AbstractPaxosCallback.targets:I
2: aload 0
aload 2
putfield org.apache.cassandra.service.paxos.AbstractPaxosCallback.consistency:Lorg/apache/cassandra/db/ConsistencyLevel;
3: aload 0
new java.util.concurrent.CountDownLatch
dup
iload 1
invokespecial java.util.concurrent.CountDownLatch.<init>:(I)V
putfield org.apache.cassandra.service.paxos.AbstractPaxosCallback.latch:Ljava/util/concurrent/CountDownLatch;
4: aload 0
lload 3
putfield org.apache.cassandra.service.paxos.AbstractPaxosCallback.queryStartNanoTime:J
5: return
end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 6 0 this Lorg/apache/cassandra/service/paxos/AbstractPaxosCallback<TT;>;
0 6 1 targets I
0 6 2 consistency Lorg/apache/cassandra/db/ConsistencyLevel;
0 6 3 queryStartNanoTime J
MethodParameters:
Name Flags
targets
consistency
queryStartNanoTime
public boolean isLatencyForSnitch();
descriptor: ()Z
flags: (0x0001) ACC_PUBLIC
Code:
stack=1, locals=1, args_size=1
start local 0 0: iconst_0
ireturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lorg/apache/cassandra/service/paxos/AbstractPaxosCallback<TT;>;
public int getResponseCount();
descriptor: ()I
flags: (0x0001) ACC_PUBLIC
Code:
stack=4, locals=1, args_size=1
start local 0 0: aload 0
getfield org.apache.cassandra.service.paxos.AbstractPaxosCallback.targets:I
i2l
aload 0
getfield org.apache.cassandra.service.paxos.AbstractPaxosCallback.latch:Ljava/util/concurrent/CountDownLatch;
invokevirtual java.util.concurrent.CountDownLatch.getCount:()J
lsub
l2i
ireturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lorg/apache/cassandra/service/paxos/AbstractPaxosCallback<TT;>;
public void await();
descriptor: ()V
flags: (0x0001) ACC_PUBLIC
Code:
stack=6, locals=3, args_size=1
start local 0 0: getstatic java.util.concurrent.TimeUnit.MILLISECONDS:Ljava/util/concurrent/TimeUnit;
invokestatic org.apache.cassandra.config.DatabaseDescriptor.getWriteRpcTimeout:()J
invokevirtual java.util.concurrent.TimeUnit.toNanos:(J)J
invokestatic java.lang.System.nanoTime:()J
aload 0
getfield org.apache.cassandra.service.paxos.AbstractPaxosCallback.queryStartNanoTime:J
lsub
lsub
lstore 1
start local 1 1: aload 0
getfield org.apache.cassandra.service.paxos.AbstractPaxosCallback.latch:Ljava/util/concurrent/CountDownLatch;
lload 1
getstatic java.util.concurrent.TimeUnit.NANOSECONDS:Ljava/util/concurrent/TimeUnit;
invokevirtual java.util.concurrent.CountDownLatch.await:(JLjava/util/concurrent/TimeUnit;)Z
ifne 5
2: new org.apache.cassandra.exceptions.WriteTimeoutException
dup
getstatic org.apache.cassandra.db.WriteType.CAS:Lorg/apache/cassandra/db/WriteType;
aload 0
getfield org.apache.cassandra.service.paxos.AbstractPaxosCallback.consistency:Lorg/apache/cassandra/db/ConsistencyLevel;
aload 0
invokevirtual org.apache.cassandra.service.paxos.AbstractPaxosCallback.getResponseCount:()I
aload 0
getfield org.apache.cassandra.service.paxos.AbstractPaxosCallback.targets:I
invokespecial org.apache.cassandra.exceptions.WriteTimeoutException.<init>:(Lorg/apache/cassandra/db/WriteType;Lorg/apache/cassandra/db/ConsistencyLevel;II)V
athrow
end local 1 3: StackMap locals:
StackMap stack: java.lang.InterruptedException
pop
4: new java.lang.AssertionError
dup
ldc "This latch shouldn't have been interrupted."
invokespecial java.lang.AssertionError.<init>:(Ljava/lang/Object;)V
athrow
5: StackMap locals:
StackMap stack:
return
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 6 0 this Lorg/apache/cassandra/service/paxos/AbstractPaxosCallback<TT;>;
1 3 1 timeout J
Exception table:
from to target type
0 3 3 Class java.lang.InterruptedException
Exceptions:
throws org.apache.cassandra.exceptions.WriteTimeoutException
}
Signature: <T:Ljava/lang/Object;>Ljava/lang/Object;Lorg/apache/cassandra/net/IAsyncCallback<TT;>;
SourceFile: "AbstractPaxosCallback.java"