-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Panic while handling /health?bundle=true
#1703
Labels
Comments
patrick-east
added a commit
to patrick-east/opa
that referenced
this issue
Aug 29, 2019
The issue was that with bundles loaded from the file system we would not initialize the mutex used for checking bundle status. This fixes the initialization and prevents the error. Health status works as expected now. Fixes: open-policy-agent#1703 Signed-off-by: Patrick East <east.patrick@gmail.com>
patrick-east
added a commit
to patrick-east/opa
that referenced
this issue
Aug 29, 2019
The issue was that with bundles loaded from the file system we would not initialize the mutex used for checking bundle status. This fixes the initialization and prevents the error. Health status works as expected now. Fixes: open-policy-agent#1703 Signed-off-by: Patrick East <east.patrick@gmail.com> (cherry picked from commit 3248c2d)
patrick-east
added a commit
that referenced
this issue
Aug 30, 2019
The issue was that with bundles loaded from the file system we would not initialize the mutex used for checking bundle status. This fixes the initialization and prevents the error. Health status works as expected now. Fixes: #1703 Signed-off-by: Patrick East <east.patrick@gmail.com>
patrick-east
added a commit
that referenced
this issue
Aug 30, 2019
The issue was that with bundles loaded from the file system we would not initialize the mutex used for checking bundle status. This fixes the initialization and prevents the error. Health status works as expected now. Fixes: #1703 Signed-off-by: Patrick East <east.patrick@gmail.com> (cherry picked from commit 3248c2d)
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Expected Behavior
No panic
Actual Behavior
Calling the health API can cause a panic:
Steps to Reproduce the Problem
Start opa server with a bundle as a data file, ex:
Curl the health check
Additional Info
This can probably be fixed simply by switching the mutex to not be a pointer on the server.
Turns out the problem is that the logic for initializing the mutex was assuming a bundle plugin was active. Loading the bundle in from the CLI hides that.
The text was updated successfully, but these errors were encountered: