mirror of https://github.com/grpc/grpc-java.git
xds: Add tlsCertificate and certificateValidationContext attributes to XdsAttributes: needed for passing those values to the SDS component
This commit is contained in:
parent
468d540bc9
commit
e1323e46d1
|
|
@ -16,7 +16,9 @@
|
||||||
|
|
||||||
package io.grpc.xds;
|
package io.grpc.xds;
|
||||||
|
|
||||||
|
import io.envoyproxy.envoy.api.v2.auth.CertificateValidationContext;
|
||||||
import io.envoyproxy.envoy.api.v2.auth.SdsSecretConfig;
|
import io.envoyproxy.envoy.api.v2.auth.SdsSecretConfig;
|
||||||
|
import io.envoyproxy.envoy.api.v2.auth.TlsCertificate;
|
||||||
import io.grpc.Attributes;
|
import io.grpc.Attributes;
|
||||||
import io.grpc.Grpc;
|
import io.grpc.Grpc;
|
||||||
|
|
||||||
|
|
@ -26,11 +28,24 @@ import io.grpc.Grpc;
|
||||||
final class XdsAttributes {
|
final class XdsAttributes {
|
||||||
/**
|
/**
|
||||||
* Attribute key for SdsSecretConfig of a subchannel.
|
* Attribute key for SdsSecretConfig of a subchannel.
|
||||||
*
|
|
||||||
*/
|
*/
|
||||||
@Grpc.TransportAttr
|
@Grpc.TransportAttr
|
||||||
public static final Attributes.Key<SdsSecretConfig> ATTR_SDS_CONFIG =
|
public static final Attributes.Key<SdsSecretConfig> ATTR_SDS_CONFIG =
|
||||||
Attributes.Key.create("io.grpc.xds.XdsAttributes.sdsSecretConfig");
|
Attributes.Key.create("io.grpc.xds.XdsAttributes.sdsSecretConfig");
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Attribute key for TlsCertificate of a subchannel.
|
||||||
|
*/
|
||||||
|
@Grpc.TransportAttr
|
||||||
|
public static final Attributes.Key<TlsCertificate> ATTR_TLS_CERTIFICATE =
|
||||||
|
Attributes.Key.create("io.grpc.xds.XdsAttributes.tlsCertificate");
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Attribute key for CertificateValidationContext of a subchannel.
|
||||||
|
*/
|
||||||
|
@Grpc.TransportAttr
|
||||||
|
public static final Attributes.Key<CertificateValidationContext> ATTR_CERT_VALIDATION_CONTEXT =
|
||||||
|
Attributes.Key.create("io.grpc.xds.XdsAttributes.certificateValidationContext");
|
||||||
|
|
||||||
private XdsAttributes() {}
|
private XdsAttributes() {}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue