diff --git a/google-cloud-clients/google-cloud-trace/src/main/java/com/google/cloud/trace/v1/stub/GrpcTraceServiceStub.java b/google-cloud-clients/google-cloud-trace/src/main/java/com/google/cloud/trace/v1/stub/GrpcTraceServiceStub.java index 3697f843edfb..f788a3948a67 100644 --- a/google-cloud-clients/google-cloud-trace/src/main/java/com/google/cloud/trace/v1/stub/GrpcTraceServiceStub.java +++ b/google-cloud-clients/google-cloud-trace/src/main/java/com/google/cloud/trace/v1/stub/GrpcTraceServiceStub.java @@ -23,7 +23,9 @@ import com.google.api.gax.grpc.GrpcCallSettings; import com.google.api.gax.grpc.GrpcStubCallableFactory; import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.RequestParamsExtractor; import com.google.api.gax.rpc.UnaryCallable; +import com.google.common.collect.ImmutableMap; import com.google.devtools.cloudtrace.v1.GetTraceRequest; import com.google.devtools.cloudtrace.v1.ListTracesRequest; import com.google.devtools.cloudtrace.v1.ListTracesResponse; @@ -33,6 +35,7 @@ import io.grpc.MethodDescriptor; import io.grpc.protobuf.ProtoUtils; import java.io.IOException; +import java.util.Map; import java.util.concurrent.TimeUnit; import javax.annotation.Generated; @@ -118,6 +121,15 @@ protected GrpcTraceServiceStub( GrpcCallSettings patchTracesTransportSettings = GrpcCallSettings.newBuilder() .setMethodDescriptor(patchTracesMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(PatchTracesRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("project_id", String.valueOf(request.getProjectId())); + return params.build(); + } + }) .build(); GrpcCallSettings getTraceTransportSettings = GrpcCallSettings.newBuilder() @@ -126,6 +138,15 @@ protected GrpcTraceServiceStub( GrpcCallSettings listTracesTransportSettings = GrpcCallSettings.newBuilder() .setMethodDescriptor(listTracesMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(ListTracesRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("project_id", String.valueOf(request.getProjectId())); + return params.build(); + } + }) .build(); this.patchTracesCallable = diff --git a/google-cloud-clients/google-cloud-trace/src/main/java/com/google/cloud/trace/v2/stub/GrpcTraceServiceStub.java b/google-cloud-clients/google-cloud-trace/src/main/java/com/google/cloud/trace/v2/stub/GrpcTraceServiceStub.java index efc2187e243e..e7f5b5cd60fd 100644 --- a/google-cloud-clients/google-cloud-trace/src/main/java/com/google/cloud/trace/v2/stub/GrpcTraceServiceStub.java +++ b/google-cloud-clients/google-cloud-trace/src/main/java/com/google/cloud/trace/v2/stub/GrpcTraceServiceStub.java @@ -21,13 +21,16 @@ import com.google.api.gax.grpc.GrpcCallSettings; import com.google.api.gax.grpc.GrpcStubCallableFactory; import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.RequestParamsExtractor; import com.google.api.gax.rpc.UnaryCallable; +import com.google.common.collect.ImmutableMap; import com.google.devtools.cloudtrace.v2.BatchWriteSpansRequest; import com.google.devtools.cloudtrace.v2.Span; import com.google.protobuf.Empty; import io.grpc.MethodDescriptor; import io.grpc.protobuf.ProtoUtils; import java.io.IOException; +import java.util.Map; import java.util.concurrent.TimeUnit; import javax.annotation.Generated; @@ -105,10 +108,28 @@ protected GrpcTraceServiceStub( GrpcCallSettings batchWriteSpansTransportSettings = GrpcCallSettings.newBuilder() .setMethodDescriptor(batchWriteSpansMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(BatchWriteSpansRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("name", String.valueOf(request.getName())); + return params.build(); + } + }) .build(); GrpcCallSettings createSpanTransportSettings = GrpcCallSettings.newBuilder() .setMethodDescriptor(createSpanMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(Span request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("name", String.valueOf(request.getName())); + return params.build(); + } + }) .build(); this.batchWriteSpansCallable = diff --git a/google-cloud-clients/google-cloud-trace/synth.metadata b/google-cloud-clients/google-cloud-trace/synth.metadata index eadc17f8146d..2a460ece0251 100644 --- a/google-cloud-clients/google-cloud-trace/synth.metadata +++ b/google-cloud-clients/google-cloud-trace/synth.metadata @@ -1,19 +1,19 @@ { - "updateTime": "2019-03-06T08:55:06.586413Z", + "updateTime": "2019-03-28T07:59:19.919927Z", "sources": [ { "generator": { "name": "artman", - "version": "0.16.15", - "dockerImage": "googleapis/artman@sha256:9caadfa59d48224cba5f3217eb9d61a155b78ccf31e628abef385bc5b7ed3bd2" + "version": "0.16.20", + "dockerImage": "googleapis/artman@sha256:e3c054a2fb85a12481c722af616c7fb6f1d02d862248385eecbec3e4240ebd1e" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "856117505ff9075b3e9c0b5674113667b6cf9e00", - "internalRef": "236931378" + "sha": "6a84b3267b0a95e922608b9891219075047eee29", + "internalRef": "240640999" } } ],