github.com/line/ostracon@v1.0.10-0.20230328032236-7f20145f065d/proto/ostracon/abci/types.proto (about)

     1  syntax = "proto3";
     2  package ostracon.abci;
     3  
     4  option go_package = "github.com/line/ostracon/abci/types";
     5  
     6  // For more information on gogo.proto, see:
     7  // https://github.com/gogo/protobuf/blob/master/extensions.md
     8  import "tendermint/crypto/proof.proto";
     9  import "tendermint/types/params.proto";
    10  import "tendermint/abci/types.proto";
    11  import "tendermint/types/types.proto";
    12  import "ostracon/types/types.proto";
    13  import "tendermint/crypto/keys.proto";
    14  import "google/protobuf/timestamp.proto";
    15  import "gogoproto/gogo.proto";
    16  
    17  // This file is copied from http://github.com/tendermint/abci
    18  // NOTE: When using custom types, mind the warnings.
    19  // https://github.com/gogo/protobuf/blob/master/custom_types.md#warnings-and-issues
    20  
    21  //----------------------------------------
    22  // Request types
    23  
    24  message Request {
    25    oneof value {
    26      tendermint.abci.RequestEcho               echo                 = 1;
    27      tendermint.abci.RequestFlush              flush                = 2;
    28      tendermint.abci.RequestInfo               info                 = 3;
    29      tendermint.abci.RequestSetOption          set_option           = 4;
    30      tendermint.abci.RequestInitChain          init_chain           = 5;
    31      tendermint.abci.RequestQuery              query                = 6;
    32      RequestBeginBlock                         begin_block          = 7;
    33      tendermint.abci.RequestCheckTx            check_tx             = 8;
    34      tendermint.abci.RequestDeliverTx          deliver_tx           = 9;
    35      tendermint.abci.RequestEndBlock           end_block            = 10;
    36      tendermint.abci.RequestCommit             commit               = 11;
    37      tendermint.abci.RequestListSnapshots      list_snapshots       = 12;
    38      tendermint.abci.RequestOfferSnapshot      offer_snapshot       = 13;
    39      tendermint.abci.RequestLoadSnapshotChunk  load_snapshot_chunk  = 14;
    40      tendermint.abci.RequestApplySnapshotChunk apply_snapshot_chunk = 15;
    41      RequestBeginRecheckTx                     begin_recheck_tx     = 1000;  // 16~99 are reserved for merging original tendermint
    42      RequestEndRecheckTx                       end_recheck_tx       = 1001;
    43    }
    44  }
    45  
    46  message RequestBeginBlock {
    47    bytes                          hash                    = 1;
    48    tendermint.types.Header        header                  = 2 [(gogoproto.nullable) = false];
    49    tendermint.abci.LastCommitInfo last_commit_info        = 3 [(gogoproto.nullable) = false];
    50    repeated tendermint.abci.Evidence byzantine_validators = 4 [(gogoproto.nullable) = false];
    51  
    52    // *** Ostracon Extended Fields ***
    53    ostracon.types.Entropy entropy = 1000 [(gogoproto.nullable) = false];
    54  }
    55  
    56  message RequestBeginRecheckTx {
    57    tendermint.types.Header header = 1 [(gogoproto.nullable) = false];
    58  }
    59  
    60  message RequestEndRecheckTx {
    61    int64 height = 1;
    62  }
    63  
    64  //----------------------------------------
    65  // Response types
    66  
    67  message Response {
    68    oneof value {
    69      tendermint.abci.ResponseException          exception            = 1;
    70      tendermint.abci.ResponseEcho               echo                 = 2;
    71      tendermint.abci.ResponseFlush              flush                = 3;
    72      tendermint.abci.ResponseInfo               info                 = 4;
    73      tendermint.abci.ResponseSetOption          set_option           = 5;
    74      tendermint.abci.ResponseInitChain          init_chain           = 6;
    75      tendermint.abci.ResponseQuery              query                = 7;
    76      tendermint.abci.ResponseBeginBlock         begin_block          = 8;
    77      ResponseCheckTx                            check_tx             = 9;
    78      tendermint.abci.ResponseDeliverTx          deliver_tx           = 10;
    79      tendermint.abci.ResponseEndBlock           end_block            = 11;
    80      tendermint.abci.ResponseCommit             commit               = 12;
    81      tendermint.abci.ResponseListSnapshots      list_snapshots       = 13;
    82      tendermint.abci.ResponseOfferSnapshot      offer_snapshot       = 14;
    83      tendermint.abci.ResponseLoadSnapshotChunk  load_snapshot_chunk  = 15;
    84      tendermint.abci.ResponseApplySnapshotChunk apply_snapshot_chunk = 16;
    85      ResponseBeginRecheckTx                     begin_recheck_tx     = 1000;  // 17~99 are reserved for merging original tendermint
    86      ResponseEndRecheckTx                       end_recheck_tx       = 1001;
    87    }
    88  }
    89  
    90  message ResponseCheckTx {
    91    uint32   code                         = 1;
    92    bytes    data                         = 2;
    93    string   log                          = 3;  // nondeterministic
    94    string   info                         = 4;  // nondeterministic
    95    int64    gas_wanted                   = 5 [json_name = "gas_wanted"];
    96    int64    gas_used                     = 6 [json_name = "gas_used"];
    97    repeated tendermint.abci.Event events = 7
    98        [(gogoproto.nullable) = false, (gogoproto.jsontag) = "events,omitempty"];
    99    string codespace = 8;
   100    string sender    = 9;   // MEMO: not used, just reservation to implement https://github.com/tendermint/tendermint/pull/6740 first
   101    int64  priority  = 10;  // MEMO: not used, just reservation to implement https://github.com/tendermint/tendermint/pull/6740 first
   102  
   103    // mempool_error is set by Ostracon.
   104    // ABCI applictions creating a ResponseCheckTX should not set mempool_error.
   105    string mempool_error = 11;
   106  }
   107  
   108  message ResponseBeginRecheckTx {
   109    uint32 code = 1;
   110  }
   111  
   112  message ResponseEndRecheckTx {
   113    uint32 code = 1;
   114  }
   115  
   116  //----------------------------------------
   117  // Service Definition
   118  
   119  service ABCIApplication {
   120    rpc Echo(tendermint.abci.RequestEcho) returns (tendermint.abci.ResponseEcho);
   121    rpc Flush(tendermint.abci.RequestFlush) returns (tendermint.abci.ResponseFlush);
   122    rpc Info(tendermint.abci.RequestInfo) returns (tendermint.abci.ResponseInfo);
   123    rpc SetOption(tendermint.abci.RequestSetOption) returns (tendermint.abci.ResponseSetOption);
   124    rpc DeliverTx(tendermint.abci.RequestDeliverTx) returns (tendermint.abci.ResponseDeliverTx);
   125    rpc CheckTx(tendermint.abci.RequestCheckTx) returns (ResponseCheckTx);
   126    rpc Query(tendermint.abci.RequestQuery) returns (tendermint.abci.ResponseQuery);
   127    rpc Commit(tendermint.abci.RequestCommit) returns (tendermint.abci.ResponseCommit);
   128    rpc InitChain(tendermint.abci.RequestInitChain) returns (tendermint.abci.ResponseInitChain);
   129    rpc BeginBlock(RequestBeginBlock) returns (tendermint.abci.ResponseBeginBlock);
   130    rpc EndBlock(tendermint.abci.RequestEndBlock) returns (tendermint.abci.ResponseEndBlock);
   131    rpc ListSnapshots(tendermint.abci.RequestListSnapshots) returns (tendermint.abci.ResponseListSnapshots);
   132    rpc OfferSnapshot(tendermint.abci.RequestOfferSnapshot) returns (tendermint.abci.ResponseOfferSnapshot);
   133    rpc LoadSnapshotChunk(tendermint.abci.RequestLoadSnapshotChunk) returns (tendermint.abci.ResponseLoadSnapshotChunk);
   134    rpc ApplySnapshotChunk(tendermint.abci.RequestApplySnapshotChunk) returns (tendermint.abci.ResponseApplySnapshotChunk);
   135    rpc BeginRecheckTx(RequestBeginRecheckTx) returns (ResponseBeginRecheckTx);
   136    rpc EndRecheckTx(RequestEndRecheckTx) returns (ResponseEndRecheckTx);
   137  }