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

BS,PS: Streamline main #2827

Merged
merged 2 commits into from
Jul 2, 2019

Conversation

lukedirtwalker
Copy link
Collaborator

@lukedirtwalker lukedirtwalker commented Jul 2, 2019

  • Make sure we call msger.CloseServer()
  • PS: Start discorunner separately from other tasks
  • Make kill on a nil periodic.Runner a no-op so that we don't have to have ifs in client code.

This change is Reviewable

* Make sure we call msger.CloseServer()
* PS: Start discorunner separately from other tasks
* Make kill on a nil periodic.Runner a no-op so that we don't have to have ifs in client code.
@lukedirtwalker lukedirtwalker requested a review from oncilla July 2, 2019 07:08
Copy link
Contributor

@oncilla oncilla left a comment

Choose a reason for hiding this comment

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

Reviewed 3 of 3 files at r1.
Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @lukedirtwalker)


go/beacon_srv/main.go, line 501 at r1 (raw file):

	t.mtx.Lock()
	defer t.mtx.Unlock()
	if !t.running {

This will cause a panic because of double close if !t.running is that intended?
Also, what is t.running used for now? We can just drop it.

Copy link
Collaborator Author

@lukedirtwalker lukedirtwalker left a comment

Choose a reason for hiding this comment

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

Reviewable status: 1 of 3 files reviewed, 1 unresolved discussion (waiting on @oncilla)


go/beacon_srv/main.go, line 501 at r1 (raw file):

Previously, Oncilla wrote…

This will cause a panic because of double close if !t.running is that intended?
Also, what is t.running used for now? We can just drop it.

Good catch! I re-added the if and set t.running=true earlier so that we can kill a half started task set.

Copy link
Contributor

@oncilla oncilla left a comment

Choose a reason for hiding this comment

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

Reviewed 2 of 2 files at r2.
Reviewable status: :shipit: complete! all files reviewed, all discussions resolved

Copy link
Contributor

@oncilla oncilla left a comment

Choose a reason for hiding this comment

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

:lgtm:

Reviewable status: :shipit: complete! all files reviewed, all discussions resolved

@lukedirtwalker lukedirtwalker merged commit a8f3e14 into scionproto:master Jul 2, 2019
@lukedirtwalker lukedirtwalker deleted the pubCloseMsger branch July 2, 2019 11:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants