Skip to content

Rejected unknown fields do not specify what field is unknown #7937

@howardjohn

Description

@howardjohn

Title: Rejected unknown fields do not specify what field is unknown

Description:
When an unknown field is set using the filesystem subscription, we get a useful error message:

[warning][config] [source/common/config/filesystem_subscription_impl.cc:53] Filesystem config update failure: Protobuf message (type envoy.api.v2.DiscoveryResponse reason INVALID_ARGUMENT:fake_field: Cannot find field.) has unknown fields

When an unknown field is sent over gRPC, we get a less useful message:

[warning][config] [external/envoy/source/common/config/grpc_mux_subscription_impl.cc:81] gRPC config for type.googleapis.com/envoy.api.v2.Listener rejected: Protobuf message (type envoy.api.v2.Listener) has unknown fields

This is frustrating because it is hard to understand what field is unknown.

Repro steps:
See #7936 for repro steps for filebased. Not sure an easy way to give a simple reproduction for the gRPC one, but you'll see it if you send an unknown field over XDS (at least for lds)

Note -- this will have no impact for me/Istio once #7936 is resolved, but may still be useful for others that don't allow unknown fields.

Metadata

Metadata

Assignees

Labels

enhancementFeature requests. Not bugs or questions.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions