Backport of Fix configuration merging for implicit tproxy upstreams. into release/1.14.x #16005
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.
Backport
This PR is auto-generated from #16000 to be assessed for backporting due to the inclusion of the label backport/1.14.
WARNING automatic cherry-pick of commits failed. Commits will require human attention.
The below text is copied from the body of the original PR.
This PR fixes an issue where tproxy would not correctly use service-defaults and proxy-defaults for implicit upstreams. Normally, we handle this by taking configuration from an auto-generated wildcard
*
upstream, but that was not done in all cases -- notably peer upstreams.The changes here are essentially:
It's worth noting that another large issue still needs to be resolved in a different PR (#15956), where the
ServiceDefaults.UpstreamConfig.Overrides[].Peer
field does NOT exist. This manifests in two ways after these changes:agent/configentry/merge_service_config.go
andagent/configentry/resolve.go
are oblivious to the concept of a peer.default/default/mysvc?peer=cluster-02
, but the overrides UID isdefault/default/mysvc
. This is technically correct behavior, but it's noted here, because overrides will NOT work for peer upstreams in tproxy mode until theagent/configentry
package is updated.Overview of commits