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 scheduler client #4774

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,6 +23,7 @@
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.cloud.scheduler.v1.CreateJobRequest;
import com.google.cloud.scheduler.v1.DeleteJobRequest;
Expand All @@ -34,10 +35,12 @@
import com.google.cloud.scheduler.v1.ResumeJobRequest;
import com.google.cloud.scheduler.v1.RunJobRequest;
import com.google.cloud.scheduler.v1.UpdateJobRequest;
import com.google.common.collect.ImmutableMap;
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;

Expand Down Expand Up @@ -165,34 +168,106 @@ protected GrpcCloudSchedulerStub(
GrpcCallSettings<ListJobsRequest, ListJobsResponse> listJobsTransportSettings =
GrpcCallSettings.<ListJobsRequest, ListJobsResponse>newBuilder()
.setMethodDescriptor(listJobsMethodDescriptor)
.setParamsExtractor(
new RequestParamsExtractor<ListJobsRequest>() {
@Override
public Map<String, String> extract(ListJobsRequest request) {
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
params.put("parent", String.valueOf(request.getParent()));
return params.build();
}
})
.build();
GrpcCallSettings<GetJobRequest, Job> getJobTransportSettings =
GrpcCallSettings.<GetJobRequest, Job>newBuilder()
.setMethodDescriptor(getJobMethodDescriptor)
.setParamsExtractor(
new RequestParamsExtractor<GetJobRequest>() {
@Override
public Map<String, String> extract(GetJobRequest request) {
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
params.put("name", String.valueOf(request.getName()));
return params.build();
}
})
.build();
GrpcCallSettings<CreateJobRequest, Job> createJobTransportSettings =
GrpcCallSettings.<CreateJobRequest, Job>newBuilder()
.setMethodDescriptor(createJobMethodDescriptor)
.setParamsExtractor(
new RequestParamsExtractor<CreateJobRequest>() {
@Override
public Map<String, String> extract(CreateJobRequest request) {
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
params.put("parent", String.valueOf(request.getParent()));
return params.build();
}
})
.build();
GrpcCallSettings<UpdateJobRequest, Job> updateJobTransportSettings =
GrpcCallSettings.<UpdateJobRequest, Job>newBuilder()
.setMethodDescriptor(updateJobMethodDescriptor)
.setParamsExtractor(
new RequestParamsExtractor<UpdateJobRequest>() {
@Override
public Map<String, String> extract(UpdateJobRequest request) {
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
params.put("job.name", String.valueOf(request.getJob().getName()));
return params.build();
}
})
.build();
GrpcCallSettings<DeleteJobRequest, Empty> deleteJobTransportSettings =
GrpcCallSettings.<DeleteJobRequest, Empty>newBuilder()
.setMethodDescriptor(deleteJobMethodDescriptor)
.setParamsExtractor(
new RequestParamsExtractor<DeleteJobRequest>() {
@Override
public Map<String, String> extract(DeleteJobRequest request) {
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
params.put("name", String.valueOf(request.getName()));
return params.build();
}
})
.build();
GrpcCallSettings<PauseJobRequest, Job> pauseJobTransportSettings =
GrpcCallSettings.<PauseJobRequest, Job>newBuilder()
.setMethodDescriptor(pauseJobMethodDescriptor)
.setParamsExtractor(
new RequestParamsExtractor<PauseJobRequest>() {
@Override
public Map<String, String> extract(PauseJobRequest request) {
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
params.put("name", String.valueOf(request.getName()));
return params.build();
}
})
.build();
GrpcCallSettings<ResumeJobRequest, Job> resumeJobTransportSettings =
GrpcCallSettings.<ResumeJobRequest, Job>newBuilder()
.setMethodDescriptor(resumeJobMethodDescriptor)
.setParamsExtractor(
new RequestParamsExtractor<ResumeJobRequest>() {
@Override
public Map<String, String> extract(ResumeJobRequest request) {
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
params.put("name", String.valueOf(request.getName()));
return params.build();
}
})
.build();
GrpcCallSettings<RunJobRequest, Job> runJobTransportSettings =
GrpcCallSettings.<RunJobRequest, Job>newBuilder()
.setMethodDescriptor(runJobMethodDescriptor)
.setParamsExtractor(
new RequestParamsExtractor<RunJobRequest>() {
@Override
public Map<String, String> extract(RunJobRequest request) {
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
params.put("name", String.valueOf(request.getName()));
return params.build();
}
})
.build();

this.listJobsCallable =
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
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.cloud.scheduler.v1beta1.CreateJobRequest;
import com.google.cloud.scheduler.v1beta1.DeleteJobRequest;
Expand All @@ -34,10 +35,12 @@
import com.google.cloud.scheduler.v1beta1.ResumeJobRequest;
import com.google.cloud.scheduler.v1beta1.RunJobRequest;
import com.google.cloud.scheduler.v1beta1.UpdateJobRequest;
import com.google.common.collect.ImmutableMap;
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;

Expand Down Expand Up @@ -165,34 +168,106 @@ protected GrpcCloudSchedulerStub(
GrpcCallSettings<ListJobsRequest, ListJobsResponse> listJobsTransportSettings =
GrpcCallSettings.<ListJobsRequest, ListJobsResponse>newBuilder()
.setMethodDescriptor(listJobsMethodDescriptor)
.setParamsExtractor(
new RequestParamsExtractor<ListJobsRequest>() {
@Override
public Map<String, String> extract(ListJobsRequest request) {
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
params.put("parent", String.valueOf(request.getParent()));
return params.build();
}
})
.build();
GrpcCallSettings<GetJobRequest, Job> getJobTransportSettings =
GrpcCallSettings.<GetJobRequest, Job>newBuilder()
.setMethodDescriptor(getJobMethodDescriptor)
.setParamsExtractor(
new RequestParamsExtractor<GetJobRequest>() {
@Override
public Map<String, String> extract(GetJobRequest request) {
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
params.put("name", String.valueOf(request.getName()));
return params.build();
}
})
.build();
GrpcCallSettings<CreateJobRequest, Job> createJobTransportSettings =
GrpcCallSettings.<CreateJobRequest, Job>newBuilder()
.setMethodDescriptor(createJobMethodDescriptor)
.setParamsExtractor(
new RequestParamsExtractor<CreateJobRequest>() {
@Override
public Map<String, String> extract(CreateJobRequest request) {
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
params.put("parent", String.valueOf(request.getParent()));
return params.build();
}
})
.build();
GrpcCallSettings<UpdateJobRequest, Job> updateJobTransportSettings =
GrpcCallSettings.<UpdateJobRequest, Job>newBuilder()
.setMethodDescriptor(updateJobMethodDescriptor)
.setParamsExtractor(
new RequestParamsExtractor<UpdateJobRequest>() {
@Override
public Map<String, String> extract(UpdateJobRequest request) {
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
params.put("job.name", String.valueOf(request.getJob().getName()));
return params.build();
}
})
.build();
GrpcCallSettings<DeleteJobRequest, Empty> deleteJobTransportSettings =
GrpcCallSettings.<DeleteJobRequest, Empty>newBuilder()
.setMethodDescriptor(deleteJobMethodDescriptor)
.setParamsExtractor(
new RequestParamsExtractor<DeleteJobRequest>() {
@Override
public Map<String, String> extract(DeleteJobRequest request) {
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
params.put("name", String.valueOf(request.getName()));
return params.build();
}
})
.build();
GrpcCallSettings<PauseJobRequest, Job> pauseJobTransportSettings =
GrpcCallSettings.<PauseJobRequest, Job>newBuilder()
.setMethodDescriptor(pauseJobMethodDescriptor)
.setParamsExtractor(
new RequestParamsExtractor<PauseJobRequest>() {
@Override
public Map<String, String> extract(PauseJobRequest request) {
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
params.put("name", String.valueOf(request.getName()));
return params.build();
}
})
.build();
GrpcCallSettings<ResumeJobRequest, Job> resumeJobTransportSettings =
GrpcCallSettings.<ResumeJobRequest, Job>newBuilder()
.setMethodDescriptor(resumeJobMethodDescriptor)
.setParamsExtractor(
new RequestParamsExtractor<ResumeJobRequest>() {
@Override
public Map<String, String> extract(ResumeJobRequest request) {
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
params.put("name", String.valueOf(request.getName()));
return params.build();
}
})
.build();
GrpcCallSettings<RunJobRequest, Job> runJobTransportSettings =
GrpcCallSettings.<RunJobRequest, Job>newBuilder()
.setMethodDescriptor(runJobMethodDescriptor)
.setParamsExtractor(
new RequestParamsExtractor<RunJobRequest>() {
@Override
public Map<String, String> extract(RunJobRequest request) {
ImmutableMap.Builder<String, String> params = ImmutableMap.builder();
params.put("name", String.valueOf(request.getName()));
return params.build();
}
})
.build();

this.listJobsCallable =
Expand Down
10 changes: 5 additions & 5 deletions google-cloud-clients/google-cloud-scheduler/synth.metadata
Original file line number Diff line number Diff line change
@@ -1,19 +1,19 @@
{
"updateTime": "2019-03-07T20:00:25.557469Z",
"updateTime": "2019-03-28T07:52:57.219526Z",
"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": "6df9a80f147c4349949f6573b5275deebddd3ba8",
"internalRef": "237262681"
"sha": "6a84b3267b0a95e922608b9891219075047eee29",
"internalRef": "240640999"
}
}
],
Expand Down