-
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(cluster) quiet keepalive events #1660
Conversation
-- @treturn table res A table representing the insert row (with fields created during the insertion). | ||
-- @treturn table err If an error occured, a table describing the issue. | ||
function DAO:insert(tbl, options) | ||
check_arg(tbl, 1, "table") | ||
options = options or {} |
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.
Should be:
function DAO:insert(tbl, options)
options = options or {}
check_arg(tbl, 1, "table")
check_arg(options, 2, "table")
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.
Done
@@ -82,7 +82,7 @@ local function send_keepalive(premature) | |||
ngx_log(ngx.ERR, tostring(err)) | |||
elseif #nodes == 1 then | |||
local node = nodes[1] | |||
local _, err = singletons.dao.nodes:update(node, node, {ttl=singletons.configuration.cluster_ttl_on_failure}) | |||
local _, err = singletons.dao.nodes:update(node, node, {ttl=singletons.configuration.cluster_ttl_on_failure, quiet = true}) |
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.
Could we avoid long lines? As per our codestyle, not exceeding 80 chars width is ideal:
local _, err = singletons.dao.nodes:update(node, node, {
ttl = singletons.configuration.cluster_ttl_on_failure,
quiet = true
})
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.
Done
33bb5db
to
6d0317d
Compare
two questions;
|
Not testable, at least none are written regarding events propagation (other than invalidation), and as we know they are extremely unreliable. Testing that an event was not propagated is even trickier.
Eventually. Before the end of the day if so, because |
Has been implemented in |
I was working on the tests |
Full changelog