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
Bug 1504250 - Keep listening for deprovision messages #508
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The problem is we have return statements in the for loop of the go routine. Simply change those to continue. That is why making them a method worked for you because the return brought you back to the loop. I should've seen this in the deprovision review.
|
OR chain the if statements so they only do one of them at a time and no need for continue or return. See the provision subscriber. Either way is acceptable. |
559e1aa
to
f280885
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Um does not compile:
$ make build
go build -i -ldflags="-s -w" ./cmd/broker
# github.com/openshift/ansible-service-broker/pkg/broker
pkg/broker/deprovision_subscriber.go:60: undefined: log in log.Errorf
make: *** [Makefile:19: broker] Error 2
f280885
to
ae53dcb
Compare
|
Describe what this PR does and why we need it:
We want the subscriber to keep listening for deprovision messages even if a previous deprovision fails.
See https://bugzilla.redhat.com/show_bug.cgi?id=1504250 for recreation steps.
Before this change 'deprovision complete msg' would be sent to the channel but there would not be a corresponding 'processed deprovision message from buffer'.
After this change (from broker logs):