Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
N
neo
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Stefane Fermigier
neo
Commits
3e4d0dd7
Commit
3e4d0dd7
authored
Sep 03, 2017
by
Kirill Smelkov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
.
parent
bc16d2ee
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
374 additions
and
350 deletions
+374
-350
go/neo/proto.go
go/neo/proto.go
+16
-13
go/neo/protogen.go
go/neo/protogen.go
+4
-1
go/neo/zproto-marshal.go
go/neo/zproto-marshal.go
+354
-336
No files found.
go/neo/proto.go
View file @
3e4d0dd7
...
...
@@ -32,8 +32,9 @@ package neo
// The order of message definitions is significant - messages are assigned
// message IDs in the same order they are defined.
//
// For compatibility with neo/py is a message should have its ID assigned with
// "answer" bit set its definition is prefixed with `//neo:proto answer` comment.
// For compatibility with neo/py a message has its ID assigned with "answer"
// bit set if either message name starts with "Answer" or message definition is
// prefixed with `//neo:proto answer` comment.
// TODO regroup messages definitions to stay more close to 1 communication topic
// TODO document protocol itself better (who sends who what with which semantic)
...
...
@@ -291,7 +292,8 @@ type RowInfo struct {
// Error is a special type of message, because this can be sent against
// any other message, even if such a message does not expect a reply
// usually. Any -> Any.
// FIXME -> |RESPONSE_MASK
//
//neo:proto answer
type
Error
struct
{
Code
ErrorCode
// PNumber
Message
string
...
...
@@ -317,9 +319,10 @@ type AcceptIdentification struct {
}
// Check if a peer is still alive. Any -> Any.
type
Ping
struct
{
// TODO _answer = PFEmpty
}
type
Ping
struct
{}
//neo:proto answer
type
Pong
struct
{}
// Tell peer it can close the connection if it has finished with us. Any -> Any
type
CloseClient
struct
{
...
...
@@ -341,6 +344,13 @@ type NotPrimaryMaster struct {
}
}
// Notify information about one or more nodes. PM -> Any.
type
NotifyNodeInformation
struct
{
// XXX in py this is monotonic_time() of call to broadcastNodesInformation() & friends
IdTimestamp
float64
NodeList
[]
NodeInfo
}
// Ask all data needed by master to recover. PM -> S, S -> PM.
type
Recovery
struct
{
}
...
...
@@ -722,13 +732,6 @@ type TweakPartitionTable struct {
// XXX _answer = Error
}
// Notify information about one or more nodes. PM -> Any.
type
NotifyNodeInformation
struct
{
// XXX in py this is monotonic_time() of call to broadcastNodesInformation() & friends
IdTimestamp
float64
NodeList
[]
NodeInfo
}
// Ask node information
type
NodeInformation
struct
{
// XXX _answer = PFEmpty
...
...
go/neo/protogen.go
View file @
3e4d0dd7
...
...
@@ -293,7 +293,10 @@ import (
}
// generate code for this type to implement neo.Msg
msgCode
:=
MsgCode
{
msgSerial
,
specAnnotation
.
answer
}
msgCode
:=
MsgCode
{
msgSerial
:
msgSerial
,
answer
:
specAnnotation
.
answer
||
strings
.
HasPrefix
(
typename
,
"Answer"
),
}
fmt
.
Fprintf
(
&
buf
,
"// %d. %s"
,
msgSerial
,
typename
)
if
specAnnotation
.
answer
{
...
...
go/neo/zproto-marshal.go
View file @
3e4d0dd7
...
...
@@ -14,10 +14,10 @@ import (
// messages marshalling
// 0. Error
// 0. Error
(answer)
func
(
*
Error
)
neoMsgCode
()
uint16
{
return
0
return
0
|
answerBit
}
func
(
p
*
Error
)
neoMsgEncodedLen
()
int
{
...
...
@@ -173,10 +173,27 @@ func (p *Ping) neoMsgDecode(data []byte) (int, error) {
return
0
,
nil
}
// 4. CloseClient
// 4. Pong (answer)
func
(
*
Pong
)
neoMsgCode
()
uint16
{
return
4
|
answerBit
}
func
(
p
*
Pong
)
neoMsgEncodedLen
()
int
{
return
0
}
func
(
p
*
Pong
)
neoMsgEncode
(
data
[]
byte
)
{
}
func
(
p
*
Pong
)
neoMsgDecode
(
data
[]
byte
)
(
int
,
error
)
{
return
0
,
nil
}
// 5. CloseClient
func
(
*
CloseClient
)
neoMsgCode
()
uint16
{
return
4
return
5
}
func
(
p
*
CloseClient
)
neoMsgEncodedLen
()
int
{
...
...
@@ -190,10 +207,10 @@ func (p *CloseClient) neoMsgDecode(data []byte) (int, error) {
return
0
,
nil
}
//
5
. PrimaryMaster
//
6
. PrimaryMaster
func
(
*
PrimaryMaster
)
neoMsgCode
()
uint16
{
return
5
return
6
}
func
(
p
*
PrimaryMaster
)
neoMsgEncodedLen
()
int
{
...
...
@@ -207,10 +224,10 @@ func (p *PrimaryMaster) neoMsgDecode(data []byte) (int, error) {
return
0
,
nil
}
//
6
. AnswerPrimary
//
7
. AnswerPrimary
func
(
*
AnswerPrimary
)
neoMsgCode
()
uint16
{
return
6
return
7
|
answerBit
}
func
(
p
*
AnswerPrimary
)
neoMsgEncodedLen
()
int
{
...
...
@@ -232,10 +249,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
//
7
. NotPrimaryMaster
//
8
. NotPrimaryMaster
func
(
*
NotPrimaryMaster
)
neoMsgCode
()
uint16
{
return
7
return
8
}
func
(
p
*
NotPrimaryMaster
)
neoMsgEncodedLen
()
int
{
...
...
@@ -304,10 +321,90 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 8. Recovery
// 9. NotifyNodeInformation
func
(
*
NotifyNodeInformation
)
neoMsgCode
()
uint16
{
return
9
}
func
(
p
*
NotifyNodeInformation
)
neoMsgEncodedLen
()
int
{
var
size
int
for
i
:=
0
;
i
<
len
(
p
.
NodeList
);
i
++
{
a
:=
&
p
.
NodeList
[
i
]
size
+=
len
((
*
a
)
.
Addr
.
Host
)
}
return
12
+
len
(
p
.
NodeList
)
*
26
+
size
}
func
(
p
*
NotifyNodeInformation
)
neoMsgEncode
(
data
[]
byte
)
{
float64_NEOEncode
(
data
[
0
:
],
p
.
IdTimestamp
)
{
l
:=
uint32
(
len
(
p
.
NodeList
))
binary
.
BigEndian
.
PutUint32
(
data
[
8
:
],
l
)
data
=
data
[
12
:
]
for
i
:=
0
;
uint32
(
i
)
<
l
;
i
++
{
a
:=
&
p
.
NodeList
[
i
]
binary
.
BigEndian
.
PutUint32
(
data
[
0
:
],
uint32
(
int32
((
*
a
)
.
Type
)))
{
l
:=
uint32
(
len
((
*
a
)
.
Addr
.
Host
))
binary
.
BigEndian
.
PutUint32
(
data
[
4
:
],
l
)
data
=
data
[
8
:
]
copy
(
data
,
(
*
a
)
.
Addr
.
Host
)
data
=
data
[
l
:
]
}
binary
.
BigEndian
.
PutUint16
(
data
[
0
:
],
(
*
a
)
.
Addr
.
Port
)
binary
.
BigEndian
.
PutUint32
(
data
[
2
:
],
uint32
(
int32
((
*
a
)
.
UUID
)))
binary
.
BigEndian
.
PutUint32
(
data
[
6
:
],
uint32
(
int32
((
*
a
)
.
State
)))
float64_NEOEncode
(
data
[
10
:
],
(
*
a
)
.
IdTimestamp
)
data
=
data
[
18
:
]
}
}
}
func
(
p
*
NotifyNodeInformation
)
neoMsgDecode
(
data
[]
byte
)
(
int
,
error
)
{
var
nread
uint32
if
uint32
(
len
(
data
))
<
12
{
goto
overflow
}
p
.
IdTimestamp
=
float64_NEODecode
(
data
[
0
:
])
{
l
:=
binary
.
BigEndian
.
Uint32
(
data
[
8
:
])
data
=
data
[
12
:
]
p
.
NodeList
=
make
([]
NodeInfo
,
l
)
for
i
:=
0
;
uint32
(
i
)
<
l
;
i
++
{
a
:=
&
p
.
NodeList
[
i
]
if
uint32
(
len
(
data
))
<
8
{
goto
overflow
}
(
*
a
)
.
Type
=
NodeType
(
int32
(
binary
.
BigEndian
.
Uint32
(
data
[
0
:
])))
{
l
:=
binary
.
BigEndian
.
Uint32
(
data
[
4
:
])
data
=
data
[
8
:
]
if
uint32
(
len
(
data
))
<
18
+
l
{
goto
overflow
}
nread
+=
18
+
l
(
*
a
)
.
Addr
.
Host
=
string
(
data
[
:
l
])
data
=
data
[
l
:
]
}
(
*
a
)
.
Addr
.
Port
=
binary
.
BigEndian
.
Uint16
(
data
[
0
:
])
(
*
a
)
.
UUID
=
NodeUUID
(
int32
(
binary
.
BigEndian
.
Uint32
(
data
[
2
:
])))
(
*
a
)
.
State
=
NodeState
(
int32
(
binary
.
BigEndian
.
Uint32
(
data
[
6
:
])))
(
*
a
)
.
IdTimestamp
=
float64_NEODecode
(
data
[
10
:
])
data
=
data
[
18
:
]
}
nread
+=
l
*
8
}
return
12
+
int
(
nread
),
nil
overflow
:
return
0
,
ErrDecodeOverflow
}
// 10. Recovery
func
(
*
Recovery
)
neoMsgCode
()
uint16
{
return
8
return
10
}
func
(
p
*
Recovery
)
neoMsgEncodedLen
()
int
{
...
...
@@ -321,10 +418,10 @@ func (p *Recovery) neoMsgDecode(data []byte) (int, error) {
return
0
,
nil
}
//
9
. AnswerRecovery
//
11
. AnswerRecovery
func
(
*
AnswerRecovery
)
neoMsgCode
()
uint16
{
return
9
return
11
|
answerBit
}
func
(
p
*
AnswerRecovery
)
neoMsgEncodedLen
()
int
{
...
...
@@ -350,10 +447,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 1
0
. LastIDs
// 1
2
. LastIDs
func
(
*
LastIDs
)
neoMsgCode
()
uint16
{
return
1
0
return
1
2
}
func
(
p
*
LastIDs
)
neoMsgEncodedLen
()
int
{
...
...
@@ -367,10 +464,10 @@ func (p *LastIDs) neoMsgDecode(data []byte) (int, error) {
return
0
,
nil
}
// 1
1
. AnswerLastIDs
// 1
3
. AnswerLastIDs
func
(
*
AnswerLastIDs
)
neoMsgCode
()
uint16
{
return
1
1
return
1
3
|
answerBit
}
func
(
p
*
AnswerLastIDs
)
neoMsgEncodedLen
()
int
{
...
...
@@ -394,10 +491,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 1
2
. AskPartitionTable
// 1
4
. AskPartitionTable
func
(
*
AskPartitionTable
)
neoMsgCode
()
uint16
{
return
1
2
return
1
4
}
func
(
p
*
AskPartitionTable
)
neoMsgEncodedLen
()
int
{
...
...
@@ -411,10 +508,10 @@ func (p *AskPartitionTable) neoMsgDecode(data []byte) (int, error) {
return
0
,
nil
}
// 1
3
. AnswerPartitionTable
// 1
5
. AnswerPartitionTable
func
(
*
AnswerPartitionTable
)
neoMsgCode
()
uint16
{
return
1
3
return
1
5
|
answerBit
}
func
(
p
*
AnswerPartitionTable
)
neoMsgEncodedLen
()
int
{
...
...
@@ -491,10 +588,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 1
4
. NotifyPartitionTable
// 1
6
. NotifyPartitionTable
func
(
*
NotifyPartitionTable
)
neoMsgCode
()
uint16
{
return
1
4
return
1
6
}
func
(
p
*
NotifyPartitionTable
)
neoMsgEncodedLen
()
int
{
...
...
@@ -571,10 +668,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 1
5
. NotifyPartitionChanges
// 1
7
. NotifyPartitionChanges
func
(
*
NotifyPartitionChanges
)
neoMsgCode
()
uint16
{
return
1
5
return
1
7
}
func
(
p
*
NotifyPartitionChanges
)
neoMsgEncodedLen
()
int
{
...
...
@@ -628,10 +725,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 1
6
. StartOperation
// 1
8
. StartOperation
func
(
*
StartOperation
)
neoMsgCode
()
uint16
{
return
1
6
return
1
8
}
func
(
p
*
StartOperation
)
neoMsgEncodedLen
()
int
{
...
...
@@ -653,10 +750,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 1
7
. StopOperation
// 1
9
. StopOperation
func
(
*
StopOperation
)
neoMsgCode
()
uint16
{
return
1
7
return
1
9
}
func
(
p
*
StopOperation
)
neoMsgEncodedLen
()
int
{
...
...
@@ -670,10 +767,10 @@ func (p *StopOperation) neoMsgDecode(data []byte) (int, error) {
return
0
,
nil
}
//
18
. UnfinishedTransactions
//
20
. UnfinishedTransactions
func
(
*
UnfinishedTransactions
)
neoMsgCode
()
uint16
{
return
18
return
20
}
func
(
p
*
UnfinishedTransactions
)
neoMsgEncodedLen
()
int
{
...
...
@@ -718,10 +815,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
//
19
. AnswerUnfinishedTransactions
//
21
. AnswerUnfinishedTransactions
func
(
*
AnswerUnfinishedTransactions
)
neoMsgCode
()
uint16
{
return
19
return
21
|
answerBit
}
func
(
p
*
AnswerUnfinishedTransactions
)
neoMsgEncodedLen
()
int
{
...
...
@@ -768,10 +865,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 2
0
. LockedTransactions
// 2
2
. LockedTransactions
func
(
*
LockedTransactions
)
neoMsgCode
()
uint16
{
return
2
0
return
2
2
}
func
(
p
*
LockedTransactions
)
neoMsgEncodedLen
()
int
{
...
...
@@ -785,10 +882,10 @@ func (p *LockedTransactions) neoMsgDecode(data []byte) (int, error) {
return
0
,
nil
}
// 2
1
. AnswerLockedTransactions
// 2
3
. AnswerLockedTransactions
func
(
*
AnswerLockedTransactions
)
neoMsgCode
()
uint16
{
return
2
1
return
2
3
|
answerBit
}
func
(
p
*
AnswerLockedTransactions
)
neoMsgEncodedLen
()
int
{
...
...
@@ -839,10 +936,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 2
2
. FinalTID
// 2
4
. FinalTID
func
(
*
FinalTID
)
neoMsgCode
()
uint16
{
return
2
2
return
2
4
}
func
(
p
*
FinalTID
)
neoMsgEncodedLen
()
int
{
...
...
@@ -864,10 +961,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 2
3
. AnswerFinalTID
// 2
5
. AnswerFinalTID
func
(
*
AnswerFinalTID
)
neoMsgCode
()
uint16
{
return
2
3
return
2
5
|
answerBit
}
func
(
p
*
AnswerFinalTID
)
neoMsgEncodedLen
()
int
{
...
...
@@ -889,10 +986,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 2
4
. ValidateTransaction
// 2
6
. ValidateTransaction
func
(
*
ValidateTransaction
)
neoMsgCode
()
uint16
{
return
2
4
return
2
6
}
func
(
p
*
ValidateTransaction
)
neoMsgEncodedLen
()
int
{
...
...
@@ -916,10 +1013,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 2
5
. BeginTransaction
// 2
7
. BeginTransaction
func
(
*
BeginTransaction
)
neoMsgCode
()
uint16
{
return
2
5
return
2
7
}
func
(
p
*
BeginTransaction
)
neoMsgEncodedLen
()
int
{
...
...
@@ -941,10 +1038,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 2
6
. AnswerBeginTransaction
// 2
8
. AnswerBeginTransaction
func
(
*
AnswerBeginTransaction
)
neoMsgCode
()
uint16
{
return
2
6
return
2
8
|
answerBit
}
func
(
p
*
AnswerBeginTransaction
)
neoMsgEncodedLen
()
int
{
...
...
@@ -966,10 +1063,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 2
7
. FailedVote
// 2
9
. FailedVote
func
(
*
FailedVote
)
neoMsgCode
()
uint16
{
return
2
7
return
2
9
}
func
(
p
*
FailedVote
)
neoMsgEncodedLen
()
int
{
...
...
@@ -1016,10 +1113,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
//
28
. FinishTransaction
//
30
. FinishTransaction
func
(
*
FinishTransaction
)
neoMsgCode
()
uint16
{
return
28
return
30
}
func
(
p
*
FinishTransaction
)
neoMsgEncodedLen
()
int
{
...
...
@@ -1090,10 +1187,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
//
29
. AnswerFinishTransaction
//
31
. AnswerFinishTransaction
func
(
*
AnswerFinishTransaction
)
neoMsgCode
()
uint16
{
return
29
return
31
|
answerBit
}
func
(
p
*
AnswerFinishTransaction
)
neoMsgEncodedLen
()
int
{
...
...
@@ -1117,10 +1214,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 3
0
. NotifyTransactionFinished
// 3
2
. NotifyTransactionFinished
func
(
*
NotifyTransactionFinished
)
neoMsgCode
()
uint16
{
return
3
0
return
3
2
}
func
(
p
*
NotifyTransactionFinished
)
neoMsgEncodedLen
()
int
{
...
...
@@ -1144,10 +1241,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 3
1
. LockInformation
// 3
3
. LockInformation
func
(
*
LockInformation
)
neoMsgCode
()
uint16
{
return
3
1
return
3
3
}
func
(
p
*
LockInformation
)
neoMsgEncodedLen
()
int
{
...
...
@@ -1171,10 +1268,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 3
2
. AnswerLockInformation
// 3
4
. AnswerLockInformation
func
(
*
AnswerLockInformation
)
neoMsgCode
()
uint16
{
return
3
2
return
3
4
|
answerBit
}
func
(
p
*
AnswerLockInformation
)
neoMsgEncodedLen
()
int
{
...
...
@@ -1196,10 +1293,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 3
3
. InvalidateObjects
// 3
5
. InvalidateObjects
func
(
*
InvalidateObjects
)
neoMsgCode
()
uint16
{
return
3
3
return
3
5
}
func
(
p
*
InvalidateObjects
)
neoMsgEncodedLen
()
int
{
...
...
@@ -1246,10 +1343,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 3
4
. UnlockInformation
// 3
6
. UnlockInformation
func
(
*
UnlockInformation
)
neoMsgCode
()
uint16
{
return
3
4
return
3
6
}
func
(
p
*
UnlockInformation
)
neoMsgEncodedLen
()
int
{
...
...
@@ -1271,10 +1368,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 3
5
. GenerateOIDs
// 3
7
. GenerateOIDs
func
(
*
GenerateOIDs
)
neoMsgCode
()
uint16
{
return
3
5
return
3
7
}
func
(
p
*
GenerateOIDs
)
neoMsgEncodedLen
()
int
{
...
...
@@ -1296,10 +1393,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 3
6
. AnswerGenerateOIDs
// 3
8
. AnswerGenerateOIDs
func
(
*
AnswerGenerateOIDs
)
neoMsgCode
()
uint16
{
return
3
6
return
3
8
|
answerBit
}
func
(
p
*
AnswerGenerateOIDs
)
neoMsgEncodedLen
()
int
{
...
...
@@ -1344,10 +1441,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 3
7
. Deadlock
// 3
9
. Deadlock
func
(
*
Deadlock
)
neoMsgCode
()
uint16
{
return
3
7
return
3
9
}
func
(
p
*
Deadlock
)
neoMsgEncodedLen
()
int
{
...
...
@@ -1371,10 +1468,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
//
38
. RebaseTransaction
//
40
. RebaseTransaction
func
(
*
RebaseTransaction
)
neoMsgCode
()
uint16
{
return
38
return
40
}
func
(
p
*
RebaseTransaction
)
neoMsgEncodedLen
()
int
{
...
...
@@ -1398,10 +1495,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
//
39
. AnswerRebaseTransaction
//
41
. AnswerRebaseTransaction
func
(
*
AnswerRebaseTransaction
)
neoMsgCode
()
uint16
{
return
39
return
41
|
answerBit
}
func
(
p
*
AnswerRebaseTransaction
)
neoMsgEncodedLen
()
int
{
...
...
@@ -1446,10 +1543,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 4
0
. RebaseObject
// 4
2
. RebaseObject
func
(
*
RebaseObject
)
neoMsgCode
()
uint16
{
return
4
0
return
4
2
}
func
(
p
*
RebaseObject
)
neoMsgEncodedLen
()
int
{
...
...
@@ -1473,10 +1570,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 4
1
. AnswerRebaseObject
// 4
3
. AnswerRebaseObject
func
(
*
AnswerRebaseObject
)
neoMsgCode
()
uint16
{
return
4
1
return
4
3
|
answerBit
}
func
(
p
*
AnswerRebaseObject
)
neoMsgEncodedLen
()
int
{
...
...
@@ -1523,10 +1620,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 4
2
. StoreObject
// 4
4
. StoreObject
func
(
*
StoreObject
)
neoMsgCode
()
uint16
{
return
4
2
return
4
4
}
func
(
p
*
StoreObject
)
neoMsgEncodedLen
()
int
{
...
...
@@ -1577,10 +1674,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 4
3
. AnswerStoreObject
// 4
5
. AnswerStoreObject
func
(
*
AnswerStoreObject
)
neoMsgCode
()
uint16
{
return
4
3
return
4
5
|
answerBit
}
func
(
p
*
AnswerStoreObject
)
neoMsgEncodedLen
()
int
{
...
...
@@ -1602,10 +1699,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 4
4
. AbortTransaction
// 4
6
. AbortTransaction
func
(
*
AbortTransaction
)
neoMsgCode
()
uint16
{
return
4
4
return
4
6
}
func
(
p
*
AbortTransaction
)
neoMsgEncodedLen
()
int
{
...
...
@@ -1652,10 +1749,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 4
5
. StoreTransaction
// 4
7
. StoreTransaction
func
(
*
StoreTransaction
)
neoMsgCode
()
uint16
{
return
4
5
return
4
7
}
func
(
p
*
StoreTransaction
)
neoMsgEncodedLen
()
int
{
...
...
@@ -1753,10 +1850,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 4
6
. VoteTransaction
// 4
8
. VoteTransaction
func
(
*
VoteTransaction
)
neoMsgCode
()
uint16
{
return
4
6
return
4
8
}
func
(
p
*
VoteTransaction
)
neoMsgEncodedLen
()
int
{
...
...
@@ -1778,10 +1875,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 4
7
. GetObject
// 4
9
. GetObject
func
(
*
GetObject
)
neoMsgCode
()
uint16
{
return
4
7
return
4
9
}
func
(
p
*
GetObject
)
neoMsgEncodedLen
()
int
{
...
...
@@ -1807,10 +1904,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
//
48
. AnswerGetObject
//
50
. AnswerGetObject
func
(
*
AnswerGetObject
)
neoMsgCode
()
uint16
{
return
48
return
50
|
answerBit
}
func
(
p
*
AnswerGetObject
)
neoMsgEncodedLen
()
int
{
...
...
@@ -1861,10 +1958,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
//
49
. TIDList
//
51
. TIDList
func
(
*
TIDList
)
neoMsgCode
()
uint16
{
return
49
return
51
}
func
(
p
*
TIDList
)
neoMsgEncodedLen
()
int
{
...
...
@@ -1890,10 +1987,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 5
0
. AnswerTIDList
// 5
2
. AnswerTIDList
func
(
*
AnswerTIDList
)
neoMsgCode
()
uint16
{
return
5
0
return
5
2
|
answerBit
}
func
(
p
*
AnswerTIDList
)
neoMsgEncodedLen
()
int
{
...
...
@@ -1938,10 +2035,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 5
1
. TIDListFrom
// 5
3
. TIDListFrom
func
(
*
TIDListFrom
)
neoMsgCode
()
uint16
{
return
5
1
return
5
3
}
func
(
p
*
TIDListFrom
)
neoMsgEncodedLen
()
int
{
...
...
@@ -1969,10 +2066,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 5
2
. AnswerTIDListFrom
// 5
4
. AnswerTIDListFrom
func
(
*
AnswerTIDListFrom
)
neoMsgCode
()
uint16
{
return
5
2
return
5
4
|
answerBit
}
func
(
p
*
AnswerTIDListFrom
)
neoMsgEncodedLen
()
int
{
...
...
@@ -2017,10 +2114,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 5
3
. TransactionInformation
// 5
5
. TransactionInformation
func
(
*
TransactionInformation
)
neoMsgCode
()
uint16
{
return
5
3
return
5
5
}
func
(
p
*
TransactionInformation
)
neoMsgEncodedLen
()
int
{
...
...
@@ -2042,10 +2139,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 5
4
. AnswerTransactionInformation
// 5
6
. AnswerTransactionInformation
func
(
*
AnswerTransactionInformation
)
neoMsgCode
()
uint16
{
return
5
4
return
5
6
|
answerBit
}
func
(
p
*
AnswerTransactionInformation
)
neoMsgEncodedLen
()
int
{
...
...
@@ -2145,10 +2242,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 5
5
. ObjectHistory
// 5
7
. ObjectHistory
func
(
*
ObjectHistory
)
neoMsgCode
()
uint16
{
return
5
5
return
5
7
}
func
(
p
*
ObjectHistory
)
neoMsgEncodedLen
()
int
{
...
...
@@ -2174,10 +2271,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 5
6
. AnswerObjectHistory
// 5
8
. AnswerObjectHistory
func
(
*
AnswerObjectHistory
)
neoMsgCode
()
uint16
{
return
5
6
return
5
8
|
answerBit
}
func
(
p
*
AnswerObjectHistory
)
neoMsgEncodedLen
()
int
{
...
...
@@ -2229,10 +2326,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 5
7
. PartitionList
// 5
9
. PartitionList
func
(
*
PartitionList
)
neoMsgCode
()
uint16
{
return
5
7
return
5
9
}
func
(
p
*
PartitionList
)
neoMsgEncodedLen
()
int
{
...
...
@@ -2258,10 +2355,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
//
58
. AnswerPartitionList
//
60
. AnswerPartitionList
func
(
*
AnswerPartitionList
)
neoMsgCode
()
uint16
{
return
58
return
60
|
answerBit
}
func
(
p
*
AnswerPartitionList
)
neoMsgEncodedLen
()
int
{
...
...
@@ -2338,10 +2435,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
//
59
. NodeList
//
61
. NodeList
func
(
*
NodeList
)
neoMsgCode
()
uint16
{
return
59
return
61
}
func
(
p
*
NodeList
)
neoMsgEncodedLen
()
int
{
...
...
@@ -2363,10 +2460,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 6
0
. AnswerNodeList
// 6
2
. AnswerNodeList
func
(
*
AnswerNodeList
)
neoMsgCode
()
uint16
{
return
6
0
return
6
2
|
answerBit
}
func
(
p
*
AnswerNodeList
)
neoMsgEncodedLen
()
int
{
...
...
@@ -2441,10 +2538,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 6
1
. SetNodeState
// 6
3
. SetNodeState
func
(
*
SetNodeState
)
neoMsgCode
()
uint16
{
return
6
1
return
6
3
}
func
(
p
*
SetNodeState
)
neoMsgEncodedLen
()
int
{
...
...
@@ -2468,10 +2565,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 6
2
. AddPendingNodes
// 6
4
. AddPendingNodes
func
(
*
AddPendingNodes
)
neoMsgCode
()
uint16
{
return
6
2
return
6
4
}
func
(
p
*
AddPendingNodes
)
neoMsgEncodedLen
()
int
{
...
...
@@ -2516,10 +2613,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 6
3
. TweakPartitionTable
// 6
5
. TweakPartitionTable
func
(
*
TweakPartitionTable
)
neoMsgCode
()
uint16
{
return
6
3
return
6
5
}
func
(
p
*
TweakPartitionTable
)
neoMsgEncodedLen
()
int
{
...
...
@@ -2564,90 +2661,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 64. NotifyNodeInformation
func
(
*
NotifyNodeInformation
)
neoMsgCode
()
uint16
{
return
64
}
func
(
p
*
NotifyNodeInformation
)
neoMsgEncodedLen
()
int
{
var
size
int
for
i
:=
0
;
i
<
len
(
p
.
NodeList
);
i
++
{
a
:=
&
p
.
NodeList
[
i
]
size
+=
len
((
*
a
)
.
Addr
.
Host
)
}
return
12
+
len
(
p
.
NodeList
)
*
26
+
size
}
func
(
p
*
NotifyNodeInformation
)
neoMsgEncode
(
data
[]
byte
)
{
float64_NEOEncode
(
data
[
0
:
],
p
.
IdTimestamp
)
{
l
:=
uint32
(
len
(
p
.
NodeList
))
binary
.
BigEndian
.
PutUint32
(
data
[
8
:
],
l
)
data
=
data
[
12
:
]
for
i
:=
0
;
uint32
(
i
)
<
l
;
i
++
{
a
:=
&
p
.
NodeList
[
i
]
binary
.
BigEndian
.
PutUint32
(
data
[
0
:
],
uint32
(
int32
((
*
a
)
.
Type
)))
{
l
:=
uint32
(
len
((
*
a
)
.
Addr
.
Host
))
binary
.
BigEndian
.
PutUint32
(
data
[
4
:
],
l
)
data
=
data
[
8
:
]
copy
(
data
,
(
*
a
)
.
Addr
.
Host
)
data
=
data
[
l
:
]
}
binary
.
BigEndian
.
PutUint16
(
data
[
0
:
],
(
*
a
)
.
Addr
.
Port
)
binary
.
BigEndian
.
PutUint32
(
data
[
2
:
],
uint32
(
int32
((
*
a
)
.
UUID
)))
binary
.
BigEndian
.
PutUint32
(
data
[
6
:
],
uint32
(
int32
((
*
a
)
.
State
)))
float64_NEOEncode
(
data
[
10
:
],
(
*
a
)
.
IdTimestamp
)
data
=
data
[
18
:
]
}
}
}
func
(
p
*
NotifyNodeInformation
)
neoMsgDecode
(
data
[]
byte
)
(
int
,
error
)
{
var
nread
uint32
if
uint32
(
len
(
data
))
<
12
{
goto
overflow
}
p
.
IdTimestamp
=
float64_NEODecode
(
data
[
0
:
])
{
l
:=
binary
.
BigEndian
.
Uint32
(
data
[
8
:
])
data
=
data
[
12
:
]
p
.
NodeList
=
make
([]
NodeInfo
,
l
)
for
i
:=
0
;
uint32
(
i
)
<
l
;
i
++
{
a
:=
&
p
.
NodeList
[
i
]
if
uint32
(
len
(
data
))
<
8
{
goto
overflow
}
(
*
a
)
.
Type
=
NodeType
(
int32
(
binary
.
BigEndian
.
Uint32
(
data
[
0
:
])))
{
l
:=
binary
.
BigEndian
.
Uint32
(
data
[
4
:
])
data
=
data
[
8
:
]
if
uint32
(
len
(
data
))
<
18
+
l
{
goto
overflow
}
nread
+=
18
+
l
(
*
a
)
.
Addr
.
Host
=
string
(
data
[
:
l
])
data
=
data
[
l
:
]
}
(
*
a
)
.
Addr
.
Port
=
binary
.
BigEndian
.
Uint16
(
data
[
0
:
])
(
*
a
)
.
UUID
=
NodeUUID
(
int32
(
binary
.
BigEndian
.
Uint32
(
data
[
2
:
])))
(
*
a
)
.
State
=
NodeState
(
int32
(
binary
.
BigEndian
.
Uint32
(
data
[
6
:
])))
(
*
a
)
.
IdTimestamp
=
float64_NEODecode
(
data
[
10
:
])
data
=
data
[
18
:
]
}
nread
+=
l
*
8
}
return
12
+
int
(
nread
),
nil
overflow
:
return
0
,
ErrDecodeOverflow
}
// 65. NodeInformation
// 66. NodeInformation
func
(
*
NodeInformation
)
neoMsgCode
()
uint16
{
return
6
5
return
6
6
}
func
(
p
*
NodeInformation
)
neoMsgEncodedLen
()
int
{
...
...
@@ -2661,10 +2678,10 @@ func (p *NodeInformation) neoMsgDecode(data []byte) (int, error) {
return
0
,
nil
}
// 6
6
. SetClusterState
// 6
7
. SetClusterState
func
(
*
SetClusterState
)
neoMsgCode
()
uint16
{
return
6
6
return
6
7
}
func
(
p
*
SetClusterState
)
neoMsgEncodedLen
()
int
{
...
...
@@ -2686,10 +2703,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 6
7
. repairFlags
// 6
8
. repairFlags
func
(
*
repairFlags
)
neoMsgCode
()
uint16
{
return
6
7
return
6
8
}
func
(
p
*
repairFlags
)
neoMsgEncodedLen
()
int
{
...
...
@@ -2711,10 +2728,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 6
8
. Repair
// 6
9
. Repair
func
(
*
Repair
)
neoMsgCode
()
uint16
{
return
6
8
return
6
9
}
func
(
p
*
Repair
)
neoMsgEncodedLen
()
int
{
...
...
@@ -2761,10 +2778,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
//
69
. RepairOne
//
70
. RepairOne
func
(
*
RepairOne
)
neoMsgCode
()
uint16
{
return
69
return
70
}
func
(
p
*
RepairOne
)
neoMsgEncodedLen
()
int
{
...
...
@@ -2786,10 +2803,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 7
0
. NotifyClusterState
// 7
1
. NotifyClusterState
func
(
*
NotifyClusterState
)
neoMsgCode
()
uint16
{
return
7
0
return
7
1
}
func
(
p
*
NotifyClusterState
)
neoMsgEncodedLen
()
int
{
...
...
@@ -2811,10 +2828,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 7
1
. AskClusterState
// 7
2
. AskClusterState
func
(
*
AskClusterState
)
neoMsgCode
()
uint16
{
return
7
1
return
7
2
}
func
(
p
*
AskClusterState
)
neoMsgEncodedLen
()
int
{
...
...
@@ -2828,10 +2845,10 @@ func (p *AskClusterState) neoMsgDecode(data []byte) (int, error) {
return
0
,
nil
}
// 7
2
. AnswerClusterState
// 7
3
. AnswerClusterState
func
(
*
AnswerClusterState
)
neoMsgCode
()
uint16
{
return
7
2
return
7
3
|
answerBit
}
func
(
p
*
AnswerClusterState
)
neoMsgEncodedLen
()
int
{
...
...
@@ -2853,10 +2870,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 7
3
. ObjectUndoSerial
// 7
4
. ObjectUndoSerial
func
(
*
ObjectUndoSerial
)
neoMsgCode
()
uint16
{
return
7
3
return
7
4
}
func
(
p
*
ObjectUndoSerial
)
neoMsgEncodedLen
()
int
{
...
...
@@ -2907,10 +2924,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 7
4
. AnswerObjectUndoSerial
// 7
5
. AnswerObjectUndoSerial
func
(
*
AnswerObjectUndoSerial
)
neoMsgCode
()
uint16
{
return
7
4
return
7
5
|
answerBit
}
func
(
p
*
AnswerObjectUndoSerial
)
neoMsgEncodedLen
()
int
{
...
...
@@ -2975,10 +2992,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 7
5
. CheckCurrentSerial
// 7
6
. CheckCurrentSerial
func
(
*
CheckCurrentSerial
)
neoMsgCode
()
uint16
{
return
7
5
return
7
6
}
func
(
p
*
CheckCurrentSerial
)
neoMsgEncodedLen
()
int
{
...
...
@@ -3004,10 +3021,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 7
6
. Pack
// 7
7
. Pack
func
(
*
Pack
)
neoMsgCode
()
uint16
{
return
7
6
return
7
7
}
func
(
p
*
Pack
)
neoMsgEncodedLen
()
int
{
...
...
@@ -3029,10 +3046,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 7
7
. AnswerPack
// 7
8
. AnswerPack
func
(
*
AnswerPack
)
neoMsgCode
()
uint16
{
return
7
7
return
7
8
|
answerBit
}
func
(
p
*
AnswerPack
)
neoMsgEncodedLen
()
int
{
...
...
@@ -3054,10 +3071,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 7
8
. CheckReplicas
// 7
9
. CheckReplicas
func
(
*
CheckReplicas
)
neoMsgCode
()
uint16
{
return
7
8
return
7
9
}
func
(
p
*
CheckReplicas
)
neoMsgEncodedLen
()
int
{
...
...
@@ -3112,10 +3129,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
//
79
. CheckPartition
//
80
. CheckPartition
func
(
*
CheckPartition
)
neoMsgCode
()
uint16
{
return
79
return
80
}
func
(
p
*
CheckPartition
)
neoMsgEncodedLen
()
int
{
...
...
@@ -3178,10 +3195,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 8
0
. CheckTIDRange
// 8
1
. CheckTIDRange
func
(
*
CheckTIDRange
)
neoMsgCode
()
uint16
{
return
8
0
return
8
1
}
func
(
p
*
CheckTIDRange
)
neoMsgEncodedLen
()
int
{
...
...
@@ -3209,10 +3226,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 8
1
. AnswerCheckTIDRange
// 8
2
. AnswerCheckTIDRange
func
(
*
AnswerCheckTIDRange
)
neoMsgCode
()
uint16
{
return
8
1
return
8
2
|
answerBit
}
func
(
p
*
AnswerCheckTIDRange
)
neoMsgEncodedLen
()
int
{
...
...
@@ -3238,10 +3255,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 8
2
. CheckSerialRange
// 8
3
. CheckSerialRange
func
(
*
CheckSerialRange
)
neoMsgCode
()
uint16
{
return
8
2
return
8
3
}
func
(
p
*
CheckSerialRange
)
neoMsgEncodedLen
()
int
{
...
...
@@ -3271,10 +3288,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 8
3
. AnswerCheckSerialRange
// 8
4
. AnswerCheckSerialRange
func
(
*
AnswerCheckSerialRange
)
neoMsgCode
()
uint16
{
return
8
3
return
8
4
|
answerBit
}
func
(
p
*
AnswerCheckSerialRange
)
neoMsgEncodedLen
()
int
{
...
...
@@ -3304,10 +3321,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 8
4
. PartitionCorrupted
// 8
5
. PartitionCorrupted
func
(
*
PartitionCorrupted
)
neoMsgCode
()
uint16
{
return
8
4
return
8
5
}
func
(
p
*
PartitionCorrupted
)
neoMsgEncodedLen
()
int
{
...
...
@@ -3354,10 +3371,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 8
5
. LastTransaction
// 8
6
. LastTransaction
func
(
*
LastTransaction
)
neoMsgCode
()
uint16
{
return
8
5
return
8
6
}
func
(
p
*
LastTransaction
)
neoMsgEncodedLen
()
int
{
...
...
@@ -3371,10 +3388,10 @@ func (p *LastTransaction) neoMsgDecode(data []byte) (int, error) {
return
0
,
nil
}
// 8
6
. AnswerLastTransaction
// 8
7
. AnswerLastTransaction
func
(
*
AnswerLastTransaction
)
neoMsgCode
()
uint16
{
return
8
6
return
8
7
|
answerBit
}
func
(
p
*
AnswerLastTransaction
)
neoMsgEncodedLen
()
int
{
...
...
@@ -3396,10 +3413,10 @@ overflow:
return
0
,
ErrDecodeOverflow
}
// 8
7
. NotifyReady
// 8
8
. NotifyReady
func
(
*
NotifyReady
)
neoMsgCode
()
uint16
{
return
8
7
return
8
8
}
func
(
p
*
NotifyReady
)
neoMsgEncodedLen
()
int
{
...
...
@@ -3415,92 +3432,93 @@ func (p *NotifyReady) neoMsgDecode(data []byte) (int, error) {
// registry of message types
var
msgTypeRegistry
=
map
[
uint16
]
reflect
.
Type
{
0
:
reflect
.
TypeOf
(
Error
{}),
0
|
answerBit
:
reflect
.
TypeOf
(
Error
{}),
1
:
reflect
.
TypeOf
(
RequestIdentification
{}),
2
|
answerBit
:
reflect
.
TypeOf
(
AcceptIdentification
{}),
3
:
reflect
.
TypeOf
(
Ping
{}),
4
:
reflect
.
TypeOf
(
CloseClient
{}),
5
:
reflect
.
TypeOf
(
PrimaryMaster
{}),
6
:
reflect
.
TypeOf
(
AnswerPrimary
{}),
7
:
reflect
.
TypeOf
(
NotPrimaryMaster
{}),
8
:
reflect
.
TypeOf
(
Recovery
{}),
9
:
reflect
.
TypeOf
(
AnswerRecovery
{}),
10
:
reflect
.
TypeOf
(
LastIDs
{}),
11
:
reflect
.
TypeOf
(
AnswerLastIDs
{}),
12
:
reflect
.
TypeOf
(
AskPartitionTable
{}),
13
:
reflect
.
TypeOf
(
AnswerPartitionTable
{}),
14
:
reflect
.
TypeOf
(
NotifyPartitionTable
{}),
15
:
reflect
.
TypeOf
(
NotifyPartitionChanges
{}),
16
:
reflect
.
TypeOf
(
StartOperation
{}),
17
:
reflect
.
TypeOf
(
StopOperation
{}),
18
:
reflect
.
TypeOf
(
UnfinishedTransactions
{}),
19
:
reflect
.
TypeOf
(
AnswerUnfinishedTransactions
{}),
20
:
reflect
.
TypeOf
(
LockedTransactions
{}),
21
:
reflect
.
TypeOf
(
AnswerLockedTransactions
{}),
22
:
reflect
.
TypeOf
(
FinalTID
{}),
23
:
reflect
.
TypeOf
(
AnswerFinalTID
{}),
24
:
reflect
.
TypeOf
(
ValidateTransaction
{}),
25
:
reflect
.
TypeOf
(
BeginTransaction
{}),
26
:
reflect
.
TypeOf
(
AnswerBeginTransaction
{}),
27
:
reflect
.
TypeOf
(
FailedVote
{}),
28
:
reflect
.
TypeOf
(
FinishTransaction
{}),
29
:
reflect
.
TypeOf
(
AnswerFinishTransaction
{}),
30
:
reflect
.
TypeOf
(
NotifyTransactionFinished
{}),
31
:
reflect
.
TypeOf
(
LockInformation
{}),
32
:
reflect
.
TypeOf
(
AnswerLockInformation
{}),
33
:
reflect
.
TypeOf
(
InvalidateObjects
{}),
34
:
reflect
.
TypeOf
(
UnlockInformation
{}),
35
:
reflect
.
TypeOf
(
GenerateOIDs
{}),
36
:
reflect
.
TypeOf
(
AnswerGenerateOIDs
{}),
37
:
reflect
.
TypeOf
(
Deadlock
{}),
38
:
reflect
.
TypeOf
(
RebaseTransaction
{}),
39
:
reflect
.
TypeOf
(
AnswerRebaseTransaction
{}),
40
:
reflect
.
TypeOf
(
RebaseObject
{}),
41
:
reflect
.
TypeOf
(
AnswerRebaseObject
{}),
42
:
reflect
.
TypeOf
(
StoreObject
{}),
43
:
reflect
.
TypeOf
(
AnswerStoreObject
{}),
44
:
reflect
.
TypeOf
(
AbortTransaction
{}),
45
:
reflect
.
TypeOf
(
StoreTransaction
{}),
46
:
reflect
.
TypeOf
(
VoteTransaction
{}),
47
:
reflect
.
TypeOf
(
GetObject
{}),
48
:
reflect
.
TypeOf
(
AnswerGetObject
{}),
49
:
reflect
.
TypeOf
(
TIDList
{}),
50
:
reflect
.
TypeOf
(
AnswerTIDList
{}),
51
:
reflect
.
TypeOf
(
TIDListFrom
{}),
52
:
reflect
.
TypeOf
(
AnswerTIDListFrom
{}),
53
:
reflect
.
TypeOf
(
TransactionInformation
{}),
54
:
reflect
.
TypeOf
(
AnswerTransactionInformation
{}),
55
:
reflect
.
TypeOf
(
ObjectHistory
{}),
56
:
reflect
.
TypeOf
(
AnswerObjectHistory
{}),
57
:
reflect
.
TypeOf
(
PartitionList
{}),
58
:
reflect
.
TypeOf
(
AnswerPartitionList
{}),
59
:
reflect
.
TypeOf
(
NodeList
{}),
60
:
reflect
.
TypeOf
(
AnswerNodeList
{}),
61
:
reflect
.
TypeOf
(
SetNodeState
{}),
62
:
reflect
.
TypeOf
(
AddPendingNodes
{}),
63
:
reflect
.
TypeOf
(
TweakPartitionTable
{}),
64
:
reflect
.
TypeOf
(
NotifyNodeInformation
{}),
65
:
reflect
.
TypeOf
(
NodeInformation
{}),
66
:
reflect
.
TypeOf
(
SetClusterState
{}),
67
:
reflect
.
TypeOf
(
repairFlags
{}),
68
:
reflect
.
TypeOf
(
Repair
{}),
69
:
reflect
.
TypeOf
(
RepairOne
{}),
70
:
reflect
.
TypeOf
(
NotifyClusterState
{}),
71
:
reflect
.
TypeOf
(
AskClusterState
{}),
72
:
reflect
.
TypeOf
(
AnswerClusterState
{}),
73
:
reflect
.
TypeOf
(
ObjectUndoSerial
{}),
74
:
reflect
.
TypeOf
(
AnswerObjectUndoSerial
{}),
75
:
reflect
.
TypeOf
(
CheckCurrentSerial
{}),
76
:
reflect
.
TypeOf
(
Pack
{}),
77
:
reflect
.
TypeOf
(
AnswerPack
{}),
78
:
reflect
.
TypeOf
(
CheckReplicas
{}),
79
:
reflect
.
TypeOf
(
CheckPartition
{}),
80
:
reflect
.
TypeOf
(
CheckTIDRange
{}),
81
:
reflect
.
TypeOf
(
AnswerCheckTIDRange
{}),
82
:
reflect
.
TypeOf
(
CheckSerialRange
{}),
83
:
reflect
.
TypeOf
(
AnswerCheckSerialRange
{}),
84
:
reflect
.
TypeOf
(
PartitionCorrupted
{}),
85
:
reflect
.
TypeOf
(
LastTransaction
{}),
86
:
reflect
.
TypeOf
(
AnswerLastTransaction
{}),
87
:
reflect
.
TypeOf
(
NotifyReady
{}),
4
|
answerBit
:
reflect
.
TypeOf
(
Pong
{}),
5
:
reflect
.
TypeOf
(
CloseClient
{}),
6
:
reflect
.
TypeOf
(
PrimaryMaster
{}),
7
|
answerBit
:
reflect
.
TypeOf
(
AnswerPrimary
{}),
8
:
reflect
.
TypeOf
(
NotPrimaryMaster
{}),
9
:
reflect
.
TypeOf
(
NotifyNodeInformation
{}),
10
:
reflect
.
TypeOf
(
Recovery
{}),
11
|
answerBit
:
reflect
.
TypeOf
(
AnswerRecovery
{}),
12
:
reflect
.
TypeOf
(
LastIDs
{}),
13
|
answerBit
:
reflect
.
TypeOf
(
AnswerLastIDs
{}),
14
:
reflect
.
TypeOf
(
AskPartitionTable
{}),
15
|
answerBit
:
reflect
.
TypeOf
(
AnswerPartitionTable
{}),
16
:
reflect
.
TypeOf
(
NotifyPartitionTable
{}),
17
:
reflect
.
TypeOf
(
NotifyPartitionChanges
{}),
18
:
reflect
.
TypeOf
(
StartOperation
{}),
19
:
reflect
.
TypeOf
(
StopOperation
{}),
20
:
reflect
.
TypeOf
(
UnfinishedTransactions
{}),
21
|
answerBit
:
reflect
.
TypeOf
(
AnswerUnfinishedTransactions
{}),
22
:
reflect
.
TypeOf
(
LockedTransactions
{}),
23
|
answerBit
:
reflect
.
TypeOf
(
AnswerLockedTransactions
{}),
24
:
reflect
.
TypeOf
(
FinalTID
{}),
25
|
answerBit
:
reflect
.
TypeOf
(
AnswerFinalTID
{}),
26
:
reflect
.
TypeOf
(
ValidateTransaction
{}),
27
:
reflect
.
TypeOf
(
BeginTransaction
{}),
28
|
answerBit
:
reflect
.
TypeOf
(
AnswerBeginTransaction
{}),
29
:
reflect
.
TypeOf
(
FailedVote
{}),
30
:
reflect
.
TypeOf
(
FinishTransaction
{}),
31
|
answerBit
:
reflect
.
TypeOf
(
AnswerFinishTransaction
{}),
32
:
reflect
.
TypeOf
(
NotifyTransactionFinished
{}),
33
:
reflect
.
TypeOf
(
LockInformation
{}),
34
|
answerBit
:
reflect
.
TypeOf
(
AnswerLockInformation
{}),
35
:
reflect
.
TypeOf
(
InvalidateObjects
{}),
36
:
reflect
.
TypeOf
(
UnlockInformation
{}),
37
:
reflect
.
TypeOf
(
GenerateOIDs
{}),
38
|
answerBit
:
reflect
.
TypeOf
(
AnswerGenerateOIDs
{}),
39
:
reflect
.
TypeOf
(
Deadlock
{}),
40
:
reflect
.
TypeOf
(
RebaseTransaction
{}),
41
|
answerBit
:
reflect
.
TypeOf
(
AnswerRebaseTransaction
{}),
42
:
reflect
.
TypeOf
(
RebaseObject
{}),
43
|
answerBit
:
reflect
.
TypeOf
(
AnswerRebaseObject
{}),
44
:
reflect
.
TypeOf
(
StoreObject
{}),
45
|
answerBit
:
reflect
.
TypeOf
(
AnswerStoreObject
{}),
46
:
reflect
.
TypeOf
(
AbortTransaction
{}),
47
:
reflect
.
TypeOf
(
StoreTransaction
{}),
48
:
reflect
.
TypeOf
(
VoteTransaction
{}),
49
:
reflect
.
TypeOf
(
GetObject
{}),
50
|
answerBit
:
reflect
.
TypeOf
(
AnswerGetObject
{}),
51
:
reflect
.
TypeOf
(
TIDList
{}),
52
|
answerBit
:
reflect
.
TypeOf
(
AnswerTIDList
{}),
53
:
reflect
.
TypeOf
(
TIDListFrom
{}),
54
|
answerBit
:
reflect
.
TypeOf
(
AnswerTIDListFrom
{}),
55
:
reflect
.
TypeOf
(
TransactionInformation
{}),
56
|
answerBit
:
reflect
.
TypeOf
(
AnswerTransactionInformation
{}),
57
:
reflect
.
TypeOf
(
ObjectHistory
{}),
58
|
answerBit
:
reflect
.
TypeOf
(
AnswerObjectHistory
{}),
59
:
reflect
.
TypeOf
(
PartitionList
{}),
60
|
answerBit
:
reflect
.
TypeOf
(
AnswerPartitionList
{}),
61
:
reflect
.
TypeOf
(
NodeList
{}),
62
|
answerBit
:
reflect
.
TypeOf
(
AnswerNodeList
{}),
63
:
reflect
.
TypeOf
(
SetNodeState
{}),
64
:
reflect
.
TypeOf
(
AddPendingNodes
{}),
65
:
reflect
.
TypeOf
(
TweakPartitionTable
{}),
66
:
reflect
.
TypeOf
(
NodeInformation
{}),
67
:
reflect
.
TypeOf
(
SetClusterState
{}),
68
:
reflect
.
TypeOf
(
repairFlags
{}),
69
:
reflect
.
TypeOf
(
Repair
{}),
70
:
reflect
.
TypeOf
(
RepairOne
{}),
71
:
reflect
.
TypeOf
(
NotifyClusterState
{}),
72
:
reflect
.
TypeOf
(
AskClusterState
{}),
73
|
answerBit
:
reflect
.
TypeOf
(
AnswerClusterState
{}),
74
:
reflect
.
TypeOf
(
ObjectUndoSerial
{}),
75
|
answerBit
:
reflect
.
TypeOf
(
AnswerObjectUndoSerial
{}),
76
:
reflect
.
TypeOf
(
CheckCurrentSerial
{}),
77
:
reflect
.
TypeOf
(
Pack
{}),
78
|
answerBit
:
reflect
.
TypeOf
(
AnswerPack
{}),
79
:
reflect
.
TypeOf
(
CheckReplicas
{}),
80
:
reflect
.
TypeOf
(
CheckPartition
{}),
81
:
reflect
.
TypeOf
(
CheckTIDRange
{}),
82
|
answerBit
:
reflect
.
TypeOf
(
AnswerCheckTIDRange
{}),
83
:
reflect
.
TypeOf
(
CheckSerialRange
{}),
84
|
answerBit
:
reflect
.
TypeOf
(
AnswerCheckSerialRange
{}),
85
:
reflect
.
TypeOf
(
PartitionCorrupted
{}),
86
:
reflect
.
TypeOf
(
LastTransaction
{}),
87
|
answerBit
:
reflect
.
TypeOf
(
AnswerLastTransaction
{}),
88
:
reflect
.
TypeOf
(
NotifyReady
{}),
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment