Commit Graph

16 Commits

Author SHA1 Message Date
Abdul Rabbani
74d80e648a Use sszRoot instead of sszObj for MhKey 2022-05-13 10:20:23 -04:00
Abdul Rabbani
e5fa95d851 Stop tests from running forever on failure. 2022-05-13 10:06:08 -04:00
Abdul Rabbani
39eeae83a6 Utilize the MHkey 2022-05-13 09:51:51 -04:00
Abdul Rabbani
27b3eeb268 Integrate MHKey into existing code base. 2022-05-13 09:04:54 -04:00
Abdul Rabbani
b6e7e503f2 Handle Skipped Slots (#34)
* Ensure that the node is synced at boot time

* Update test + add logic for checking skipped slots

* Update boot check

* Add skip_sync to config.

* Update a test so it fails
2022-05-13 08:55:18 -04:00
Abdul Rabbani
8cab81f12e Add KnownGaps Errors (#33) 2022-05-13 08:55:18 -04:00
Abdul Rabbani
e9f86e82ec Remove Test file 2022-05-13 08:55:18 -04:00
Abdul Rabbani
bea9ce2920 Feature/22 test handling incoming events (#30)
* Checkpoint before the weekend

* Update location for SetupPostgresDB

* Include first functioning tests for processing head

* Fix gitignore

* Test CaptureHead | Add Metrics | Handle Test Race Conditions

This Commit allows us to:

* Test the `CaptureHead` function.
* Test parsing a single Head message.
* Test a Reorg condition.
* Add Metrics. This is primarily used for testing but can have future use cases.
* Rearrange the test due to race conditions introduced by reusing a variable. `BeforeEach` can't be used to update `BC`.

* Update and finalize testing at this stage

* Update code and CI/CD

* Fix lint errors

* Update CICD and fail when file not found.

* Update test to have failed as expected.
2022-05-13 08:55:18 -04:00
Abdul Rabbani
bf38c83a4c Feature/22 test handling incoming events - Intermediary Commit (#28)
* Checkpoint before the weekend

* Update location for SetupPostgresDB
2022-05-13 08:55:18 -04:00
Abdul Rabbani
4994f1fa94 Capture the head block in the DB entirely. (#27)
* -- Intermediary Commit --

Just want to commit my code over the weekend, in case I spill coffee on my workstation.

* Create DB models ready for write.

* Handle SSE events

* Update ref for stack-orchestrator

* Use env in one place only.

* Boot Application on PR

* Update syntax

* Update syntax

* Correct command

* Use bash instead of sh

* Use until instead of while

* Make linter happy and check sse subscription err

* Handle Reorgs - Untested
2022-05-13 08:55:00 -04:00
Abdul Rabbani
ec24895dca Added test to ensure the application shuts down gracefully or within a timeframe. 2022-05-13 08:52:53 -04:00
Abdul Rabbani
f46c4410a2 Clean up + Get State and Block 2022-04-27 14:01:59 -04:00
Abdul Rabbani
d496886f95 Process SSE messages, and include a graceful shutdown 2022-04-27 10:28:42 -04:00
Abdul Rabbani
87313887a4 Graceful Shutdown | Handle SSE | Requires Testing
This Commit contains the following:
* Graceful shutdowns.
* Handling all incoming SSE events for reorgs, finalizations, and head.

The structure of the `BeaconClient` has drastically changed and generics are used.
2022-04-26 13:57:01 -04:00
Abdul Rabbani
5b75f5a257 Create a single beaconclient pkg instead of having subpackages
The main reason to do this is so they can all access the `BeaconClient` Struct.
2022-04-25 11:32:46 -04:00
Abdul Rabbani
594d1e6ee8 Move healthcheck to beaconclient pkg. 2022-04-25 10:41:50 -04:00