Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: On-boarding and recovery of an Orb domain #918

Merged
merged 1 commit into from
Dec 3, 2021

Conversation

bstasyszyn
Copy link
Contributor

Registered a task with the Task Manager that periodically queries the outbox of the services that the domain is following and processes any missing anchor events from "Create" and "Announce" activities. When a new domain is on-boarded, it starts following other domains (ActivityPub services). The synchronization task should then start from the beginning of the outboxes of these domains and process all anchor events (from "Create" and "Announce" activities). Also, if all instances of a domain should go down for a period of time then "Create" and "Announce" activities may be missed. As soon as the domain comes back online the task will start synchronizing from where it last left off in order to process the missing anchor events.

closes #481

Signed-off-by: Bob Stasyszyn Bob.Stasyszyn@securekey.com

@codecov
Copy link

codecov bot commented Dec 3, 2021

Codecov Report

Merging #918 (508dba1) into main (d722a71) will decrease coverage by 0.05%.
The diff coverage is 83.01%.

Impacted file tree graph

@@            Coverage Diff             @@
##             main     #918      +/-   ##
==========================================
- Coverage   89.40%   89.35%   -0.06%     
==========================================
  Files         157      159       +2     
  Lines       14337    14551     +214     
==========================================
+ Hits        12818    13002     +184     
- Misses        930      949      +19     
- Partials      589      600      +11     
Impacted Files Coverage Δ
...vitypub/service/activityhandler/activityhandler.go 100.00% <ø> (ø)
pkg/observer/observer.go 81.77% <33.33%> (ø)
cmd/orb-server/startcmd/start.go 72.84% <57.14%> (-0.33%) ⬇️
pkg/activitypub/client/client.go 86.53% <69.23%> (-0.76%) ⬇️
...ctivitypub/service/activityhandler/inboxhandler.go 85.34% <69.69%> (+0.05%) ⬆️
...tivitypub/service/anchorsynctask/anchorsynctask.go 85.90% <85.90%> (ø)
cmd/orb-server/startcmd/params.go 80.00% <100.00%> (+0.18%) ⬆️
...kg/activitypub/service/anchorsynctask/syncstore.go 100.00% <100.00%> (ø)
pkg/activitypub/service/service.go 93.84% <100.00%> (+0.19%) ⬆️
pkg/anchor/writer/writer.go 91.47% <100.00%> (-0.03%) ⬇️
... and 3 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update d722a71...508dba1. Read the comment docs.

Registered a task with the Task Manager that periodically queries the outbox of the services that the domain is following and processes any missing anchor events from "Create" and "Announce" activities. When a new domain is on-boarded, it starts following other domains (ActivityPub services). The synchronization task should then start from the beginning of the outboxes of these domains and process all anchor events (from "Create" and "Announce" activities). Also, if all instances of a domain should go down for a period of time then "Create" and "Announce" activities may be missed. As soon as the domain comes back online the task will start synchronizing from where it last left off in order to process the missing anchor events.

closes trustbloc#481

Signed-off-by: Bob Stasyszyn <Bob.Stasyszyn@securekey.com>
@fqutishat fqutishat merged commit 4c60e97 into trustbloc:main Dec 3, 2021
@bstasyszyn bstasyszyn deleted the 481-6 branch December 3, 2021 20:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Recovery after domain restart
3 participants