ververica / ververica-platform-playground

Instructions for getting started with Ververica Platform on minikube.
https://docs.ververica.com/getting_started/index.html
Apache License 2.0
89 stars 39 forks source link

[DECO-279] Add Prometheus Operator stack #50

Closed austince closed 3 years ago

austince commented 3 years ago

Adds Prometheus Operator support via a ServiceMonitor for all Flink jobs. I've tested both the stacks to ensure the current method still works as well.

Also:

austince commented 3 years ago

@knaufk @qinjunjerry optional for review, will solicit one from the deco team as well.

austince commented 3 years ago

I am wondering if we we need the complexity of both Prometheus deployment modes here? Could we only offer the Operator-based approach in the playground going forward?

I think that would work, though the Prometheus users are still split on installation approaches – not everyone uses the Prometheus Operator. I guess one solution might be to add the annotations to make it work with a "standalone" Prometheus setup, so that it will still work for those users, and just use the Prometheus Operator stack here.

Update: another consequence of using just the Prometheus Operator is that it uses the v1 CRD API, which restricts the k8s version to 1.16+.

austince commented 3 years ago

From feedback from @qinjunjerry, will use the Service + ServiceMonitor approach which will work with any VVP 2.x series. Requires more k8s configuration, but less VVP configuration.

qinjunjerry commented 3 years ago

That is unrelated to this change, but anyway: I started ./setup.sh --with-metrics --with-logging after running ./setup.sh --edition community

  • I ran into the ERROR: No Ververica Platform license provided. in both cases. I assume that for the first one the user shouldn't have to deal with it considering that --edition community was specified?

./setup.sh --with-metrics --with-logging --edition enterprise needs a valid license. --edition community needs you to accept the community license.

XComp commented 3 years ago

I see, confirming the community license makes sense. But the error printout is kind of not expected, I guess:

Error: template: ververica-platform/templates/pvc.yaml:1:11: executing "ververica-platform/templates/pvc.yaml" at <include "vvp.should.create.pvc" .>: error calling include: template: ververica-platform/templates/_helpers.tpl:75:15: executing "vvp.should.create.pvc" at <include "vvp.pvc.enabled" .>: error calling include: template: ververica-platform/templates/_
helpers.tpl:67:12: executing "vvp.pvc.enabled" at <include "vvp.private.process.application.config" .>: error calling include: template: ververica-platform/templates/_helpers.tpl:137:8: executing "vvp.private.process.application.config" at <include "vvp.private.inject.license.config" .>: error calling include: template: ververica-platform/templates/_helpers.tpl:
212:106: executing "vvp.private.inject.license.config" at <fail>: error calling fail:

================================================================================
ERROR: No Ververica Platform license provided.

Actions to resolve:

* Provide a valid license at `vvp.license.data`.

- OR -

* Read the printed Ververica Platform Community Edition license agreement and
indicate that you accept it by setting `acceptCommunityEditionLicense=true`.

That was part of the output when calling ./setup.sh --edition community

qinjunjerry commented 3 years ago

Yes, the error is printed there. I never noticed it and simply type `y' to the question following the long LICENSE AGREEMENT

...
This Agreement constitutes the parties’ entire understanding regarding the Software, and supersedes any and all other prior or contemporaneous agreements, whether written or oral.

================================================================================
ERROR: No Ververica Platform license provided.

Actions to resolve:

* Provide a valid license at `vvp.license.data`.

- OR -

* Read the printed Ververica Platform Community Edition license agreement and
indicate that you accept it by setting `acceptCommunityEditionLicense=true`.
================================================================================
Do you want to pass 'acceptCommunityEditionLicense=true'? (y/N) y
austince commented 3 years ago

~I do not have push access to this branch anymore, so will update tomorrow.~

Now I do -- updated!