0

does https://docs.solana.com/validator/geyser also allow a user to parse events?

I'm researching whether it is worth the trouble integrating such a plugin for my app.

Trying to get an understanding of what data it allows me to parse and store in Postgres

1 Answer 1

1

There isn't a formal specification for "events" in Solana at the protocol level, but typically they're structured logs emitted by programs.

In that sense, you can create a handler for notify_transaction which reads through the logs in the provided transaction: https://github.com/solana-labs/solana/blob/056930483531424f2ef584be8aeaa1cee56b0db7/geyser-plugin-interface/src/geyser_plugin_interface.rs#L401

If you receive the logs from every single transaction processed by the network, you can filter out the transactions that contain the log or "event" that you care about.

2
  • got it - thanks! and just for my understanding, for me to use geyser plugins, i'll need to spin up my own validators right? for devnet and mainnet? notify_transaction looks like what i need, just gonna keep reading some tutorials to get up to speed
    – AceGravity
    Commented Feb 1 at 19:35
  • Correct, you'll need some direct connection to a running validator, one for each network that you want to monitor. You could run the validator, or maybe you can convince an operator to compile your geyer plugin into their validator, if you have a good relationship with one of them
    – Jon C
    Commented Feb 2 at 14:26

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.