-
Notifications
You must be signed in to change notification settings - Fork 1k
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
Q: Graph-node subscriptions #3647
Comments
Is there any example/doc regarding how we may subscribe through GRAPH-QL-WS? |
I'll close it as there's no activity. |
Same here, may be websocket is not implement. |
Hello, is there any documentation for the above one? Cause i would like to use graphql subscriptions to subscribe to entities changes when events are emitted and handlers modify entities, instead of using graphql polling |
This is now moot as subscriptions are no longer supported |
Q: Is there any way to subscribe (e.g via websocket) for event (eth contract's event) which is handled in subgraph/graph-node?
Let's say we have following event defined in subgraph.yaml under eventhandlers.event:
- event: Transfer(indexed address,indexed address,indexed uint256)
handler: handleTransfer
Such event ( Transfer(indexed address,indexed address,indexed uint256) ) is also defined in contract's ABI (and so it is published by eth network).
Is there any way to subscribe for it directly via graph-node, so that every transfer which results in saving some data/entity in graph-node and which we may query for will be immediately published? Or does this kind of publishing logic has to be included in the event handler? (or as I understood its subgraph which shall define type Subscription in its schema.graphql, so we may then listen for it through graph-node, yes?)
I would like to not have to make any kind of polling and get real-time data from the graph-node when it does save data/entities.
The text was updated successfully, but these errors were encountered: