Commit 9f40d1cf authored by Ubuntu's avatar Ubuntu

update proto

parent 733f4f9d
...@@ -129,6 +129,25 @@ message NonceResponse { ...@@ -129,6 +129,25 @@ message NonceResponse {
bytes nonce = 3; bytes nonce = 3;
} }
message NonceRepeatedRequest {
// request address
repeated bytes address = 1;
// request block number
repeated bytes block_id = 2;
}
message NonceRepeatedResponse {
// the address
repeated bytes address = 1;
// block height
repeated bytes block_id = 2;
// nonce
repeated bytes nonce = 3;
}
message TransactionCountRequest { message TransactionCountRequest {
// request address // request address
bytes address = 1; bytes address = 1;
......
...@@ -4,7 +4,7 @@ package p2p.v1; ...@@ -4,7 +4,7 @@ package p2p.v1;
import "p2p/v1/request_response.proto"; import "p2p/v1/request_response.proto";
service P2PService { service P2PService {
rpc BroadCastMsg(BroadCastRequest) returns (BroadCastResponse) {} rpc BroadcastMsg(BroadCastRequest) returns (BroadCastResponse) {}
rpc SendData(SendDataRequest) returns (SendDataResponse) {} rpc SendMsg(SendDataRequest) returns (SendDataResponse) {}
rpc SubscribeMsg(SubscribeMsgRequest) returns (SubscribeMsgResponse) {} rpc SubscribeMsg(SubscribeMsgRequest) returns (SubscribeMsgResponse) {}
} }
...@@ -20,6 +20,7 @@ message LimitInfoResponse { ...@@ -20,6 +20,7 @@ message LimitInfoResponse {
message CommitBatchTxRequest { message CommitBatchTxRequest {
bytes txdata = 1; bytes txdata = 1;
int64 size =2;
} }
message CommitBatchTxResponse { message CommitBatchTxResponse {
......
...@@ -7,19 +7,20 @@ import "google/protobuf/empty.proto"; ...@@ -7,19 +7,20 @@ import "google/protobuf/empty.proto";
// SentryService methods for other module. // SentryService methods for other module.
service SentryService { service SentryService {
// LimitInfo get latest param for make batch tx. // LimitInfo get latest param for make batch tx.
rpc LimitInfo(LimitInfoRequest) returns(LimitInfoResponse) {} rpc GetLimitInfo(LimitInfoRequest) returns(LimitInfoResponse) {}
// CommitBatchTx used to commit batch tx to tx-sort-network // CommitBatchTx used to commit batch tx to tx-sort-network
rpc CommitBatchTx(CommitBatchTxRequest) returns(CommitBatchTxResponse) {} rpc CommitBatchTx(CommitBatchTxRequest) returns(CommitBatchTxResponse) {}
// GetTxReceipt from tx-sort-network with txhash // GetTxReceipt from tx-sort-network with txhash
rpc GetReceipt(GetReceiptRequest) returns(GetReceiptResponse) {} rpc GetBatchTxResult(GetReceiptRequest) returns(GetReceiptResponse) {}
//for val
// GetNewBlock used for nebula get new virtual block info from contract with lastblock. // GetNewBlock used for nebula get new virtual block info from contract with lastblock.
rpc GetNewBlock(GetNewBlockRequest) returns(GetNewBlockResponse) {} rpc GetNewBlock(GetNewBlockRequest) returns(GetNewBlockResponse) {}
// CommitBlock used for nebula commit new block and state info to contract. // CommitBlock used for nebula commit new block and state info to contract.
rpc CommitBlock(CommitBlockRequest) returns(CommitBlockResponse) {} rpc CommitBlock(CommitBlockRequest) returns(CommitBlockResponse) {}
// GetConsensusedBlock used for nebula get special block consensus result. // GetConsensusedBlock used for nebula get special block consensus result.
rpc GetConsensusedBlock(GetConsensusedBlockRequest) returns(GetConsensusedBlockResponse) {} rpc GetConfirmedBlock(GetConsensusedBlockRequest) returns(GetConsensusedBlockResponse) {}
rpc GetBalance(GetBalanceReq) returns (GetBalanceResp) {}; // rpc GetBalance(GetBalanceReq) returns (GetBalanceResp) {};
rpc GetNonce(GetNonceReq) returns (GetNonceResp) {}; // rpc GetNonce(GetNonceReq) returns (GetNonceResp) {};
rpc GetBlockNumber(google.protobuf.Empty) returns (BlockNumber) {}; // rpc GetBlockNumber(google.protobuf.Empty) returns (BlockNumber) {};
} }
...@@ -9,18 +9,31 @@ import "txchecker/v1/resource.proto"; ...@@ -9,18 +9,31 @@ import "txchecker/v1/resource.proto";
// The standard BatchGet request definition. // The standard BatchGet request definition.
message BatchCheckTxRequest { message BatchCheckTxRequest {
// The ids of the requested shelves. // The ids of the requested shelves.
repeated bytes txs = 1; //with rw and block hash //repeated bytes tx = 1; //with rw and block hash
repeated bytes from = 2; //repeated bytes type= 2;
}
repeated bytes tx = 1;
repeated bytes From =2;
repeated int8 type =3;
}
// type TxWithFrom struct { //ype checkTx struct{
// tx interface
// From []byte // From []byte
// type
//}
// type tx struct{
// checkTx
// RW []byte // RW []byte
// Tx *types.Transaction // wset []byte
// BlockHash []byte ??? // rset []byte
// proof []byte
// stateblocknum int64
// } // }
// The standard BatchGet response definition. // The standard BatchGet response definition.
message BatchCheckTxResponse { message BatchCheckTxResponse {
// The retrieved shelves. // The retrieved shelves.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment