The config manager service uses the deployKey to lookup which org is attempting to deploy/update the Vizier.
The org ID is then used to make a request to LaunchDarkly for the Vizier feature flags. Feature flags are set on a per-org basis, for example org A may have featureFlag1 set to true.
The config manager updates the Vizier YAMLs with the correct feature flags flipped.
Operator receives the Vizier YAMLs as a response from the config manager service, and applies the YAMLs.
However, this flow only works when the deployKey is valid (so basically, only at deploy time). Most times, a deployKey is generated when deploying a Vizier, and automatically deleted once the Vizier is up-and-running. When the Vizier updates, since the deployKey is no longer valid, the config manager service is unable to fetch the associated orgID. If it is unable to get an orgID, it simply does not add any of the feature flags to the Vizier YAMLs.
Expected behavior
Regardless of whether a user is deploying or updating a Vizier, the feature flags should be set properly based on which org is deploying the Vizier. Since the deploy key is not always valid, we can determine the org associated with a Vizier through its Vizier ID.
Add VizierID to ConfigForVizierRequest protos: src/api/proto/cloudpb/cloudapi.proto, src/cloud/config_manager/configmanagerpb/service.proto
@kpattaswamy FYI this was reverted because it was causing px deploys on fresh clusters to timeout in the v0.1.5 operator (despite it eventually succeeding). See #1899 for more details.
Describe the bug We have a system for setting feature flags on Viziers. The flow is as follows:
deployKey
is included as part of the vzspec.However, this flow only works when the deployKey is valid (so basically, only at deploy time). Most times, a deployKey is generated when deploying a Vizier, and automatically deleted once the Vizier is up-and-running. When the Vizier updates, since the deployKey is no longer valid, the config manager service is unable to fetch the associated orgID. If it is unable to get an orgID, it simply does not add any of the feature flags to the Vizier YAMLs.
Expected behavior Regardless of whether a user is deploying or updating a Vizier, the feature flags should be set properly based on which org is deploying the Vizier. Since the deploy key is not always valid, we can determine the org associated with a Vizier through its Vizier ID.
ConfigForVizierRequest
protos:src/api/proto/cloudpb/cloudapi.proto
,src/cloud/config_manager/configmanagerpb/service.proto
ConfigForVizierRequest
: https://github.com/pixie-io/pixie/blob/ea9a357864dcde4df7d8476b40a18caf58a3e569/src/operator/controllers/vizier_controller.go#L809 Note: Vizier ID will not be available if the user is deploying Vizier for the first time, but it will be available if the Vizier is going through an update. We can use https://github.com/pixie-io/pixie/blob/ea9a357864dcde4df7d8476b40a18caf58a3e569/src/operator/controllers/vizier_controller.go#L1018-L1024 to get the Vizier ID.