-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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
fix(declarative) initialize hash for empty config #8425
Conversation
LGTM |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
From the KIC perspective all we're looking for is a data-point which indicates that the gateway has not been initialized with a configuration yet in DBLESS mode (primary reason being to trigger configuration re-push if the gateway container crashes). Having all 0's as an indicator of empty instead of null is workable for us 👍
@@ -187,6 +187,7 @@ local constants = { | |||
DECLARATIVE_PAGE_KEY = "declarative:page", | |||
DECLARATIVE_LOAD_KEY = "declarative_config:loaded", | |||
DECLARATIVE_HASH_KEY = "declarative_config:hash", | |||
DECLARATIVE_EMPTY_CONFIG_HASH = string.rep("0", 32), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice! Good to see this moving to a constant rather than just being a magic string.
be1a379
to
84bcea7
Compare
* fix(declarative) initialize hash for empty config * docs(CHANGELOG) feature description
* fix(declarative) initialize hash for empty config * docs(CHANGELOG) feature description
Summary
This change adds back the
configuration_hash
entry to the/status
endpoint when using dbless mode/node is a dataplane and no configuration has been loaded.See #8214 for reference.
Full changelog
configuration_hash
returns"00000000000000000000000000000000"
when no configuration has been loaded.FT-2358