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

etcdmain: SdNotify when gateway, grpc-proxy are ready #7467

Merged
merged 1 commit into from
Mar 9, 2017

Conversation

gyuho
Copy link
Contributor

@gyuho gyuho commented Mar 9, 2017

Just tried this on Container Linux with systemd, confirmed that it works well without sd-notify errors.

Mar 09 17:52:19 gyuho-coreos.c.etcd-development.internal systemd[1]: Starting etcd...
Mar 09 17:52:19 gyuho-coreos.c.etcd-development.internal etcd[25737]: ready to proxy client requests to [127.0.0.1:2379]
Mar 09 17:52:19 gyuho-coreos.c.etcd-development.internal systemd[1]: Started etcd.

Mar 09 17:54:06 gyuho-coreos.c.etcd-development.internal systemd[1]: Starting etcd...
Mar 09 17:54:06 gyuho-coreos.c.etcd-development.internal etcd[25832]: listening for grpc-proxy client requests on 127.0.0.1:23791
Mar 09 17:54:06 gyuho-coreos.c.etcd-development.internal systemd[1]: Started etcd.

Fix #7465

@@ -135,5 +138,15 @@ func startGateway(cmd *cobra.Command, args []string) {
MonitorInterval: getewayRetryDelay,
}

if systemdutil.IsRunningSystemd() {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is duplicated three times, consolidate into:

func notifySystemd() {
    if !systemdutil.IsRunningSystemd() {
       return
    }
    ...
}

in main.go?

Signed-off-by: Gyu-Ho Lee <gyuhox@gmail.com>
@gyuho
Copy link
Contributor Author

gyuho commented Mar 9, 2017

@heyitsanthony PTAL? Thanks!

@heyitsanthony
Copy link
Contributor

lgtm. Thanks!

@gyuho gyuho merged commit 5351953 into etcd-io:master Mar 9, 2017
@gyuho gyuho deleted the sd-notify branch March 9, 2017 19:24
@codecov-io
Copy link

codecov-io commented Mar 9, 2017

Codecov Report

❗ No coverage uploaded for pull request base (master@ad1d48b). Click here to learn what that means.
The diff coverage is 45.45%.

@@           Coverage Diff            @@
##             master   #7467   +/-   ##
========================================
  Coverage          ?   70.8%           
========================================
  Files             ?     244           
  Lines             ?   21437           
  Branches          ?       0           
========================================
  Hits              ?   15178           
  Misses            ?    5132           
  Partials          ?    1127
Impacted Files Coverage Δ
etcdmain/gateway.go 35.08% <0%> (ø)
etcdmain/grpc_proxy.go 19.81% <0%> (ø)
etcdmain/etcd.go 45.33% <100%> (ø)
etcdmain/main.go 50% <50%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update ad1d48b...01dd60c. Read the comment docs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants