GithubHelp home page GithubHelp logo

dshackle-archive-avro's Introduction

Dshackle Archive Avro definitions

Avro schema definitions for Dshackle Archive files.

Fields Description

Block

Fields common between different blockchains
  • blockchainType - type of blockchain, as a definitions of what fields to expect. One of ETHEREUM or BITCOIN

  • blockchainId - actual blockchain id (ETH, BTC, etc)

  • archiveTimestamp - when the archive record was created. Milliseconds since epoch

  • height - block height

  • blockId - block hash

  • timestamp - block timestamp. Milliseconds since epoch

  • parentId - parent block hash

  • json - JSON response for that block

Ethereum specific fields
  • unclesCount - number of uncles for the current block

  • uncle0Json - JSON for first uncle (eth_getUncleByBlockHashAndIndex(0))

  • uncle1Json - JSON for second uncle (eth_getUncleByBlockHashAndIndex(1))

Bitcoin specific fields
  • none

Transaction

Fields common between different blockchains
  • blockchainType - type of blockchain, as a definitions of what fields to expect. One of ETHEREUM or BITCOIN

  • blockchainId - actual blockchain id (ETH, BTC, etc)

  • archiveTimestamp - when the archive record was created. Milliseconds since epoch

  • height - block height

  • blockId - block hash

  • timestamp - block timestamp. Milliseconds since epoch

  • index - index of the transaction in block

  • txid - hash or transaction id of the transaction

  • json - JSON response for that transaction

  • raw - raw bytes of the transaction

Ethereum specific fields
  • from - from address

  • to - to address

  • receiptJson - JSON response for eth_getTransactionReceipt

  • traceJson - JSON response for trace_replayTransaction(trace)

  • stateDiffJson - JSON response for trace_replayTransaction(stateDiff)

Bitcoin specific fields
  • none

See src/main/avro for actual Avro definitions.

Java Stubs

To use Java generated stubs use:

repositories {
    maven { url  "https://maven.emrld.io" }
}

dependencies {
    implementation 'io.emeraldpay.dshackle.archive:dshackle-archive-avro:0.1'
}

Generated classes to access Avro messages:

  • io.emeraldpay.dshackle.archive.avro.Block

  • io.emeraldpay.dshackle.archive.avro.Transaction

License

Copyright 2022 EmeraldPay, Inc

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

dshackle-archive-avro's People

Contributors

splix avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.