Fixed bug where our history buffer for fork detection was 500x larger than it needed to be leading to performance issues
Made hist buff size configurable
Improved connection state tracking on StateHistorySocket class, we wheren't setting the connected flag correctly on errors & on close() function
Started traking reporter & resumer tasks ids in order to be able to gracefully close
Improved state handling around start() function, now it throws if trying to call start, while start is already connecting
Improved ship abi ready state tracking on socket errors
Created standalone stop() function which fully stops reporter & resumer tasks, closes socket, sets the ship tracking abi flag, clears block history and collector & terminates deseralization workers.
Made restart() ms delay configurable from caller.
Minor changes:
Added check for undefined block data on collectAction & collectDelta functions, which sometimes shows up at process exit (imagine some sort of race when terminating workers while jobs are begin processed)
Changed main.ts to be a benchmark & added it to .gitignore so it stops showing on diffs.
Mayor changes:
StateHistorySocket
class, we wheren't setting theconnected
flag correctly on errors & onclose()
functionstart()
function, now it throws if trying to call start, while start is already connectingstop()
function which fully stops reporter & resumer tasks, closes socket, sets the ship tracking abi flag, clears block history and collector & terminates deseralization workers.restart()
ms delay configurable from caller.Minor changes:
undefined
block data oncollectAction & collectDelta
functions, which sometimes shows up at process exit (imagine some sort of race when terminating workers while jobs are begin processed)main.ts
to be a benchmark & added it to .gitignore so it stops showing on diffs.