OWLS-90857 - Create copy of init container env variables for each sever pod to avoid the roll issue #2458
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
OFSS domain has 1 domain with multiple clusters each having 2 replicas. There are init containers defined in each cluster. When the introspectVersion is changed with no other changes, the second pod gets rolled. This is caused because the init container env variables point to the same underlying data structures (and not deep copies). However, we set different values for some variables such as SERVER_NAME and SERVICE_NAME. This causes the server name env variable of the init container for the second server to have an incorrect value of the first server name. This change creates a copy of the init container env variables list so they don't get overwritten when value changes for other pods. Integration test results at - https://build.weblogick8s.org:8443/job/weblogic-kubernetes-operator-kind-new/5658/