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

     1  # Methods and Types
     2  
     3  Please ensure you've first read the spec for [CometBFT Methods and Types](https://github.com/cometbft/cometbft/blob/v0.34.x/spec/abci/abci.md). Here only defines the difference between CometBFT.
     4  
     5  ## Connections
     6  
     7  #### **Mempool** connection
     8  
     9  Ostracon handles the `BeginRecheckTx` and `EndRecheckTx` calls in addition to `CheckTx`.
    10  
    11  ## Messages
    12  
    13  ### BeginBlock
    14  
    15  Ostracon adds a entropy to the [BeginBlock](https://github.com/cometbft/cometbft/blob/v0.34.x/spec/abci/abci.md#BeginBlock) response.
    16  
    17  * **Request**:
    18  
    19      | Name                 | Type                                          | Description                                                                                                       | Field Number |
    20      |----------------------|-----------------------------------------------|-------------------------------------------------------------------------------------------------------------------|--------------|
    21      | hash                 | bytes                                         | The block's hash. This can be derived from the block header.                                                      | 1            |
    22      | header               | [Header](https://github.com/cometbft/cometbft/blob/v0.34.x/spec/core/data_structures.md#header)   | The block header.                                                                                                 | 2            |
    23      | last_commit_info     | [LastCommitInfo](https://github.com/cometbft/cometbft/blob/v0.34.x/spec/abci/abci.md#lastcommitinfo)             | Info about the last commit, including the round, and the list of validators and which ones signed the last block. | 3            |
    24      | byzantine_validators | repeated [Evidence](https://github.com/cometbft/cometbft/blob/v0.34.x/spec/abci/abci.md#evidence)                | List of evidence of validators that acted maliciously.                                                            | 4            |
    25      | entropy              | [Entropy](../core/data_structures.md#entropy) | The block's entropy.                                                                                              | 1000         |
    26  
    27  * **Response**:
    28  
    29      | Name   | Type                      | Description                         | Field Number |
    30      |--------|---------------------------|-------------------------------------|--------------|
    31      | events | repeated [Event](https://github.com/cometbft/cometbft/blob/v0.34.x/spec/abci/abci.md#events) | type & Key-Value events for indexing | 1           |
    32  
    33  * **Usage**:
    34      * Signals the beginning of a new block.
    35      * Called prior to any `DeliverTx` method calls.
    36      * The header contains the height, timestamp, and more - it exactly matches the
    37      CometBFT block header. We may seek to generalize this in the future.
    38      * The `LastCommitInfo` and `ByzantineValidators` can be used to determine
    39      rewards and punishments for the validators.
    40      * The `entropy` can be used to determine the next validators set.
    41  
    42  ### BeginRecheckTx
    43  
    44  * **Request**:
    45  
    46      | Name   | Type                                                                                            | Description                    | Field Number |
    47      |--------|-------------------------------------------------------------------------------------------------|--------------------------------|--------------|
    48      | header | [Header](https://github.com/cometbft/cometbft/blob/v0.34.x/spec/core/data_structures.md#header) | The block header.              | 1            |
    49  
    50  * **Response**:
    51  
    52      | Name       | Type   | Description      | Field Number |
    53      |------------|--------|------------------|--------------|
    54      | code       | uint32 | Response code.   | 1            |
    55  
    56  * **Usage**:
    57      * Signals the beginning of re-checking transactions.
    58  
    59  ### EndRecheckTx
    60  
    61  * **Request**:
    62  
    63      | Name   | Type  | Description                    | Field Number |
    64      |--------|-------|--------------------------------|--------------|
    65      | height | int64 | Height of the executing block. | 1            |
    66  
    67  * **Response**:
    68  
    69      | Name       | Type   | Description    | Field Number |
    70      |------------|--------|----------------|--------------|
    71      | code       | uint32 | Response code. | 1            |
    72  
    73  * **Usage**:
    74      * Signals the end of re-checking transactions.