taquito icon indicating copy to clipboard operation
taquito copied to clipboard

Provide a subscriber to events

Open roxaneletourneau opened this issue 2 years ago • 1 comments

Two solutions to be discussed with the team: 1- We add a method subcribeEvent in the PollingSubscribeProvider class. The method takes optional filters allowing the subscription to a particular kind of event (filter for a particular contract address that emitted the event, for example) ~2 - We create a separate new class that will use long polling rather than polling. Long-running subscriber to events was discussed during the protocol K overview on July 8th.~

Additional context https://tezos.gitlab.io/alpha/event.html#computing-an-event-address https://www.marigold.dev/post/how-to-send-events-from-contract-fast

roxaneletourneau avatar Jul 08 '22 21:07 roxaneletourneau

Hey team! Please add your planning poker estimate with Zenhub @dsawali @hui-an-yang @zainen

roxaneletourneau avatar Aug 30 '22 16:08 roxaneletourneau

Hi 👋🏻 I wonder why polling when we have monitor/heads/${chain}?

cryi avatar Oct 09 '22 08:10 cryi

Hi @cryi, all the mechanisms for polling are already in place and used in Taquito, so reusing it allows implementing the subscriber to events quickly. Coming next, we have a plan to use the monitor/heads/${chain} as described here: https://github.com/ecadlabs/taquito/issues/1030

roxaneletourneau avatar Oct 11 '22 15:10 roxaneletourneau