See go/clientlibs-routine-headers-numeric-enums for more information.
Enums in every implicit/ explicit routing header should be encoded as an Int.
The Routing Headers seem to be encoded here via a ParamsExtractor.
Example:
|
.setParamsExtractor( |
|
request -> { |
|
RequestParamsBuilder builder = RequestParamsBuilder.create(); |
|
builder.add("name", String.valueOf(request.getName())); |
|
return builder.build(); |
|
}) |
This should be modified to get the Int value instead.
Generator changes:
Affect the AbstractTransportServiceStubClassComposer. Specifically around:
|
if (method.routingHeaderRule() == null) { |
|
createRequestParamsExtractorBodyForHttpBindings( |
|
method, requestVarExpr, bodyStatements, returnExpr); |
|
} else { |
|
createRequestParamsExtractorBodyForRoutingHeaders( |
|
method, requestVarExpr, classStatements, bodyStatements, returnExpr); |
|
} |
Both methods should be modified so that the changes are applied for both implicit and explicit routing headers.
See go/clientlibs-routine-headers-numeric-enums for more information.
Enums in every implicit/ explicit routing header should be encoded as an Int.
The Routing Headers seem to be encoded here via a ParamsExtractor.
Example:
sdk-platform-java/showcase/gapic-showcase/src/main/java/com/google/showcase/v1beta1/stub/HttpJsonComplianceStub.java
Lines 850 to 855 in 44701e8
This should be modified to get the Int value instead.
Generator changes:
Affect the
AbstractTransportServiceStubClassComposer. Specifically around:sdk-platform-java/gapic-generator-java/src/main/java/com/google/api/generator/gapic/composer/common/AbstractTransportServiceStubClassComposer.java
Lines 1252 to 1258 in 44701e8
Both methods should be modified so that the changes are applied for both implicit and explicit routing headers.