pravega / pravega-operator

Pravega Kubernetes Operator
Apache License 2.0
41 stars 38 forks source link

Add ability to launch Controller's container in privileged mode #544

Closed AndreyKoltsov1997 closed 3 years ago

AndreyKoltsov1997 commented 3 years ago

Description

Behavior of Java applications (for example: Pravega Controller) could be analysed using profilers. They use tracers to measure a particular statistics. In case of running within Docker container environment, tracing isn't enabled by default. Currently, unlike Segment Store Service, Pravega Controller's container couldn't be launched in "privileged mode" which makes it harder to profile the application.

Importance

nice-to-have

Location

pkg/controller/pravega/pravega_controller.go

Suggestions for an improvement

Enabling tracers could be accomplished via (1) manual specification of flags (for example: docker run .. -cap-add=SYS_PTRACE ...) or (2) running container in privileged mode. Approach n. 2 would be sufficient in case of running application within Kubernetes environment. I propose to add the ability to run Controller container in "privileged" mode via testmode.enabled flag.