Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Regenerate monitoring client #4770

Merged
merged 1 commit into from
Mar 28, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -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.monitoring.v3.AlertPolicy;
import com.google.monitoring.v3.CreateAlertPolicyRequest;
import com.google.monitoring.v3.DeleteAlertPolicyRequest;
Expand All @@ -35,6 +37,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;

Expand Down Expand Up @@ -151,22 +154,68 @@ protected GrpcAlertPolicyServiceStub(
listAlertPoliciesTransportSettings =
GrpcCallSettings.<ListAlertPoliciesRequest, ListAlertPoliciesResponse>newBuilder()
.setMethodDescriptor(listAlertPoliciesMethodDescriptor)
.setParamsExtractor(
new RequestParamsExtractor<ListAlertPoliciesRequest>() {
@Override
public Map<String, String> extract(ListAlertPoliciesRequest request) {
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
params.put("name", String.valueOf(request.getName()));
return params.build();
}
})
.build();
GrpcCallSettings<GetAlertPolicyRequest, AlertPolicy> getAlertPolicyTransportSettings =
GrpcCallSettings.<GetAlertPolicyRequest, AlertPolicy>newBuilder()
.setMethodDescriptor(getAlertPolicyMethodDescriptor)
.setParamsExtractor(
new RequestParamsExtractor<GetAlertPolicyRequest>() {
@Override
public Map<String, String> extract(GetAlertPolicyRequest request) {
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
params.put("name", String.valueOf(request.getName()));
return params.build();
}
})
.build();
GrpcCallSettings<CreateAlertPolicyRequest, AlertPolicy> createAlertPolicyTransportSettings =
GrpcCallSettings.<CreateAlertPolicyRequest, AlertPolicy>newBuilder()
.setMethodDescriptor(createAlertPolicyMethodDescriptor)
.setParamsExtractor(
new RequestParamsExtractor<CreateAlertPolicyRequest>() {
@Override
public Map<String, String> extract(CreateAlertPolicyRequest request) {
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
params.put("name", String.valueOf(request.getName()));
return params.build();
}
})
.build();
GrpcCallSettings<DeleteAlertPolicyRequest, Empty> deleteAlertPolicyTransportSettings =
GrpcCallSettings.<DeleteAlertPolicyRequest, Empty>newBuilder()
.setMethodDescriptor(deleteAlertPolicyMethodDescriptor)
.setParamsExtractor(
new RequestParamsExtractor<DeleteAlertPolicyRequest>() {
@Override
public Map<String, String> extract(DeleteAlertPolicyRequest request) {
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
params.put("name", String.valueOf(request.getName()));
return params.build();
}
})
.build();
GrpcCallSettings<UpdateAlertPolicyRequest, AlertPolicy> updateAlertPolicyTransportSettings =
GrpcCallSettings.<UpdateAlertPolicyRequest, AlertPolicy>newBuilder()
.setMethodDescriptor(updateAlertPolicyMethodDescriptor)
.setParamsExtractor(
new RequestParamsExtractor<UpdateAlertPolicyRequest>() {
@Override
public Map<String, String> extract(UpdateAlertPolicyRequest request) {
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
params.put(
"alert_policy.name", String.valueOf(request.getAlertPolicy().getName()));
return params.build();
}
})
.build();

this.listAlertPoliciesCallable =
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,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.monitoring.v3.CreateGroupRequest;
import com.google.monitoring.v3.DeleteGroupRequest;
import com.google.monitoring.v3.GetGroupRequest;
Expand All @@ -38,6 +40,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;

Expand Down Expand Up @@ -153,27 +156,81 @@ protected GrpcGroupServiceStub(
GrpcCallSettings<ListGroupsRequest, ListGroupsResponse> listGroupsTransportSettings =
GrpcCallSettings.<ListGroupsRequest, ListGroupsResponse>newBuilder()
.setMethodDescriptor(listGroupsMethodDescriptor)
.setParamsExtractor(
new RequestParamsExtractor<ListGroupsRequest>() {
@Override
public Map<String, String> extract(ListGroupsRequest request) {
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
params.put("name", String.valueOf(request.getName()));
return params.build();
}
})
.build();
GrpcCallSettings<GetGroupRequest, Group> getGroupTransportSettings =
GrpcCallSettings.<GetGroupRequest, Group>newBuilder()
.setMethodDescriptor(getGroupMethodDescriptor)
.setParamsExtractor(
new RequestParamsExtractor<GetGroupRequest>() {
@Override
public Map<String, String> extract(GetGroupRequest request) {
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
params.put("name", String.valueOf(request.getName()));
return params.build();
}
})
.build();
GrpcCallSettings<CreateGroupRequest, Group> createGroupTransportSettings =
GrpcCallSettings.<CreateGroupRequest, Group>newBuilder()
.setMethodDescriptor(createGroupMethodDescriptor)
.setParamsExtractor(
new RequestParamsExtractor<CreateGroupRequest>() {
@Override
public Map<String, String> extract(CreateGroupRequest request) {
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
params.put("name", String.valueOf(request.getName()));
return params.build();
}
})
.build();
GrpcCallSettings<UpdateGroupRequest, Group> updateGroupTransportSettings =
GrpcCallSettings.<UpdateGroupRequest, Group>newBuilder()
.setMethodDescriptor(updateGroupMethodDescriptor)
.setParamsExtractor(
new RequestParamsExtractor<UpdateGroupRequest>() {
@Override
public Map<String, String> extract(UpdateGroupRequest request) {
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
params.put("group.name", String.valueOf(request.getGroup().getName()));
return params.build();
}
})
.build();
GrpcCallSettings<DeleteGroupRequest, Empty> deleteGroupTransportSettings =
GrpcCallSettings.<DeleteGroupRequest, Empty>newBuilder()
.setMethodDescriptor(deleteGroupMethodDescriptor)
.setParamsExtractor(
new RequestParamsExtractor<DeleteGroupRequest>() {
@Override
public Map<String, String> extract(DeleteGroupRequest request) {
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
params.put("name", String.valueOf(request.getName()));
return params.build();
}
})
.build();
GrpcCallSettings<ListGroupMembersRequest, ListGroupMembersResponse>
listGroupMembersTransportSettings =
GrpcCallSettings.<ListGroupMembersRequest, ListGroupMembersResponse>newBuilder()
.setMethodDescriptor(listGroupMembersMethodDescriptor)
.setParamsExtractor(
new RequestParamsExtractor<ListGroupMembersRequest>() {
@Override
public Map<String, String> extract(ListGroupMembersRequest request) {
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
params.put("name", String.valueOf(request.getName()));
return params.build();
}
})
.build();

this.listGroupsCallable =
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,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.monitoring.v3.CreateMetricDescriptorRequest;
import com.google.monitoring.v3.CreateTimeSeriesRequest;
import com.google.monitoring.v3.DeleteMetricDescriptorRequest;
Expand All @@ -43,6 +45,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;

Expand Down Expand Up @@ -212,41 +215,115 @@ protected GrpcMetricServiceStub(
.<ListMonitoredResourceDescriptorsRequest, ListMonitoredResourceDescriptorsResponse>
newBuilder()
.setMethodDescriptor(listMonitoredResourceDescriptorsMethodDescriptor)
.setParamsExtractor(
new RequestParamsExtractor<ListMonitoredResourceDescriptorsRequest>() {
@Override
public Map<String, String> extract(
ListMonitoredResourceDescriptorsRequest request) {
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
params.put("name", String.valueOf(request.getName()));
return params.build();
}
})
.build();
GrpcCallSettings<GetMonitoredResourceDescriptorRequest, MonitoredResourceDescriptor>
getMonitoredResourceDescriptorTransportSettings =
GrpcCallSettings
.<GetMonitoredResourceDescriptorRequest, MonitoredResourceDescriptor>newBuilder()
.setMethodDescriptor(getMonitoredResourceDescriptorMethodDescriptor)
.setParamsExtractor(
new RequestParamsExtractor<GetMonitoredResourceDescriptorRequest>() {
@Override
public Map<String, String> extract(
GetMonitoredResourceDescriptorRequest request) {
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
params.put("name", String.valueOf(request.getName()));
return params.build();
}
})
.build();
GrpcCallSettings<ListMetricDescriptorsRequest, ListMetricDescriptorsResponse>
listMetricDescriptorsTransportSettings =
GrpcCallSettings
.<ListMetricDescriptorsRequest, ListMetricDescriptorsResponse>newBuilder()
.setMethodDescriptor(listMetricDescriptorsMethodDescriptor)
.setParamsExtractor(
new RequestParamsExtractor<ListMetricDescriptorsRequest>() {
@Override
public Map<String, String> extract(ListMetricDescriptorsRequest request) {
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
params.put("name", String.valueOf(request.getName()));
return params.build();
}
})
.build();
GrpcCallSettings<GetMetricDescriptorRequest, MetricDescriptor>
getMetricDescriptorTransportSettings =
GrpcCallSettings.<GetMetricDescriptorRequest, MetricDescriptor>newBuilder()
.setMethodDescriptor(getMetricDescriptorMethodDescriptor)
.setParamsExtractor(
new RequestParamsExtractor<GetMetricDescriptorRequest>() {
@Override
public Map<String, String> extract(GetMetricDescriptorRequest request) {
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
params.put("name", String.valueOf(request.getName()));
return params.build();
}
})
.build();
GrpcCallSettings<CreateMetricDescriptorRequest, MetricDescriptor>
createMetricDescriptorTransportSettings =
GrpcCallSettings.<CreateMetricDescriptorRequest, MetricDescriptor>newBuilder()
.setMethodDescriptor(createMetricDescriptorMethodDescriptor)
.setParamsExtractor(
new RequestParamsExtractor<CreateMetricDescriptorRequest>() {
@Override
public Map<String, String> extract(CreateMetricDescriptorRequest request) {
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
params.put("name", String.valueOf(request.getName()));
return params.build();
}
})
.build();
GrpcCallSettings<DeleteMetricDescriptorRequest, Empty> deleteMetricDescriptorTransportSettings =
GrpcCallSettings.<DeleteMetricDescriptorRequest, Empty>newBuilder()
.setMethodDescriptor(deleteMetricDescriptorMethodDescriptor)
.setParamsExtractor(
new RequestParamsExtractor<DeleteMetricDescriptorRequest>() {
@Override
public Map<String, String> extract(DeleteMetricDescriptorRequest request) {
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
params.put("name", String.valueOf(request.getName()));
return params.build();
}
})
.build();
GrpcCallSettings<ListTimeSeriesRequest, ListTimeSeriesResponse>
listTimeSeriesTransportSettings =
GrpcCallSettings.<ListTimeSeriesRequest, ListTimeSeriesResponse>newBuilder()
.setMethodDescriptor(listTimeSeriesMethodDescriptor)
.setParamsExtractor(
new RequestParamsExtractor<ListTimeSeriesRequest>() {
@Override
public Map<String, String> extract(ListTimeSeriesRequest request) {
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
params.put("name", String.valueOf(request.getName()));
return params.build();
}
})
.build();
GrpcCallSettings<CreateTimeSeriesRequest, Empty> createTimeSeriesTransportSettings =
GrpcCallSettings.<CreateTimeSeriesRequest, Empty>newBuilder()
.setMethodDescriptor(createTimeSeriesMethodDescriptor)
.setParamsExtractor(
new RequestParamsExtractor<CreateTimeSeriesRequest>() {
@Override
public Map<String, String> extract(CreateTimeSeriesRequest request) {
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
params.put("name", String.valueOf(request.getName()));
return params.build();
}
})
.build();

this.listMonitoredResourceDescriptorsCallable =
Expand Down
Loading