Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

READY: Latest TrustChain block via DHT #349

Merged
merged 3 commits into from
Feb 13, 2019
Merged

Commits on Feb 10, 2019

  1. Added a new endpoint for retrieving the latest TrustChain block via t…

    …he DHT mechanism. Added a wildcard listener in the listener_map (of the TrustChainCommunity class) whose associated listeners are called regardless of block type. This wildcard is used to publish newly added to the TrustChainDB blocks to the DHT. The callback for this mechanism also defines behavior which disallows the same block from being published twice to the DHT. It is now possible to retrieve the latest TrustChain block of some peer via a HTTP request. Created a new test set for the newly added block retrieval mechanism. In addition to this, made a few changes to the REST API test suite in terms of the communication modules, such as moving classes from one module to another and creating new modules which host logic for HTTP requests and communication for specific endpoints.
    DanGraur authored and DanGraur committed Feb 10, 2019
    Configuration menu
    Copy the full SHA
    e734e21 View commit details
    Browse the repository at this point in the history
  2. Blocks published to the DHT will now have their chunks signed using t…

    …he node's secret key. In addition to this, this signature will be used on the receiving end for verifying the faithfulness of the chunks and, implicitly, of the block. Chunks will also be published under a new type of payload class, called DHTBlockPayload. The public key will be used (together with a special suffix) for publishing a block to the DHT (it should be mentioned that the raw key will be hashed before publishing).
    DanGraur authored and DanGraur committed Feb 10, 2019
    Configuration menu
    Copy the full SHA
    afe1a28 View commit details
    Browse the repository at this point in the history

Commits on Feb 11, 2019

  1. Embedded the chunk position and the total number of chunks in the DHT…

    …BlockPayload. Removed the dht.storage.get and replaced them with dht.find_values calls, which are handled asynchronously. Finally, made a few changes and additions to the test_dht_endpoint module.
    DanGraur authored and DanGraur committed Feb 11, 2019
    Configuration menu
    Copy the full SHA
    49f31b9 View commit details
    Browse the repository at this point in the history