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

Enclave: avoid log spam during initial L1 catchup #2299

Merged
merged 1 commit into from
Feb 6, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion go/enclave/enclave_admin_service.go
Original file line number Diff line number Diff line change
Expand Up @@ -578,7 +578,9 @@ func (e *enclaveAdminService) getNodeType(ctx context.Context) common.NodeType {
id := e.enclaveKeyService.EnclaveID()
attestedEnclave, err := e.storage.GetEnclavePubKey(ctx, id)
if err != nil {
e.logger.Info("could not read enclave pub key. Defaulting to validator type", log.ErrKey, err)
// this log message doesn't need to be info level, we can assume enclave is in this state until we see a msg like
// "Store attestation. Owner: <EnclaveID>" in the logs (i.e. after initial L1 catchup)
e.logger.Trace("could not read enclave pub key. Defaulting to validator type", log.ErrKey, err)
return common.Validator
}
return attestedEnclave.Type
Expand Down