Skip to content

Commit

Permalink
feat: l1infotreesync can be run as individual component (#188)
Browse files Browse the repository at this point in the history
  • Loading branch information
joanestebanr authored Nov 15, 2024
1 parent 8a1307b commit 06f8aa6
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
6 changes: 4 additions & 2 deletions cmd/run.go
Original file line number Diff line number Diff line change
Expand Up @@ -529,7 +529,7 @@ func runL1InfoTreeSyncerIfNeeded(
reorgDetector *reorgdetector.ReorgDetector,
) *l1infotreesync.L1InfoTreeSync {
if !isNeeded([]string{cdkcommon.AGGORACLE, cdkcommon.RPC,
cdkcommon.SEQUENCE_SENDER, cdkcommon.AGGSENDER}, components) {
cdkcommon.SEQUENCE_SENDER, cdkcommon.AGGSENDER, cdkcommon.L1INFOTREESYNC}, components) {
return nil
}
l1InfoTreeSync, err := l1infotreesync.New(
Expand Down Expand Up @@ -560,6 +560,7 @@ func runL1ClientIfNeeded(components []string, urlRPCL1 string) *ethclient.Client
cdkcommon.SEQUENCE_SENDER, cdkcommon.AGGREGATOR,
cdkcommon.AGGORACLE, cdkcommon.RPC,
cdkcommon.AGGSENDER,
cdkcommon.L1INFOTREESYNC,
}, components) {
return nil
}
Expand Down Expand Up @@ -594,7 +595,8 @@ func runReorgDetectorL1IfNeeded(
) (*reorgdetector.ReorgDetector, chan error) {
if !isNeeded([]string{
cdkcommon.SEQUENCE_SENDER, cdkcommon.AGGREGATOR,
cdkcommon.AGGORACLE, cdkcommon.RPC, cdkcommon.AGGSENDER},
cdkcommon.AGGORACLE, cdkcommon.RPC, cdkcommon.AGGSENDER,
cdkcommon.L1INFOTREESYNC},
components) {
return nil, nil
}
Expand Down
2 changes: 2 additions & 0 deletions common/components.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,6 @@ const (
PROVER = "prover"
// AGGSENDER name to identify the aggsender component
AGGSENDER = "aggsender"
// L1INFOTREESYNC name to identify the l1infotreesync component
L1INFOTREESYNC = "l1infotreesync"
)

0 comments on commit 06f8aa6

Please sign in to comment.