fix nomad_plugin not waiting for expectedControllers reported by nomad #234
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
I was having an issue using
nomad_external_volume
with the following snippet:with three nomad clients because
nomad_plugin
was immediately returning instead of waiting for the 3 controllers to be healthy. This caused the volume creation to fail with500: plugin has no controller
. After doing some investigation, we noticed thatnomad_plugin
was reportingThis led us to the line-edited below where it appears to be comparing the number of Controllers as reported by nomad vs the number of healthy controllers which will always be the same? Let me know if this assumption is wrong.
I tested this change locally and it is no longer giving a
500: plugin has no controller
error and seems to be waiting appropriately.Please let me know any comments/changes/concerns and I am happy to address them!