-
Notifications
You must be signed in to change notification settings - Fork 344
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
Wait for elasticsearch cluster to be up #242
Conversation
Signed-off-by: Pavol Loffay <[email protected]>
There is one minor is |
Codecov Report
@@ Coverage Diff @@
## master #242 +/- ##
=========================================
- Coverage 89.69% 89.4% -0.29%
=========================================
Files 62 62
Lines 2717 2738 +21
=========================================
+ Hits 2437 2448 +11
- Misses 181 187 +6
- Partials 99 103 +4
Continue to review full report at Codecov.
|
Signed-off-by: Pavol Loffay <[email protected]>
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.
Reviewed 2 of 3 files at r1, 2 of 2 files at r2.
Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @pavolloffay)
a discussion (no related file):
One side-effect to this PR is that the images for Jaeger components no longer happen in parallel to the bootstrap of Elasticsearch. It's not a big deal, as it makes a difference only for the first time each image is used, but it might be worth opening an issue to investigate if we can pull the images in advance, before we declare them in a deployment.
pkg/controller/jaeger/elasticsearch.go, line 71 at r2 (raw file):
} } return available == expectedSize, nil
Could you add a Debug()
message with the current state? When debugging issues, I found it helpful to know that it's waiting for (N) nodes to become ready. We have something like this in the deployment:
if d.Status.ReadyReplicas != d.Status.Replicas {
log.WithFields(log.Fields{
"namespace": dep.Namespace,
"name": dep.Name,
"ready": d.Status.ReadyReplicas,
"desired": d.Status.Replicas,
}).Debug("Waiting for deployment to estabilize")
return false, nil
}
pkg/storage/elasticsearch.go, line 114 at r2 (raw file):
"app.kubernetes.io/part-of": "jaeger", // we cannot use jaeger-operator because our component controllers removes all objects // created by ES operator
Do you mean that our Operator removes the Elasticsearch stateful sets?
There are no SS but yes. These objects would be queried by our controllers - which should not be bc they are managed by ES operator |
Signed-off-by: Pavol Loffay <[email protected]>
|
||
"github.com/pkg/errors" | ||
"github.com/sirupsen/logrus" |
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.
Across the code base, we are now using log
as alias to this package.
available++ | ||
} | ||
} | ||
logrus.WithFields(logrus.Fields{ |
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.
s/logrus/log
Resolves #216
Signed-off-by: Pavol Loffay [email protected]