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

start and stop modules in correct order #285

Merged
merged 3 commits into from
Feb 5, 2019
Merged

start and stop modules in correct order #285

merged 3 commits into from
Feb 5, 2019

Conversation

woodsaj
Copy link
Member

@woodsaj woodsaj commented Feb 4, 2019

When starting up, start all dependencies first then start the target
module. When stopping, reverse the order to ensure we dont try and
stop a module while there is still something running that needs it.

fixes #105

When starting up, start all dependencies first then start the target
module.  When stopping, reverse the order to ensure we dont try and
stop a module while there is still something running that needs it.

fixes #105
pkg/loki/loki.go Outdated Show resolved Hide resolved
pkg/loki/modules.go Outdated Show resolved Hide resolved
pkg/loki/modules.go Outdated Show resolved Hide resolved
pkg/loki/modules.go Outdated Show resolved Hide resolved
pkg/loki/modules.go Outdated Show resolved Hide resolved
pkg/loki/modules.go Outdated Show resolved Hide resolved
pkg/loki/modules.go Outdated Show resolved Hide resolved
@woodsaj woodsaj force-pushed the issue105 branch 2 times, most recently from 3c82807 to ab13a69 Compare February 5, 2019 14:46
pkg/loki/loki.go Outdated
}
delete(t.inited, m)
Copy link
Contributor

Choose a reason for hiding this comment

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

Is this needed still?

Copy link
Member Author

Choose a reason for hiding this comment

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

I guess the inited field can be removed completely from the Loki struct

uniq[dep] = false
}

result := make([]moduleName, 0)
Copy link
Contributor

Choose a reason for hiding this comment

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

Lets do []moduleName{} or make([]moduleName, 0, len(uniq). Anything but this!

@tomwilkie
Copy link
Contributor

LGTM with 2 nits.

@tomwilkie tomwilkie merged commit 4582c43 into master Feb 5, 2019
@tomwilkie tomwilkie deleted the issue105 branch February 5, 2019 17:13
btaani pushed a commit to btaani/loki that referenced this pull request Apr 22, 2024
[release-5.7] Improve validation of provided S3 storage configuration
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.

Ingester crashes on exit
2 participants