public class org.apache.cassandra.transport.Frame$Decoder extends io.netty.handler.codec.ByteToMessageDecoder
minor version: 0
major version: 59
flags: flags: (0x0021) ACC_PUBLIC, ACC_SUPER
this_class: org.apache.cassandra.transport.Frame$Decoder
super_class: io.netty.handler.codec.ByteToMessageDecoder
{
private static final int MAX_FRAME_LENGTH;
descriptor: I
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
private boolean discardingTooLongFrame;
descriptor: Z
flags: (0x0002) ACC_PRIVATE
private long tooLongFrameLength;
descriptor: J
flags: (0x0002) ACC_PRIVATE
private long bytesToDiscard;
descriptor: J
flags: (0x0002) ACC_PRIVATE
private int tooLongStreamId;
descriptor: I
flags: (0x0002) ACC_PRIVATE
private final org.apache.cassandra.transport.Connection$Factory factory;
descriptor: Lorg/apache/cassandra/transport/Connection$Factory;
flags: (0x0012) ACC_PRIVATE, ACC_FINAL
private final org.apache.cassandra.transport.ProtocolVersionLimit versionCap;
descriptor: Lorg/apache/cassandra/transport/ProtocolVersionLimit;
flags: (0x0012) ACC_PRIVATE, ACC_FINAL
static void <clinit>();
descriptor: ()V
flags: (0x0008) ACC_STATIC
Code:
stack=1, locals=0, args_size=0
0: invokestatic org.apache.cassandra.config.DatabaseDescriptor.getNativeTransportMaxFrameSize:()I
putstatic org.apache.cassandra.transport.Frame$Decoder.MAX_FRAME_LENGTH:I
return
LocalVariableTable:
Start End Slot Name Signature
public void <init>(org.apache.cassandra.transport.Connection$Factory, org.apache.cassandra.transport.ProtocolVersionLimit);
descriptor: (Lorg/apache/cassandra/transport/Connection$Factory;Lorg/apache/cassandra/transport/ProtocolVersionLimit;)V
flags: (0x0001) ACC_PUBLIC
Code:
stack=2, locals=3, args_size=3
start local 0 start local 1 start local 2 0: aload 0
invokespecial io.netty.handler.codec.ByteToMessageDecoder.<init>:()V
1: aload 0
aload 1
putfield org.apache.cassandra.transport.Frame$Decoder.factory:Lorg/apache/cassandra/transport/Connection$Factory;
2: aload 0
aload 2
putfield org.apache.cassandra.transport.Frame$Decoder.versionCap:Lorg/apache/cassandra/transport/ProtocolVersionLimit;
3: return
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 4 0 this Lorg/apache/cassandra/transport/Frame$Decoder;
0 4 1 factory Lorg/apache/cassandra/transport/Connection$Factory;
0 4 2 versionCap Lorg/apache/cassandra/transport/ProtocolVersionLimit;
MethodParameters:
Name Flags
factory
versionCap
protected void decode(io.netty.channel.ChannelHandlerContext, io.netty.buffer.ByteBuf, java.util.List<java.lang.Object>);
descriptor: (Lio/netty/channel/ChannelHandlerContext;Lio/netty/buffer/ByteBuf;Ljava/util/List;)V
flags: (0x0004) ACC_PROTECTED
Code:
stack=11, locals=21, args_size=4
start local 0 start local 1 start local 2 start local 3 0: aload 0
getfield org.apache.cassandra.transport.Frame$Decoder.discardingTooLongFrame:Z
ifeq 5
1: aload 0
aload 2
aload 0
getfield org.apache.cassandra.transport.Frame$Decoder.bytesToDiscard:J
invokestatic org.apache.cassandra.transport.Frame.discard:(Lio/netty/buffer/ByteBuf;J)J
putfield org.apache.cassandra.transport.Frame$Decoder.bytesToDiscard:J
2: aload 0
getfield org.apache.cassandra.transport.Frame$Decoder.bytesToDiscard:J
lconst_0
lcmp
ifgt 4
3: aload 0
invokevirtual org.apache.cassandra.transport.Frame$Decoder.fail:()V
4: StackMap locals:
StackMap stack:
return
5: StackMap locals:
StackMap stack:
aload 2
invokevirtual io.netty.buffer.ByteBuf.readableBytes:()I
istore 4
start local 4 6: iload 4
ifne 8
7: return
8: StackMap locals: int
StackMap stack:
aload 2
invokevirtual io.netty.buffer.ByteBuf.readerIndex:()I
istore 5
start local 5 9: aload 2
iload 5
iinc 5 1
invokevirtual io.netty.buffer.ByteBuf.getByte:(I)B
istore 6
start local 6 10: iload 6
invokestatic org.apache.cassandra.transport.Message$Direction.extractFromVersion:(I)Lorg/apache/cassandra/transport/Message$Direction;
astore 7
start local 7 11: iload 6
bipush 127
iand
istore 8
start local 8 12: iload 8
aload 0
getfield org.apache.cassandra.transport.Frame$Decoder.versionCap:Lorg/apache/cassandra/transport/ProtocolVersionLimit;
invokestatic org.apache.cassandra.transport.ProtocolVersion.decode:(ILorg/apache/cassandra/transport/ProtocolVersionLimit;)Lorg/apache/cassandra/transport/ProtocolVersion;
astore 9
start local 9 13: iload 4
bipush 9
if_icmpge 15
14: return
15: StackMap locals: org.apache.cassandra.transport.Frame$Decoder io.netty.channel.ChannelHandlerContext io.netty.buffer.ByteBuf java.util.List int int int org.apache.cassandra.transport.Message$Direction int org.apache.cassandra.transport.ProtocolVersion
StackMap stack:
aload 2
iload 5
iinc 5 1
invokevirtual io.netty.buffer.ByteBuf.getByte:(I)B
istore 10
start local 10 16: iload 10
invokestatic org.apache.cassandra.transport.Frame$Header$Flag.deserialize:(I)Ljava/util/EnumSet;
astore 11
start local 11 17: aload 9
invokevirtual org.apache.cassandra.transport.ProtocolVersion.isBeta:()Z
ifeq 21
aload 11
getstatic org.apache.cassandra.transport.Frame$Header$Flag.USE_BETA:Lorg/apache/cassandra/transport/Frame$Header$Flag;
invokevirtual java.util.EnumSet.contains:(Ljava/lang/Object;)Z
ifne 21
18: new org.apache.cassandra.transport.ProtocolException
dup
ldc "Beta version of the protocol used (%s), but USE_BETA flag is unset"
iconst_1
anewarray java.lang.Object
dup
iconst_0
aload 9
aastore
invokestatic java.lang.String.format:(Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/String;
19: aload 9
20: invokespecial org.apache.cassandra.transport.ProtocolException.<init>:(Ljava/lang/String;Lorg/apache/cassandra/transport/ProtocolVersion;)V
athrow
21: StackMap locals: int java.util.EnumSet
StackMap stack:
aload 2
iload 5
invokevirtual io.netty.buffer.ByteBuf.getShort:(I)S
istore 12
start local 12 22: iinc 5 2
23: aload 2
iload 5
iinc 5 1
invokevirtual io.netty.buffer.ByteBuf.getByte:(I)B
aload 7
invokestatic org.apache.cassandra.transport.Message$Type.fromOpcode:(ILorg/apache/cassandra/transport/Message$Direction;)Lorg/apache/cassandra/transport/Message$Type;
astore 13
start local 13 24: goto 27
end local 13 25: StackMap locals: org.apache.cassandra.transport.Frame$Decoder io.netty.channel.ChannelHandlerContext io.netty.buffer.ByteBuf java.util.List int int int org.apache.cassandra.transport.Message$Direction int org.apache.cassandra.transport.ProtocolVersion int java.util.EnumSet int
StackMap stack: org.apache.cassandra.transport.ProtocolException
astore 14
start local 14 26: aload 14
iload 12
invokestatic org.apache.cassandra.transport.messages.ErrorMessage.wrap:(Ljava/lang/Throwable;I)Ljava/lang/RuntimeException;
athrow
end local 14 start local 13 27: StackMap locals: org.apache.cassandra.transport.Message$Type
StackMap stack:
aload 2
iload 5
invokevirtual io.netty.buffer.ByteBuf.getUnsignedInt:(I)J
lstore 14
start local 14 28: iinc 5 4
29: lload 14
ldc 9
ladd
lstore 16
start local 16 30: lload 16
getstatic org.apache.cassandra.transport.Frame$Decoder.MAX_FRAME_LENGTH:I
i2l
lcmp
ifle 38
31: aload 0
iconst_1
putfield org.apache.cassandra.transport.Frame$Decoder.discardingTooLongFrame:Z
32: aload 0
iload 12
putfield org.apache.cassandra.transport.Frame$Decoder.tooLongStreamId:I
33: aload 0
lload 16
putfield org.apache.cassandra.transport.Frame$Decoder.tooLongFrameLength:J
34: aload 0
aload 2
lload 16
invokestatic org.apache.cassandra.transport.Frame.discard:(Lio/netty/buffer/ByteBuf;J)J
putfield org.apache.cassandra.transport.Frame$Decoder.bytesToDiscard:J
35: aload 0
getfield org.apache.cassandra.transport.Frame$Decoder.bytesToDiscard:J
lconst_0
lcmp
ifgt 37
36: aload 0
invokevirtual org.apache.cassandra.transport.Frame$Decoder.fail:()V
37: StackMap locals: long long
StackMap stack:
return
38: StackMap locals:
StackMap stack:
aload 2
invokevirtual io.netty.buffer.ByteBuf.readableBytes:()I
i2l
lload 16
lcmp
ifge 40
39: return
40: StackMap locals:
StackMap stack:
aload 2
iload 5
lload 14
l2i
invokevirtual io.netty.buffer.ByteBuf.slice:(II)Lio/netty/buffer/ByteBuf;
astore 18
start local 18 41: aload 18
invokevirtual io.netty.buffer.ByteBuf.retain:()Lio/netty/buffer/ByteBuf;
pop
42: iload 5
i2l
lload 14
ladd
l2i
istore 5
43: aload 2
iload 5
invokevirtual io.netty.buffer.ByteBuf.readerIndex:(I)Lio/netty/buffer/ByteBuf;
pop
44: aload 1
invokeinterface io.netty.channel.ChannelHandlerContext.channel:()Lio/netty/channel/Channel;
getstatic org.apache.cassandra.transport.Connection.attributeKey:Lio/netty/util/AttributeKey;
invokeinterface io.netty.channel.Channel.attr:(Lio/netty/util/AttributeKey;)Lio/netty/util/Attribute;
astore 19
start local 19 45: aload 19
invokeinterface io.netty.util.Attribute.get:()Ljava/lang/Object;
checkcast org.apache.cassandra.transport.Connection
astore 20
start local 20 46: aload 20
ifnonnull 50
47: aload 0
getfield org.apache.cassandra.transport.Frame$Decoder.factory:Lorg/apache/cassandra/transport/Connection$Factory;
aload 1
invokeinterface io.netty.channel.ChannelHandlerContext.channel:()Lio/netty/channel/Channel;
aload 9
invokeinterface org.apache.cassandra.transport.Connection$Factory.newConnection:(Lio/netty/channel/Channel;Lorg/apache/cassandra/transport/ProtocolVersion;)Lorg/apache/cassandra/transport/Connection;
astore 20
48: aload 19
aload 20
invokeinterface io.netty.util.Attribute.set:(Ljava/lang/Object;)V
49: goto 57
50: StackMap locals: io.netty.buffer.ByteBuf io.netty.util.Attribute org.apache.cassandra.transport.Connection
StackMap stack:
aload 20
invokevirtual org.apache.cassandra.transport.Connection.getVersion:()Lorg/apache/cassandra/transport/ProtocolVersion;
aload 9
if_acmpeq 57
51: new org.apache.cassandra.transport.ProtocolException
dup
52: ldc "Invalid message version. Got %s but previous messages on this connection had version %s"
iconst_2
anewarray java.lang.Object
dup
iconst_0
53: aload 9
aastore
dup
iconst_1
aload 20
invokevirtual org.apache.cassandra.transport.Connection.getVersion:()Lorg/apache/cassandra/transport/ProtocolVersion;
aastore
54: invokestatic java.lang.String.format:(Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/String;
invokespecial org.apache.cassandra.transport.ProtocolException.<init>:(Ljava/lang/String;)V
55: iload 12
56: invokestatic org.apache.cassandra.transport.messages.ErrorMessage.wrap:(Ljava/lang/Throwable;I)Ljava/lang/RuntimeException;
athrow
57: StackMap locals:
StackMap stack:
aload 3
new org.apache.cassandra.transport.Frame
dup
new org.apache.cassandra.transport.Frame$Header
dup
aload 9
aload 11
iload 12
aload 13
lload 14
invokespecial org.apache.cassandra.transport.Frame$Header.<init>:(Lorg/apache/cassandra/transport/ProtocolVersion;Ljava/util/EnumSet;ILorg/apache/cassandra/transport/Message$Type;J)V
aload 18
invokespecial org.apache.cassandra.transport.Frame.<init>:(Lorg/apache/cassandra/transport/Frame$Header;Lio/netty/buffer/ByteBuf;)V
invokeinterface java.util.List.add:(Ljava/lang/Object;)Z
pop
58: return
end local 20 end local 19 end local 18 end local 16 end local 14 end local 13 end local 12 end local 11 end local 10 end local 9 end local 8 end local 7 end local 6 end local 5 end local 4 end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 59 0 this Lorg/apache/cassandra/transport/Frame$Decoder;
0 59 1 ctx Lio/netty/channel/ChannelHandlerContext;
0 59 2 buffer Lio/netty/buffer/ByteBuf;
0 59 3 results Ljava/util/List<Ljava/lang/Object;>;
6 59 4 readableBytes I
9 59 5 idx I
10 59 6 firstByte I
11 59 7 direction Lorg/apache/cassandra/transport/Message$Direction;
12 59 8 versionNum I
13 59 9 version Lorg/apache/cassandra/transport/ProtocolVersion;
16 59 10 flags I
17 59 11 decodedFlags Ljava/util/EnumSet<Lorg/apache/cassandra/transport/Frame$Header$Flag;>;
22 59 12 streamId I
24 25 13 type Lorg/apache/cassandra/transport/Message$Type;
27 59 13 type Lorg/apache/cassandra/transport/Message$Type;
26 27 14 e Lorg/apache/cassandra/transport/ProtocolException;
28 59 14 bodyLength J
30 59 16 frameLength J
41 59 18 body Lio/netty/buffer/ByteBuf;
45 59 19 attrConn Lio/netty/util/Attribute<Lorg/apache/cassandra/transport/Connection;>;
46 59 20 connection Lorg/apache/cassandra/transport/Connection;
Exception table:
from to target type
23 24 25 Class org.apache.cassandra.transport.ProtocolException
Exceptions:
throws java.lang.Exception
Signature: (Lio/netty/channel/ChannelHandlerContext;Lio/netty/buffer/ByteBuf;Ljava/util/List<Ljava/lang/Object;>;)V
MethodParameters:
Name Flags
ctx
buffer
results
private void fail();
descriptor: ()V
flags: (0x0002) ACC_PRIVATE
Code:
stack=6, locals=4, args_size=1
start local 0 0: aload 0
getfield org.apache.cassandra.transport.Frame$Decoder.tooLongFrameLength:J
lstore 1
start local 1 1: aload 0
lconst_0
putfield org.apache.cassandra.transport.Frame$Decoder.tooLongFrameLength:J
2: aload 0
iconst_0
putfield org.apache.cassandra.transport.Frame$Decoder.discardingTooLongFrame:Z
3: ldc "Request is too big: length %d exceeds maximum allowed length %d."
iconst_2
anewarray java.lang.Object
dup
iconst_0
lload 1
invokestatic java.lang.Long.valueOf:(J)Ljava/lang/Long;
aastore
dup
iconst_1
getstatic org.apache.cassandra.transport.Frame$Decoder.MAX_FRAME_LENGTH:I
invokestatic java.lang.Integer.valueOf:(I)Ljava/lang/Integer;
aastore
invokestatic java.lang.String.format:(Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/String;
astore 3
start local 3 4: new org.apache.cassandra.exceptions.InvalidRequestException
dup
aload 3
invokespecial org.apache.cassandra.exceptions.InvalidRequestException.<init>:(Ljava/lang/String;)V
aload 0
getfield org.apache.cassandra.transport.Frame$Decoder.tooLongStreamId:I
invokestatic org.apache.cassandra.transport.messages.ErrorMessage.wrap:(Ljava/lang/Throwable;I)Ljava/lang/RuntimeException;
athrow
end local 3 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 5 0 this Lorg/apache/cassandra/transport/Frame$Decoder;
1 5 1 tooLongFrameLength J
4 5 3 msg Ljava/lang/String;
}
SourceFile: "Frame.java"
NestHost: org.apache.cassandra.transport.Frame
InnerClasses:
public abstract Factory = org.apache.cassandra.transport.Connection$Factory of org.apache.cassandra.transport.Connection
public Decoder = org.apache.cassandra.transport.Frame$Decoder of org.apache.cassandra.transport.Frame
public Header = org.apache.cassandra.transport.Frame$Header of org.apache.cassandra.transport.Frame
public final Flag = org.apache.cassandra.transport.Frame$Header$Flag of org.apache.cassandra.transport.Frame$Header
public final Direction = org.apache.cassandra.transport.Message$Direction of org.apache.cassandra.transport.Message
public final Type = org.apache.cassandra.transport.Message$Type of org.apache.cassandra.transport.Message