Open Kamran64 opened 4 years ago
Though this issue hasn't been solved in the java-microprofile stack, relabeling to the java-openliberty stack, which is where we would prioritize a solution if we decide to fix this.
Thanks @scottkurz - I've updated the issue title and description :)
@arthurdm correct me if I'm wrong and you see a need here... but I think this is a moot point now that we've switched to the Open Liberty operator. Closing.
I think we can resolve this issue with doc showing how to add a service monitor to the app-config.yaml. We actually show how to do this already here: https://developer.ibm.com/tutorials/configure-an-observable-microservice-with-appsody-openshift-open-liberty/
My concern with adding this to the default app-deploy.yaml is that it requires SSL to be enabled in the deployment which we are choosing not to do by default. Instead, we are adding doc in our readme on how to enable the HTTPS port and configure user credentials via ENV vars from a Secret. (#750 )
Other than the above doc, we can also add a section to our readme on how to enable a Service Monitor after SSL is enabled.
Following https://github.com/appsody/appsody-operator/pull/125, the Appsody operator supports creating service monitor if there is a
spec.monitoring
entry in theapp-deploy.yaml
file. The only requirement to utilise this is a label field, like so:We introduced this functionality for Python Flask, Node.js-Express, and Node.js-functions but it would be nice to see this for the Open Liberty stack also.
Currently, we also see a Knative error if a stack uses the
readinessProbe
andtimeoutSeconds
is not defined.Describe the solution you'd like Add a new field (
monitoring
) to theapp-deploy
file underneathspec
. The java-microprofile stack has authenticated endpoints and therefore requires abasicAuth
field also.Also add a new field,
timeoutSeconds
under thereadinessProbe
and assign it an appropriate value e.g. 1.Additional context Example PR to implement service monitor support into a stack: https://github.com/appsody/stacks/pull/419/files
Note: The PR above is for a stack without an authenticated endpoint, see: https://github.com/appsody/appsody-operator/pull/125 for a more suitable approach for microprofile.