automata-network / automata

Automata Network is a modular attestation layer that extends machine trust to Ethereum with TEE Coprocessors.
https://ata.network
Apache License 2.0
94 stars 19 forks source link

Enable Geode State Subscription #61

Open oana-barbu opened 3 years ago

oana-barbu commented 3 years ago

This patch enables the automata node to accept subscriptions for the state of a geode via the "geode_subscribeState" RPC method.

The subscription mechanism is implemented by getting storage updates: the subscribe method creates a stream over which it receives notifications when the storage value of the geode is updated; the storage value is converted to a GeodeState that is sent to the Subscriber.