Hi! New to this site but enjoying it a lot so far.
I'm working on an algo that fetches a new csv every minute. The csv is a list of events that is dynamically updated.
What's the best way to make sure I don't "double react" to an event listed in the csv. In other words the algo will fetch the csv and there might be an event which occurred ~ 60 seconds ago. How can I be sure the algo reacts to the event once - and exactly once?
Strategy 1
In my algo, ignore all events that are more than a minute old. This seems a bit dangerous to me, since the event might have occured 60.0001 seconds ago and been missed by the last tick.
Strategy 2
Configure my server so that once an event has been exported to a csv, it gets marked in the database and never gets exported again. This will be a pain from a dev point of view, as well as a backtesting point of view.
Strategy 3
Hoping there's an alternative here, since none of the other two seem too appetizing.
Cheers,
Aakil!