You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Aug 26, 2022. It is now read-only.
But i don not know how to add upstream backup servers, and how slardar use backup server when all primary server dowm with the round-robin method?
And i did't find any code to process backup servers.
Can you tell me how? I am wait online! THX!
`local servers = get_servers(consul_cluster, key .. "?raw")
if not servers or not next(servers) then
return false
end
if not check_servers(servers["servers"]) then
return false
end
local cls = {
servers = servers["servers"],
keepalive = tonumber(servers["keepalive"]),
try = tonumber(servers["try"]),
}
config[skey] = {
cluster = { cls },
}`
The text was updated successfully, but these errors were encountered:
xiaoxuanzi
changed the title
How to add upstream backup server in consul, Does it support it?
How to add upstream backup server in consul, Does it support?
Feb 9, 2017
I'm glad to have received your respone,
thanks a lot.
I want to use Slardar in my project . I have already change some of code in to Slardar adjust my to adapt to the scene in my project. and make Slardar more general.
i am very happy to submit patches in the next months and anticipate your reply.
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
I know how to add upstream server in consul in README:
key: upstreams/node-dev.example
servers: {"enable": true, "servers": [{"host": "127.0.0.1","port": 8001,"weight": 1,"max_fails": 6,"fail_timeout": 30}]}
But i don not know how to add upstream backup servers, and how slardar use backup server when all primary server dowm with the round-robin method?
And i did't find any code to process backup servers.
Can you tell me how? I am wait online! THX!
`local servers = get_servers(consul_cluster, key .. "?raw")
if not servers or not next(servers) then
return false
end
The text was updated successfully, but these errors were encountered: