diff --git a/google-cloud-clients/google-cloud-compute/src/main/java/com/google/cloud/compute/v1/InstanceClient.java b/google-cloud-clients/google-cloud-compute/src/main/java/com/google/cloud/compute/v1/InstanceClient.java index b6e5c69f776c..b57f56275808 100644 --- a/google-cloud-clients/google-cloud-compute/src/main/java/com/google/cloud/compute/v1/InstanceClient.java +++ b/google-cloud-clients/google-cloud-compute/src/main/java/com/google/cloud/compute/v1/InstanceClient.java @@ -1610,7 +1610,7 @@ public final ListReferrersInstancesPagedResponse listReferrersInstances( // AUTO-GENERATED DOCUMENTATION AND METHOD /** - * Performs a reset on the instance. This is a hard reset; the VM does not do a graceful shutdown. + * Performs a reset on the instance. This is a hard reset the VM does not do a graceful shutdown. * For more information, see Resetting an instance. * *

Sample code: @@ -1637,7 +1637,7 @@ public final Operation resetInstance(ProjectZoneInstanceName instance) { // AUTO-GENERATED DOCUMENTATION AND METHOD /** - * Performs a reset on the instance. This is a hard reset; the VM does not do a graceful shutdown. + * Performs a reset on the instance. This is a hard reset the VM does not do a graceful shutdown. * For more information, see Resetting an instance. * *

Sample code: @@ -1662,7 +1662,7 @@ public final Operation resetInstance(String instance) { // AUTO-GENERATED DOCUMENTATION AND METHOD /** - * Performs a reset on the instance. This is a hard reset; the VM does not do a graceful shutdown. + * Performs a reset on the instance. This is a hard reset the VM does not do a graceful shutdown. * For more information, see Resetting an instance. * *

Sample code: @@ -1687,7 +1687,7 @@ public final Operation resetInstance(ResetInstanceHttpRequest request) { // AUTO-GENERATED DOCUMENTATION AND METHOD /** - * Performs a reset on the instance. This is a hard reset; the VM does not do a graceful shutdown. + * Performs a reset on the instance. This is a hard reset the VM does not do a graceful shutdown. * For more information, see Resetting an instance. * *

Sample code: diff --git a/google-cloud-clients/google-cloud-compute/src/main/java/com/google/cloud/compute/v1/Interconnect.java b/google-cloud-clients/google-cloud-compute/src/main/java/com/google/cloud/compute/v1/Interconnect.java index 29d937996d25..1a97c930ed57 100644 --- a/google-cloud-clients/google-cloud-compute/src/main/java/com/google/cloud/compute/v1/Interconnect.java +++ b/google-cloud-clients/google-cloud-compute/src/main/java/com/google/cloud/compute/v1/Interconnect.java @@ -265,7 +265,7 @@ public String getGoogleIpAddress() { } /** - * [Output Only] Google reference ID; to be used when raising support tickets with Google or + * [Output Only] Google reference ID to be used when raising support tickets with Google or * otherwise to debug backend connectivity issues. */ public String getGoogleReferenceId() { @@ -646,7 +646,7 @@ public Builder setGoogleIpAddress(String googleIpAddress) { } /** - * [Output Only] Google reference ID; to be used when raising support tickets with Google or + * [Output Only] Google reference ID to be used when raising support tickets with Google or * otherwise to debug backend connectivity issues. */ public String getGoogleReferenceId() { @@ -654,7 +654,7 @@ public String getGoogleReferenceId() { } /** - * [Output Only] Google reference ID; to be used when raising support tickets with Google or + * [Output Only] Google reference ID to be used when raising support tickets with Google or * otherwise to debug backend connectivity issues. */ public Builder setGoogleReferenceId(String googleReferenceId) { diff --git a/google-cloud-clients/google-cloud-compute/src/main/java/com/google/cloud/compute/v1/ManagedInstance.java b/google-cloud-clients/google-cloud-compute/src/main/java/com/google/cloud/compute/v1/ManagedInstance.java index fe956603baeb..c84cba61333f 100644 --- a/google-cloud-clients/google-cloud-compute/src/main/java/com/google/cloud/compute/v1/ManagedInstance.java +++ b/google-cloud-clients/google-cloud-compute/src/main/java/com/google/cloud/compute/v1/ManagedInstance.java @@ -31,6 +31,7 @@ public final class ManagedInstance implements ApiMessage { private final String instance; private final String instanceStatus; private final ManagedInstanceLastAttempt lastAttempt; + private final ManagedInstanceVersion version; private ManagedInstance() { this.currentAction = null; @@ -38,6 +39,7 @@ private ManagedInstance() { this.instance = null; this.instanceStatus = null; this.lastAttempt = null; + this.version = null; } private ManagedInstance( @@ -45,12 +47,14 @@ private ManagedInstance( String id, String instance, String instanceStatus, - ManagedInstanceLastAttempt lastAttempt) { + ManagedInstanceLastAttempt lastAttempt, + ManagedInstanceVersion version) { this.currentAction = currentAction; this.id = id; this.instance = instance; this.instanceStatus = instanceStatus; this.lastAttempt = lastAttempt; + this.version = version; } @Override @@ -70,6 +74,9 @@ public Object getFieldValue(String fieldName) { if ("lastAttempt".equals(fieldName)) { return lastAttempt; } + if ("version".equals(fieldName)) { + return version; + } return null; } @@ -140,6 +147,11 @@ public ManagedInstanceLastAttempt getLastAttempt() { return lastAttempt; } + /** [Output Only] Intended version of this instance. */ + public ManagedInstanceVersion getVersion() { + return version; + } + public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } @@ -168,6 +180,7 @@ public static class Builder { private String instance; private String instanceStatus; private ManagedInstanceLastAttempt lastAttempt; + private ManagedInstanceVersion version; Builder() {} @@ -188,6 +201,9 @@ public Builder mergeFrom(ManagedInstance other) { if (other.getLastAttempt() != null) { this.lastAttempt = other.lastAttempt; } + if (other.getVersion() != null) { + this.version = other.version; + } return this; } @@ -197,6 +213,7 @@ public Builder mergeFrom(ManagedInstance other) { this.instance = source.instance; this.instanceStatus = source.instanceStatus; this.lastAttempt = source.lastAttempt; + this.version = source.version; } /** @@ -304,9 +321,20 @@ public Builder setLastAttempt(ManagedInstanceLastAttempt lastAttempt) { return this; } + /** [Output Only] Intended version of this instance. */ + public ManagedInstanceVersion getVersion() { + return version; + } + + /** [Output Only] Intended version of this instance. */ + public Builder setVersion(ManagedInstanceVersion version) { + this.version = version; + return this; + } + public ManagedInstance build() { - return new ManagedInstance(currentAction, id, instance, instanceStatus, lastAttempt); + return new ManagedInstance(currentAction, id, instance, instanceStatus, lastAttempt, version); } public Builder clone() { @@ -316,6 +344,7 @@ public Builder clone() { newBuilder.setInstance(this.instance); newBuilder.setInstanceStatus(this.instanceStatus); newBuilder.setLastAttempt(this.lastAttempt); + newBuilder.setVersion(this.version); return newBuilder; } } @@ -337,6 +366,9 @@ public String toString() { + ", " + "lastAttempt=" + lastAttempt + + ", " + + "version=" + + version + "}"; } @@ -351,13 +383,14 @@ public boolean equals(Object o) { && Objects.equals(this.id, that.getId()) && Objects.equals(this.instance, that.getInstance()) && Objects.equals(this.instanceStatus, that.getInstanceStatus()) - && Objects.equals(this.lastAttempt, that.getLastAttempt()); + && Objects.equals(this.lastAttempt, that.getLastAttempt()) + && Objects.equals(this.version, that.getVersion()); } return false; } @Override public int hashCode() { - return Objects.hash(currentAction, id, instance, instanceStatus, lastAttempt); + return Objects.hash(currentAction, id, instance, instanceStatus, lastAttempt, version); } } diff --git a/google-cloud-clients/google-cloud-compute/src/main/java/com/google/cloud/compute/v1/ManagedInstanceVersion.java b/google-cloud-clients/google-cloud-compute/src/main/java/com/google/cloud/compute/v1/ManagedInstanceVersion.java new file mode 100644 index 000000000000..232cf0b8bdc3 --- /dev/null +++ b/google-cloud-clients/google-cloud-compute/src/main/java/com/google/cloud/compute/v1/ManagedInstanceVersion.java @@ -0,0 +1,196 @@ +/* + * Copyright 2019 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.google.cloud.compute.v1; + +import com.google.api.core.BetaApi; +import com.google.api.gax.httpjson.ApiMessage; +import java.util.List; +import java.util.Objects; +import javax.annotation.Generated; +import javax.annotation.Nullable; + +@Generated("by GAPIC") +@BetaApi +public final class ManagedInstanceVersion implements ApiMessage { + private final String instanceTemplate; + private final String name; + + private ManagedInstanceVersion() { + this.instanceTemplate = null; + this.name = null; + } + + private ManagedInstanceVersion(String instanceTemplate, String name) { + this.instanceTemplate = instanceTemplate; + this.name = name; + } + + @Override + public Object getFieldValue(String fieldName) { + if ("instanceTemplate".equals(fieldName)) { + return instanceTemplate; + } + if ("name".equals(fieldName)) { + return name; + } + return null; + } + + @Nullable + @Override + public ApiMessage getApiMessageRequestBody() { + return null; + } + + @Nullable + @Override + /** + * The fields that should be serialized (even if they have empty values). If the containing + * message object has a non-null fieldmask, then all the fields in the field mask (and only those + * fields in the field mask) will be serialized. If the containing object does not have a + * fieldmask, then only non-empty fields will be serialized. + */ + public List getFieldMask() { + return null; + } + + /** + * [Output Only] The intended template of the instance. This field is empty when current_action is + * one of { DELETING, ABANDONING }. + */ + public String getInstanceTemplate() { + return instanceTemplate; + } + + /** [Output Only] Name of the version. */ + public String getName() { + return name; + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(ManagedInstanceVersion prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + public static ManagedInstanceVersion getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final ManagedInstanceVersion DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new ManagedInstanceVersion(); + } + + public static class Builder { + private String instanceTemplate; + private String name; + + Builder() {} + + public Builder mergeFrom(ManagedInstanceVersion other) { + if (other == ManagedInstanceVersion.getDefaultInstance()) return this; + if (other.getInstanceTemplate() != null) { + this.instanceTemplate = other.instanceTemplate; + } + if (other.getName() != null) { + this.name = other.name; + } + return this; + } + + Builder(ManagedInstanceVersion source) { + this.instanceTemplate = source.instanceTemplate; + this.name = source.name; + } + + /** + * [Output Only] The intended template of the instance. This field is empty when current_action + * is one of { DELETING, ABANDONING }. + */ + public String getInstanceTemplate() { + return instanceTemplate; + } + + /** + * [Output Only] The intended template of the instance. This field is empty when current_action + * is one of { DELETING, ABANDONING }. + */ + public Builder setInstanceTemplate(String instanceTemplate) { + this.instanceTemplate = instanceTemplate; + return this; + } + + /** [Output Only] Name of the version. */ + public String getName() { + return name; + } + + /** [Output Only] Name of the version. */ + public Builder setName(String name) { + this.name = name; + return this; + } + + public ManagedInstanceVersion build() { + + return new ManagedInstanceVersion(instanceTemplate, name); + } + + public Builder clone() { + Builder newBuilder = new Builder(); + newBuilder.setInstanceTemplate(this.instanceTemplate); + newBuilder.setName(this.name); + return newBuilder; + } + } + + @Override + public String toString() { + return "ManagedInstanceVersion{" + + "instanceTemplate=" + + instanceTemplate + + ", " + + "name=" + + name + + "}"; + } + + @Override + public boolean equals(Object o) { + if (o == this) { + return true; + } + if (o instanceof ManagedInstanceVersion) { + ManagedInstanceVersion that = (ManagedInstanceVersion) o; + return Objects.equals(this.instanceTemplate, that.getInstanceTemplate()) + && Objects.equals(this.name, that.getName()); + } + return false; + } + + @Override + public int hashCode() { + return Objects.hash(instanceTemplate, name); + } +} diff --git a/google-cloud-clients/google-cloud-compute/src/main/java/com/google/cloud/compute/v1/RawDisk.java b/google-cloud-clients/google-cloud-compute/src/main/java/com/google/cloud/compute/v1/RawDisk.java index be8f3a39a52f..0f0a4085a828 100644 --- a/google-cloud-clients/google-cloud-compute/src/main/java/com/google/cloud/compute/v1/RawDisk.java +++ b/google-cloud-clients/google-cloud-compute/src/main/java/com/google/cloud/compute/v1/RawDisk.java @@ -84,7 +84,7 @@ public String getContainerType() { } /** - * An optional SHA1 checksum of the disk image before unpackaging; provided by the client when the + * An optional SHA1 checksum of the disk image before unpackaging provided by the client when the * disk image is created. */ public String getSha1Checksum() { @@ -168,7 +168,7 @@ public Builder setContainerType(String containerType) { } /** - * An optional SHA1 checksum of the disk image before unpackaging; provided by the client when + * An optional SHA1 checksum of the disk image before unpackaging provided by the client when * the disk image is created. */ public String getSha1Checksum() { @@ -176,7 +176,7 @@ public String getSha1Checksum() { } /** - * An optional SHA1 checksum of the disk image before unpackaging; provided by the client when + * An optional SHA1 checksum of the disk image before unpackaging provided by the client when * the disk image is created. */ public Builder setSha1Checksum(String sha1Checksum) { diff --git a/google-cloud-clients/google-cloud-compute/src/main/java/com/google/cloud/compute/v1/ResetInstanceHttpRequest.java b/google-cloud-clients/google-cloud-compute/src/main/java/com/google/cloud/compute/v1/ResetInstanceHttpRequest.java index cf0d284f80c5..78b20863174b 100644 --- a/google-cloud-clients/google-cloud-compute/src/main/java/com/google/cloud/compute/v1/ResetInstanceHttpRequest.java +++ b/google-cloud-clients/google-cloud-compute/src/main/java/com/google/cloud/compute/v1/ResetInstanceHttpRequest.java @@ -26,7 +26,7 @@ @BetaApi /** * Request object for method compute.instances.reset. Performs a reset on the instance. This is a - * hard reset; the VM does not do a graceful shutdown. For more information, see Resetting an + * hard reset the VM does not do a graceful shutdown. For more information, see Resetting an * instance. */ public final class ResetInstanceHttpRequest implements ApiMessage { diff --git a/google-cloud-clients/google-cloud-compute/synth.metadata b/google-cloud-clients/google-cloud-compute/synth.metadata index a2d48230cb9f..a0c420a5ba4d 100644 --- a/google-cloud-clients/google-cloud-compute/synth.metadata +++ b/google-cloud-clients/google-cloud-compute/synth.metadata @@ -1,11 +1,11 @@ { - "updateTime": "2019-02-21T08:37:13.725039Z", + "updateTime": "2019-02-28T08:37:09.528246Z", "sources": [ { "git": { "name": "discovery-artifact-manager", "remote": "https://github.com/googleapis/discovery-artifact-manager.git", - "sha": "08a158ea995a7cff450f31c9eb889dadaea17fbb" + "sha": "ab3567b03ec53c3affe70518e59df16ca9cc7bac" } }, {