Unverified Commit 0e7c3d64 authored by Kubernetes Submit Queue's avatar Kubernetes Submit Queue Committed by GitHub

Merge pull request #64848 from yguo0905/automated-cherry-pick-of-#64727-upstream-release-1.10

Automatic merge from submit-queue. Automated cherry pick of #64727: Update GCE cloud provider to use Cloud TPU v1 API Cherry pick of #64727 on release-1.10. #64727: Update GCE cloud provider to use Cloud TPU v1 API
parents af0d3570 31d3a180
......@@ -3099,51 +3099,51 @@
},
{
"ImportPath": "google.golang.org/api/cloudmonitoring/v2beta2",
"Rev": "7f657476956314fee258816aaf81c0ff65cf8bee"
"Rev": "8e296ef260056b6323d10727db40512dac6d92d5"
},
{
"ImportPath": "google.golang.org/api/compute/v0.alpha",
"Rev": "7f657476956314fee258816aaf81c0ff65cf8bee"
"Rev": "8e296ef260056b6323d10727db40512dac6d92d5"
},
{
"ImportPath": "google.golang.org/api/compute/v0.beta",
"Rev": "7f657476956314fee258816aaf81c0ff65cf8bee"
"Rev": "8e296ef260056b6323d10727db40512dac6d92d5"
},
{
"ImportPath": "google.golang.org/api/compute/v1",
"Rev": "7f657476956314fee258816aaf81c0ff65cf8bee"
"Rev": "8e296ef260056b6323d10727db40512dac6d92d5"
},
{
"ImportPath": "google.golang.org/api/container/v1",
"Rev": "7f657476956314fee258816aaf81c0ff65cf8bee"
"Rev": "8e296ef260056b6323d10727db40512dac6d92d5"
},
{
"ImportPath": "google.golang.org/api/gensupport",
"Rev": "7f657476956314fee258816aaf81c0ff65cf8bee"
"Rev": "8e296ef260056b6323d10727db40512dac6d92d5"
},
{
"ImportPath": "google.golang.org/api/googleapi",
"Rev": "7f657476956314fee258816aaf81c0ff65cf8bee"
"Rev": "8e296ef260056b6323d10727db40512dac6d92d5"
},
{
"ImportPath": "google.golang.org/api/googleapi/internal/uritemplates",
"Rev": "7f657476956314fee258816aaf81c0ff65cf8bee"
"Rev": "8e296ef260056b6323d10727db40512dac6d92d5"
},
{
"ImportPath": "google.golang.org/api/logging/v2beta1",
"Rev": "7f657476956314fee258816aaf81c0ff65cf8bee"
"Rev": "8e296ef260056b6323d10727db40512dac6d92d5"
},
{
"ImportPath": "google.golang.org/api/monitoring/v3",
"Rev": "7f657476956314fee258816aaf81c0ff65cf8bee"
"Rev": "8e296ef260056b6323d10727db40512dac6d92d5"
},
{
"ImportPath": "google.golang.org/api/pubsub/v1",
"Rev": "7f657476956314fee258816aaf81c0ff65cf8bee"
"Rev": "8e296ef260056b6323d10727db40512dac6d92d5"
},
{
"ImportPath": "google.golang.org/api/tpu/v1alpha1",
"Rev": "7f657476956314fee258816aaf81c0ff65cf8bee"
"ImportPath": "google.golang.org/api/tpu/v1",
"Rev": "8e296ef260056b6323d10727db40512dac6d92d5"
},
{
"ImportPath": "google.golang.org/genproto/googleapis/api/annotations",
......
......@@ -93030,7 +93030,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
================================================================================
= vendor/google.golang.org/api/tpu/v1alpha1 licensed under: =
= vendor/google.golang.org/api/tpu/v1 licensed under: =
Copyright (c) 2011 Google Inc. All rights reserved.
......@@ -70,7 +70,7 @@ go_library(
"//vendor/google.golang.org/api/compute/v1:go_default_library",
"//vendor/google.golang.org/api/container/v1:go_default_library",
"//vendor/google.golang.org/api/googleapi:go_default_library",
"//vendor/google.golang.org/api/tpu/v1alpha1:go_default_library",
"//vendor/google.golang.org/api/tpu/v1:go_default_library",
"//vendor/gopkg.in/gcfg.v1:go_default_library",
"//vendor/k8s.io/api/core/v1:go_default_library",
"//vendor/k8s.io/apimachinery/pkg/api/resource:go_default_library",
......
......@@ -25,7 +25,7 @@ import (
"github.com/golang/glog"
"google.golang.org/api/googleapi"
tpuapi "google.golang.org/api/tpu/v1alpha1"
tpuapi "google.golang.org/api/tpu/v1"
"k8s.io/apimachinery/pkg/util/wait"
)
......@@ -165,7 +165,7 @@ func (gce *GCECloud) waitForTPUOp(interval, timeout time.Duration, op *tpuapi.Op
// newTPUMetricContext returns a new metricContext used for recording metrics
// of Cloud TPU API calls.
func newTPUMetricContext(request, zone string) *metricContext {
return newGenericMetricContext("tpus", request, unusedMetricLabel, zone, "alpha")
return newGenericMetricContext("tpus", request, unusedMetricLabel, zone, "v1")
}
// getErrorFromTPUOp returns the error in the failed op, or nil if the op
......
......@@ -413,7 +413,7 @@ filegroup(
"//vendor/google.golang.org/api/logging/v2beta1:all-srcs",
"//vendor/google.golang.org/api/monitoring/v3:all-srcs",
"//vendor/google.golang.org/api/pubsub/v1:all-srcs",
"//vendor/google.golang.org/api/tpu/v1alpha1:all-srcs",
"//vendor/google.golang.org/api/tpu/v1:all-srcs",
"//vendor/google.golang.org/genproto/googleapis/api/annotations:all-srcs",
"//vendor/google.golang.org/genproto/googleapis/rpc/status:all-srcs",
"//vendor/google.golang.org/grpc:all-srcs",
......
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
......@@ -13,6 +13,7 @@ import (
"net/http"
"net/textproto"
"strings"
"sync"
"google.golang.org/api/googleapi"
)
......@@ -105,12 +106,13 @@ type typeReader struct {
typ string
}
// multipartReader combines the contents of multiple readers to creat a multipart/related HTTP body.
// multipartReader combines the contents of multiple readers to create a multipart/related HTTP body.
// Close must be called if reads from the multipartReader are abandoned before reaching EOF.
type multipartReader struct {
pr *io.PipeReader
pipeOpen bool
ctype string
mu sync.Mutex
pipeOpen bool
}
func newMultipartReader(parts []typeReader) *multipartReader {
......@@ -146,10 +148,13 @@ func (mp *multipartReader) Read(data []byte) (n int, err error) {
}
func (mp *multipartReader) Close() error {
mp.mu.Lock()
if !mp.pipeOpen {
mp.mu.Unlock()
return nil
}
mp.pipeOpen = false
mp.mu.Unlock()
return mp.pr.Close()
}
......
......@@ -224,7 +224,7 @@
]
},
"write": {
"description": "Log entry resourcesWrites log entries to Stackdriver Logging. This API method is the only way to send log entries to Stackdriver Logging. This method is used, directly or indirectly, by the Stackdriver Logging agent (fluentd) and all logging libraries configured to use Stackdriver Logging.",
"description": "Writes log entries to Stackdriver Logging. This API method is the only way to send log entries to Stackdriver Logging. This method is used, directly or indirectly, by the Stackdriver Logging agent (fluentd) and all logging libraries configured to use Stackdriver Logging. A single request may contain log entries for a maximum of 1000 different resources (projects, organizations, billing accounts or folders)",
"flatPath": "v2beta1/entries:write",
"httpMethod": "POST",
"id": "logging.entries.write",
......@@ -755,7 +755,7 @@
}
}
},
"revision": "20180213",
"revision": "20180424",
"rootUrl": "https://logging.googleapis.com/",
"schemas": {
"BucketOptions": {
......@@ -1102,6 +1102,10 @@
"description": "Required. The resource name of the log to which this log entry belongs:\n\"projects/[PROJECT_ID]/logs/[LOG_ID]\"\n\"organizations/[ORGANIZATION_ID]/logs/[LOG_ID]\"\n\"billingAccounts/[BILLING_ACCOUNT_ID]/logs/[LOG_ID]\"\n\"folders/[FOLDER_ID]/logs/[LOG_ID]\"\nA project number may optionally be used in place of PROJECT_ID. The project number is translated to its corresponding PROJECT_ID internally and the log_name field will contain PROJECT_ID in queries and exports.[LOG_ID] must be URL-encoded within log_name. Example: \"organizations/1234567890/logs/cloudresourcemanager.googleapis.com%2Factivity\". [LOG_ID] must be less than 512 characters long and can only include the following characters: upper and lower case alphanumeric characters, forward-slash, underscore, hyphen, and period.For backward compatibility, if log_name begins with a forward-slash, such as /projects/..., then the log entry is ingested as usual but the forward-slash is removed. Listing the log entry will not show the leading slash and filtering for a log name with a leading slash will never return any results.",
"type": "string"
},
"metadata": {
"$ref": "MonitoredResourceMetadata",
"description": "Output only. Additional metadata about the monitored resource. Only k8s_container, k8s_pod, and k8s_node MonitoredResources have this field populated."
},
"operation": {
"$ref": "LogEntryOperation",
"description": "Optional. Information about an operation associated with the log entry, if applicable."
......@@ -1121,7 +1125,7 @@
},
"resource": {
"$ref": "MonitoredResource",
"description": "Required. The monitored resource associated with this log entry. Example: a log entry that reports a database error would be associated with the monitored resource designating the particular database that reported the error."
"description": "Required. The primary monitored resource associated with this log entry. Example: a log entry that reports a database error would be associated with the monitored resource designating the particular database that reported the error."
},
"severity": {
"description": "Optional. The severity of the log entry. The default value is LogSeverity.DEFAULT.",
......@@ -1162,7 +1166,7 @@
"type": "string"
},
"timestamp": {
"description": "Optional. The time the event described by the log entry occurred. This time is used to compute the log entry's age and to enforce the logs retention period. If this field is omitted in a new log entry, then Stackdriver Logging assigns it the current time.Incoming log entries should have timestamps that are no more than the logs retention period in the past, and no more than 24 hours in the future. Log entries outside those time boundaries will not be available when calling entries.list, but those log entries can still be exported with LogSinks.",
"description": "Optional. The time the event described by the log entry occurred. This time is used to compute the log entry's age and to enforce the logs retention period. If this field is omitted in a new log entry, then Stackdriver Logging assigns it the current time. Timestamps have nanosecond accuracy, but trailing zeros in the fractional seconds might be omitted when the timestamp is displayed.Incoming log entries should have timestamps that are no more than the logs retention period in the past, and no more than 24 hours in the future. Log entries outside those time boundaries will not be available when calling entries.list, but those log entries can still be exported with LogSinks.",
"format": "google-datetime",
"type": "string"
},
......@@ -1483,6 +1487,28 @@
},
"type": "object"
},
"MonitoredResourceMetadata": {
"description": "Auxiliary metadata for a MonitoredResource object. MonitoredResource objects contain the minimum set of information to uniquely identify a monitored resource instance. There is some other useful auxiliary metadata. Google Stackdriver Monitoring \u0026 Logging uses an ingestion pipeline to extract metadata for cloud resources of all types , and stores the metadata in this message.",
"id": "MonitoredResourceMetadata",
"properties": {
"systemLabels": {
"additionalProperties": {
"description": "Properties of the object.",
"type": "any"
},
"description": "Output only. Values for predefined system metadata labels. System labels are a kind of metadata extracted by Google Stackdriver. Stackdriver determines what system labels are useful and how to obtain their values. Some examples: \"machine_image\", \"vpc\", \"subnet_id\", \"security_group\", \"name\", etc. System label values can be only strings, Boolean values, or a list of strings. For example:\n{ \"name\": \"my-test-instance\",\n \"security_group\": [\"a\", \"b\", \"c\"],\n \"spot_instance\": false }\n",
"type": "object"
},
"userLabels": {
"additionalProperties": {
"type": "string"
},
"description": "Output only. A map of user-defined metadata labels.",
"type": "object"
}
},
"type": "object"
},
"RequestLog": {
"description": "Complete log information about a single HTTP request to an App Engine application.",
"id": "RequestLog",
......
......@@ -865,6 +865,11 @@ type LogEntry struct {
// never return any results.
LogName string `json:"logName,omitempty"`
// Metadata: Output only. Additional metadata about the monitored
// resource. Only k8s_container, k8s_pod, and k8s_node
// MonitoredResources have this field populated.
Metadata *MonitoredResourceMetadata `json:"metadata,omitempty"`
// Operation: Optional. Information about an operation associated with
// the log entry, if applicable.
Operation *LogEntryOperation `json:"operation,omitempty"`
......@@ -878,10 +883,10 @@ type LogEntry struct {
// Stackdriver Logging.
ReceiveTimestamp string `json:"receiveTimestamp,omitempty"`
// Resource: Required. The monitored resource associated with this log
// entry. Example: a log entry that reports a database error would be
// associated with the monitored resource designating the particular
// database that reported the error.
// Resource: Required. The primary monitored resource associated with
// this log entry. Example: a log entry that reports a database error
// would be associated with the monitored resource designating the
// particular database that reported the error.
Resource *MonitoredResource `json:"resource,omitempty"`
// Severity: Optional. The severity of the log entry. The default value
......@@ -919,12 +924,14 @@ type LogEntry struct {
// Timestamp: Optional. The time the event described by the log entry
// occurred. This time is used to compute the log entry's age and to
// enforce the logs retention period. If this field is omitted in a new
// log entry, then Stackdriver Logging assigns it the current
// time.Incoming log entries should have timestamps that are no more
// than the logs retention period in the past, and no more than 24 hours
// in the future. Log entries outside those time boundaries will not be
// available when calling entries.list, but those log entries can still
// be exported with LogSinks.
// log entry, then Stackdriver Logging assigns it the current time.
// Timestamps have nanosecond accuracy, but trailing zeros in the
// fractional seconds might be omitted when the timestamp is
// displayed.Incoming log entries should have timestamps that are no
// more than the logs retention period in the past, and no more than 24
// hours in the future. Log entries outside those time boundaries will
// not be available when calling entries.list, but those log entries can
// still be exported with LogSinks.
Timestamp string `json:"timestamp,omitempty"`
// Trace: Optional. Resource name of the trace associated with the log
......@@ -1575,6 +1582,52 @@ func (s *MonitoredResourceDescriptor) MarshalJSON() ([]byte, error) {
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
// MonitoredResourceMetadata: Auxiliary metadata for a MonitoredResource
// object. MonitoredResource objects contain the minimum set of
// information to uniquely identify a monitored resource instance. There
// is some other useful auxiliary metadata. Google Stackdriver
// Monitoring & Logging uses an ingestion pipeline to extract metadata
// for cloud resources of all types , and stores the metadata in this
// message.
type MonitoredResourceMetadata struct {
// SystemLabels: Output only. Values for predefined system metadata
// labels. System labels are a kind of metadata extracted by Google
// Stackdriver. Stackdriver determines what system labels are useful and
// how to obtain their values. Some examples: "machine_image", "vpc",
// "subnet_id", "security_group", "name", etc. System label values can
// be only strings, Boolean values, or a list of strings. For example:
// { "name": "my-test-instance",
// "security_group": ["a", "b", "c"],
// "spot_instance": false }
//
SystemLabels googleapi.RawMessage `json:"systemLabels,omitempty"`
// UserLabels: Output only. A map of user-defined metadata labels.
UserLabels map[string]string `json:"userLabels,omitempty"`
// ForceSendFields is a list of field names (e.g. "SystemLabels") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "SystemLabels") to include
// in API requests with the JSON null value. By default, fields with
// empty values are omitted from API requests. However, any field with
// an empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *MonitoredResourceMetadata) MarshalJSON() ([]byte, error) {
type NoMethod MonitoredResourceMetadata
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
// RequestLog: Complete log information about a single HTTP request to
// an App Engine application.
type RequestLog struct {
......@@ -2385,11 +2438,13 @@ type EntriesWriteCall struct {
header_ http.Header
}
// Write: Log entry resourcesWrites log entries to Stackdriver Logging.
// This API method is the only way to send log entries to Stackdriver
// Logging. This method is used, directly or indirectly, by the
// Stackdriver Logging agent (fluentd) and all logging libraries
// configured to use Stackdriver Logging.
// Write: Writes log entries to Stackdriver Logging. This API method is
// the only way to send log entries to Stackdriver Logging. This method
// is used, directly or indirectly, by the Stackdriver Logging agent
// (fluentd) and all logging libraries configured to use Stackdriver
// Logging. A single request may contain log entries for a maximum of
// 1000 different resources (projects, organizations, billing accounts
// or folders)
func (r *EntriesService) Write(writelogentriesrequest *WriteLogEntriesRequest) *EntriesWriteCall {
c := &EntriesWriteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
c.writelogentriesrequest = writelogentriesrequest
......@@ -2479,7 +2534,7 @@ func (c *EntriesWriteCall) Do(opts ...googleapi.CallOption) (*WriteLogEntriesRes
}
return ret, nil
// {
// "description": "Log entry resourcesWrites log entries to Stackdriver Logging. This API method is the only way to send log entries to Stackdriver Logging. This method is used, directly or indirectly, by the Stackdriver Logging agent (fluentd) and all logging libraries configured to use Stackdriver Logging.",
// "description": "Writes log entries to Stackdriver Logging. This API method is the only way to send log entries to Stackdriver Logging. This method is used, directly or indirectly, by the Stackdriver Logging agent (fluentd) and all logging libraries configured to use Stackdriver Logging. A single request may contain log entries for a maximum of 1000 different resources (projects, organizations, billing accounts or folders)",
// "flatPath": "v2beta1/entries:write",
// "httpMethod": "POST",
// "id": "logging.entries.write",
......
......@@ -126,6 +126,175 @@
"resources": {
"projects": {
"resources": {
"alertPolicies": {
"methods": {
"create": {
"description": "Creates a new alerting policy.",
"flatPath": "v3/projects/{projectsId}/alertPolicies",
"httpMethod": "POST",
"id": "monitoring.projects.alertPolicies.create",
"parameterOrder": [
"name"
],
"parameters": {
"name": {
"description": "The project in which to create the alerting policy. The format is projects/[PROJECT_ID].Note that this field names the parent container in which the alerting policy will be written, not the name of the created policy. The alerting policy that is returned will have a name that contains a normalized representation of this name as a prefix but adds a suffix of the form /alertPolicies/[POLICY_ID], identifying the policy in the container.",
"location": "path",
"pattern": "^projects/[^/]+$",
"required": true,
"type": "string"
}
},
"path": "v3/{+name}/alertPolicies",
"request": {
"$ref": "AlertPolicy"
},
"response": {
"$ref": "AlertPolicy"
},
"scopes": [
"https://www.googleapis.com/auth/cloud-platform",
"https://www.googleapis.com/auth/monitoring"
]
},
"delete": {
"description": "Deletes an alerting policy.",
"flatPath": "v3/projects/{projectsId}/alertPolicies/{alertPoliciesId}",
"httpMethod": "DELETE",
"id": "monitoring.projects.alertPolicies.delete",
"parameterOrder": [
"name"
],
"parameters": {
"name": {
"description": "The alerting policy to delete. The format is:\nprojects/[PROJECT_ID]/alertPolicies/[ALERT_POLICY_ID]\nFor more information, see AlertPolicy.",
"location": "path",
"pattern": "^projects/[^/]+/alertPolicies/[^/]+$",
"required": true,
"type": "string"
}
},
"path": "v3/{+name}",
"response": {
"$ref": "Empty"
},
"scopes": [
"https://www.googleapis.com/auth/cloud-platform",
"https://www.googleapis.com/auth/monitoring"
]
},
"get": {
"description": "Gets a single alerting policy.",
"flatPath": "v3/projects/{projectsId}/alertPolicies/{alertPoliciesId}",
"httpMethod": "GET",
"id": "monitoring.projects.alertPolicies.get",
"parameterOrder": [
"name"
],
"parameters": {
"name": {
"description": "The alerting policy to retrieve. The format is\nprojects/[PROJECT_ID]/alertPolicies/[ALERT_POLICY_ID]\n",
"location": "path",
"pattern": "^projects/[^/]+/alertPolicies/[^/]+$",
"required": true,
"type": "string"
}
},
"path": "v3/{+name}",
"response": {
"$ref": "AlertPolicy"
},
"scopes": [
"https://www.googleapis.com/auth/cloud-platform",
"https://www.googleapis.com/auth/monitoring",
"https://www.googleapis.com/auth/monitoring.read"
]
},
"list": {
"description": "Lists the existing alerting policies for the project.",
"flatPath": "v3/projects/{projectsId}/alertPolicies",
"httpMethod": "GET",
"id": "monitoring.projects.alertPolicies.list",
"parameterOrder": [
"name"
],
"parameters": {
"filter": {
"description": "If provided, this field specifies the criteria that must be met by alert policies to be included in the response.For more details, see sorting and filtering.",
"location": "query",
"type": "string"
},
"name": {
"description": "The project whose alert policies are to be listed. The format is\nprojects/[PROJECT_ID]\nNote that this field names the parent container in which the alerting policies to be listed are stored. To retrieve a single alerting policy by name, use the GetAlertPolicy operation, instead.",
"location": "path",
"pattern": "^projects/[^/]+$",
"required": true,
"type": "string"
},
"orderBy": {
"description": "A comma-separated list of fields by which to sort the result. Supports the same set of field references as the filter field. Entries can be prefixed with a minus sign to sort by the field in descending order.For more details, see sorting and filtering.",
"location": "query",
"type": "string"
},
"pageSize": {
"description": "The maximum number of results to return in a single response.",
"format": "int32",
"location": "query",
"type": "integer"
},
"pageToken": {
"description": "If this field is not empty then it must contain the nextPageToken value returned by a previous call to this method. Using this field causes the method to return more results from the previous method call.",
"location": "query",
"type": "string"
}
},
"path": "v3/{+name}/alertPolicies",
"response": {
"$ref": "ListAlertPoliciesResponse"
},
"scopes": [
"https://www.googleapis.com/auth/cloud-platform",
"https://www.googleapis.com/auth/monitoring",
"https://www.googleapis.com/auth/monitoring.read"
]
},
"patch": {
"description": "Updates an alerting policy. You can either replace the entire policy with a new one or replace only certain fields in the current alerting policy by specifying the fields to be updated via updateMask. Returns the updated alerting policy.",
"flatPath": "v3/projects/{projectsId}/alertPolicies/{alertPoliciesId}",
"httpMethod": "PATCH",
"id": "monitoring.projects.alertPolicies.patch",
"parameterOrder": [
"name"
],
"parameters": {
"name": {
"description": "Required if the policy exists. The resource name for this policy. The syntax is:\nprojects/[PROJECT_ID]/alertPolicies/[ALERT_POLICY_ID]\n[ALERT_POLICY_ID] is assigned by Stackdriver Monitoring when the policy is created. When calling the alertPolicies.create method, do not include the name field in the alerting policy passed as part of the request.",
"location": "path",
"pattern": "^projects/[^/]+/alertPolicies/[^/]+$",
"required": true,
"type": "string"
},
"updateMask": {
"description": "Optional. A list of alerting policy field names. If this field is not empty, each listed field in the existing alerting policy is set to the value of the corresponding field in the supplied policy (alert_policy), or to the field's default value if the field is not in the supplied alerting policy. Fields not listed retain their previous value.Examples of valid field masks include display_name, documentation, documentation.content, documentation.mime_type, user_labels, user_label.nameofkey, enabled, conditions, combiner, etc.If this field is empty, then the supplied alerting policy replaces the existing policy. It is the same as deleting the existing policy and adding the supplied policy, except for the following:\nThe new policy will have the same [ALERT_POLICY_ID] as the former policy. This gives you continuity with the former policy in your notifications and incidents.\nConditions in the new policy will keep their former [CONDITION_ID] if the supplied condition includes the name field with that [CONDITION_ID]. If the supplied condition omits the name field, then a new [CONDITION_ID] is created.",
"format": "google-fieldmask",
"location": "query",
"type": "string"
}
},
"path": "v3/{+name}",
"request": {
"$ref": "AlertPolicy"
},
"response": {
"$ref": "AlertPolicy"
},
"scopes": [
"https://www.googleapis.com/auth/cloud-platform",
"https://www.googleapis.com/auth/monitoring"
]
}
}
},
"collectdTimeSeries": {
"methods": {
"create": {
......@@ -607,6 +776,336 @@
}
}
},
"notificationChannelDescriptors": {
"methods": {
"get": {
"description": "Gets a single channel descriptor. The descriptor indicates which fields are expected / permitted for a notification channel of the given type.",
"flatPath": "v3/projects/{projectsId}/notificationChannelDescriptors/{notificationChannelDescriptorsId}",
"httpMethod": "GET",
"id": "monitoring.projects.notificationChannelDescriptors.get",
"parameterOrder": [
"name"
],
"parameters": {
"name": {
"description": "The channel type for which to execute the request. The format is projects/[PROJECT_ID]/notificationChannelDescriptors/{channel_type}.",
"location": "path",
"pattern": "^projects/[^/]+/notificationChannelDescriptors/[^/]+$",
"required": true,
"type": "string"
}
},
"path": "v3/{+name}",
"response": {
"$ref": "NotificationChannelDescriptor"
},
"scopes": [
"https://www.googleapis.com/auth/cloud-platform",
"https://www.googleapis.com/auth/monitoring",
"https://www.googleapis.com/auth/monitoring.read"
]
},
"list": {
"description": "Lists the descriptors for supported channel types. The use of descriptors makes it possible for new channel types to be dynamically added.",
"flatPath": "v3/projects/{projectsId}/notificationChannelDescriptors",
"httpMethod": "GET",
"id": "monitoring.projects.notificationChannelDescriptors.list",
"parameterOrder": [
"name"
],
"parameters": {
"name": {
"description": "The REST resource name of the parent from which to retrieve the notification channel descriptors. The expected syntax is:\nprojects/[PROJECT_ID]\nNote that this names the parent container in which to look for the descriptors; to retrieve a single descriptor by name, use the GetNotificationChannelDescriptor operation, instead.",
"location": "path",
"pattern": "^projects/[^/]+$",
"required": true,
"type": "string"
},
"pageSize": {
"description": "The maximum number of results to return in a single response. If not set to a positive number, a reasonable value will be chosen by the service.",
"format": "int32",
"location": "query",
"type": "integer"
},
"pageToken": {
"description": "If non-empty, page_token must contain a value returned as the next_page_token in a previous response to request the next set of results.",
"location": "query",
"type": "string"
}
},
"path": "v3/{+name}/notificationChannelDescriptors",
"response": {
"$ref": "ListNotificationChannelDescriptorsResponse"
},
"scopes": [
"https://www.googleapis.com/auth/cloud-platform",
"https://www.googleapis.com/auth/monitoring",
"https://www.googleapis.com/auth/monitoring.read"
]
}
}
},
"notificationChannels": {
"methods": {
"create": {
"description": "Creates a new notification channel, representing a single notification endpoint such as an email address, SMS number, or pagerduty service.",
"flatPath": "v3/projects/{projectsId}/notificationChannels",
"httpMethod": "POST",
"id": "monitoring.projects.notificationChannels.create",
"parameterOrder": [
"name"
],
"parameters": {
"name": {
"description": "The project on which to execute the request. The format is:\nprojects/[PROJECT_ID]\nNote that this names the container into which the channel will be written. This does not name the newly created channel. The resulting channel's name will have a normalized version of this field as a prefix, but will add /notificationChannels/[CHANNEL_ID] to identify the channel.",
"location": "path",
"pattern": "^projects/[^/]+$",
"required": true,
"type": "string"
}
},
"path": "v3/{+name}/notificationChannels",
"request": {
"$ref": "NotificationChannel"
},
"response": {
"$ref": "NotificationChannel"
},
"scopes": [
"https://www.googleapis.com/auth/cloud-platform",
"https://www.googleapis.com/auth/monitoring"
]
},
"delete": {
"description": "Deletes a notification channel.",
"flatPath": "v3/projects/{projectsId}/notificationChannels/{notificationChannelsId}",
"httpMethod": "DELETE",
"id": "monitoring.projects.notificationChannels.delete",
"parameterOrder": [
"name"
],
"parameters": {
"force": {
"description": "If true, the notification channel will be deleted regardless of its use in alert policies (the policies will be updated to remove the channel). If false, channels that are still referenced by an existing alerting policy will fail to be deleted in a delete operation.",
"location": "query",
"type": "boolean"
},
"name": {
"description": "The channel for which to execute the request. The format is projects/[PROJECT_ID]/notificationChannels/[CHANNEL_ID].",
"location": "path",
"pattern": "^projects/[^/]+/notificationChannels/[^/]+$",
"required": true,
"type": "string"
}
},
"path": "v3/{+name}",
"response": {
"$ref": "Empty"
},
"scopes": [
"https://www.googleapis.com/auth/cloud-platform",
"https://www.googleapis.com/auth/monitoring"
]
},
"get": {
"description": "Gets a single notification channel. The channel includes the relevant configuration details with which the channel was created. However, the response may truncate or omit passwords, API keys, or other private key matter and thus the response may not be 100% identical to the information that was supplied in the call to the create method.",
"flatPath": "v3/projects/{projectsId}/notificationChannels/{notificationChannelsId}",
"httpMethod": "GET",
"id": "monitoring.projects.notificationChannels.get",
"parameterOrder": [
"name"
],
"parameters": {
"name": {
"description": "The channel for which to execute the request. The format is projects/[PROJECT_ID]/notificationChannels/[CHANNEL_ID].",
"location": "path",
"pattern": "^projects/[^/]+/notificationChannels/[^/]+$",
"required": true,
"type": "string"
}
},
"path": "v3/{+name}",
"response": {
"$ref": "NotificationChannel"
},
"scopes": [
"https://www.googleapis.com/auth/cloud-platform",
"https://www.googleapis.com/auth/monitoring",
"https://www.googleapis.com/auth/monitoring.read"
]
},
"getVerificationCode": {
"description": "Requests a verification code for an already verified channel that can then be used in a call to VerifyNotificationChannel() on a different channel with an equivalent identity in the same or in a different project. This makes it possible to copy a channel between projects without requiring manual reverification of the channel. If the channel is not in the verified state, this method will fail (in other words, this may only be used if the SendNotificationChannelVerificationCode and VerifyNotificationChannel paths have already been used to put the given channel into the verified state).There is no guarantee that the verification codes returned by this method will be of a similar structure or form as the ones that are delivered to the channel via SendNotificationChannelVerificationCode; while VerifyNotificationChannel() will recognize both the codes delivered via SendNotificationChannelVerificationCode() and returned from GetNotificationChannelVerificationCode(), it is typically the case that the verification codes delivered via SendNotificationChannelVerificationCode() will be shorter and also have a shorter expiration (e.g. codes such as \"G-123456\") whereas GetVerificationCode() will typically return a much longer, websafe base 64 encoded string that has a longer expiration time.",
"flatPath": "v3/projects/{projectsId}/notificationChannels/{notificationChannelsId}:getVerificationCode",
"httpMethod": "POST",
"id": "monitoring.projects.notificationChannels.getVerificationCode",
"parameterOrder": [
"name"
],
"parameters": {
"name": {
"description": "The notification channel for which a verification code is to be generated and retrieved. This must name a channel that is already verified; if the specified channel is not verified, the request will fail.",
"location": "path",
"pattern": "^projects/[^/]+/notificationChannels/[^/]+$",
"required": true,
"type": "string"
}
},
"path": "v3/{+name}:getVerificationCode",
"request": {
"$ref": "GetNotificationChannelVerificationCodeRequest"
},
"response": {
"$ref": "GetNotificationChannelVerificationCodeResponse"
},
"scopes": [
"https://www.googleapis.com/auth/cloud-platform",
"https://www.googleapis.com/auth/monitoring"
]
},
"list": {
"description": "Lists the notification channels that have been created for the project.",
"flatPath": "v3/projects/{projectsId}/notificationChannels",
"httpMethod": "GET",
"id": "monitoring.projects.notificationChannels.list",
"parameterOrder": [
"name"
],
"parameters": {
"filter": {
"description": "If provided, this field specifies the criteria that must be met by notification channels to be included in the response.For more details, see sorting and filtering.",
"location": "query",
"type": "string"
},
"name": {
"description": "The project on which to execute the request. The format is projects/[PROJECT_ID]. That is, this names the container in which to look for the notification channels; it does not name a specific channel. To query a specific channel by REST resource name, use the GetNotificationChannel operation.",
"location": "path",
"pattern": "^projects/[^/]+$",
"required": true,
"type": "string"
},
"orderBy": {
"description": "A comma-separated list of fields by which to sort the result. Supports the same set of fields as in filter. Entries can be prefixed with a minus sign to sort in descending rather than ascending order.For more details, see sorting and filtering.",
"location": "query",
"type": "string"
},
"pageSize": {
"description": "The maximum number of results to return in a single response. If not set to a positive number, a reasonable value will be chosen by the service.",
"format": "int32",
"location": "query",
"type": "integer"
},
"pageToken": {
"description": "If non-empty, page_token must contain a value returned as the next_page_token in a previous response to request the next set of results.",
"location": "query",
"type": "string"
}
},
"path": "v3/{+name}/notificationChannels",
"response": {
"$ref": "ListNotificationChannelsResponse"
},
"scopes": [
"https://www.googleapis.com/auth/cloud-platform",
"https://www.googleapis.com/auth/monitoring",
"https://www.googleapis.com/auth/monitoring.read"
]
},
"patch": {
"description": "Updates a notification channel. Fields not specified in the field mask remain unchanged.",
"flatPath": "v3/projects/{projectsId}/notificationChannels/{notificationChannelsId}",
"httpMethod": "PATCH",
"id": "monitoring.projects.notificationChannels.patch",
"parameterOrder": [
"name"
],
"parameters": {
"name": {
"description": "The full REST resource name for this channel. The syntax is:\nprojects/[PROJECT_ID]/notificationChannels/[CHANNEL_ID]\nThe [CHANNEL_ID] is automatically assigned by the server on creation.",
"location": "path",
"pattern": "^projects/[^/]+/notificationChannels/[^/]+$",
"required": true,
"type": "string"
},
"updateMask": {
"description": "The fields to update.",
"format": "google-fieldmask",
"location": "query",
"type": "string"
}
},
"path": "v3/{+name}",
"request": {
"$ref": "NotificationChannel"
},
"response": {
"$ref": "NotificationChannel"
},
"scopes": [
"https://www.googleapis.com/auth/cloud-platform",
"https://www.googleapis.com/auth/monitoring"
]
},
"sendVerificationCode": {
"description": "Causes a verification code to be delivered to the channel. The code can then be supplied in VerifyNotificationChannel to verify the channel.",
"flatPath": "v3/projects/{projectsId}/notificationChannels/{notificationChannelsId}:sendVerificationCode",
"httpMethod": "POST",
"id": "monitoring.projects.notificationChannels.sendVerificationCode",
"parameterOrder": [
"name"
],
"parameters": {
"name": {
"description": "The notification channel to which to send a verification code.",
"location": "path",
"pattern": "^projects/[^/]+/notificationChannels/[^/]+$",
"required": true,
"type": "string"
}
},
"path": "v3/{+name}:sendVerificationCode",
"request": {
"$ref": "SendNotificationChannelVerificationCodeRequest"
},
"response": {
"$ref": "Empty"
},
"scopes": [
"https://www.googleapis.com/auth/cloud-platform",
"https://www.googleapis.com/auth/monitoring"
]
},
"verify": {
"description": "Verifies a NotificationChannel by proving receipt of the code delivered to the channel as a result of calling SendNotificationChannelVerificationCode.",
"flatPath": "v3/projects/{projectsId}/notificationChannels/{notificationChannelsId}:verify",
"httpMethod": "POST",
"id": "monitoring.projects.notificationChannels.verify",
"parameterOrder": [
"name"
],
"parameters": {
"name": {
"description": "The notification channel to verify.",
"location": "path",
"pattern": "^projects/[^/]+/notificationChannels/[^/]+$",
"required": true,
"type": "string"
}
},
"path": "v3/{+name}:verify",
"request": {
"$ref": "VerifyNotificationChannelRequest"
},
"response": {
"$ref": "NotificationChannel"
},
"scopes": [
"https://www.googleapis.com/auth/cloud-platform",
"https://www.googleapis.com/auth/monitoring"
]
}
}
},
"timeSeries": {
"methods": {
"create": {
......@@ -737,7 +1236,7 @@
"type": "string"
},
"pageSize": {
"description": "A positive number that is the maximum number of results to return. When view field sets to FULL, it limits the number of Points server will return; if view field is HEADERS, it limits the number of TimeSeries server will return.",
"description": "A positive number that is the maximum number of results to return. If page_size is empty or more than 100,000 results, the effective page_size is 100,000 results. If view is set to FULL, this is the maximum number of Points returned. If view is set to HEADERS, this is the maximum number of TimeSeries returned.",
"format": "int32",
"location": "query",
"type": "integer"
......@@ -955,18 +1454,187 @@
"response": {
"$ref": "ListUptimeCheckIpsResponse"
},
"scopes": [
"https://www.googleapis.com/auth/cloud-platform",
"https://www.googleapis.com/auth/monitoring",
"https://www.googleapis.com/auth/monitoring.read"
]
"scopes": [
"https://www.googleapis.com/auth/cloud-platform",
"https://www.googleapis.com/auth/monitoring",
"https://www.googleapis.com/auth/monitoring.read"
]
}
}
}
},
"revision": "20180529",
"rootUrl": "https://monitoring.googleapis.com/",
"schemas": {
"Aggregation": {
"description": "Describes how to combine multiple time series to provide different views of the data. Aggregation consists of an alignment step on individual time series (alignment_period and per_series_aligner) followed by an optional reduction step of the data across the aligned time series (cross_series_reducer and group_by_fields). For more details, see Aggregation.",
"id": "Aggregation",
"properties": {
"alignmentPeriod": {
"description": "The alignment period for per-time series alignment. If present, alignmentPeriod must be at least 60 seconds. After per-time series alignment, each time series will contain data points only on the period boundaries. If perSeriesAligner is not specified or equals ALIGN_NONE, then this field is ignored. If perSeriesAligner is specified and does not equal ALIGN_NONE, then this field must be defined; otherwise an error is returned.",
"format": "google-duration",
"type": "string"
},
"crossSeriesReducer": {
"description": "The approach to be used to combine time series. Not all reducer functions may be applied to all time series, depending on the metric type and the value type of the original time series. Reduction may change the metric type of value type of the time series.Time series data must be aligned in order to perform cross-time series reduction. If crossSeriesReducer is specified, then perSeriesAligner must be specified and not equal ALIGN_NONE and alignmentPeriod must be specified; otherwise, an error is returned.",
"enum": [
"REDUCE_NONE",
"REDUCE_MEAN",
"REDUCE_MIN",
"REDUCE_MAX",
"REDUCE_SUM",
"REDUCE_STDDEV",
"REDUCE_COUNT",
"REDUCE_COUNT_TRUE",
"REDUCE_COUNT_FALSE",
"REDUCE_FRACTION_TRUE",
"REDUCE_PERCENTILE_99",
"REDUCE_PERCENTILE_95",
"REDUCE_PERCENTILE_50",
"REDUCE_PERCENTILE_05"
],
"enumDescriptions": [
"No cross-time series reduction. The output of the aligner is returned.",
"Reduce by computing the mean across time series for each alignment period. This reducer is valid for delta and gauge metrics with numeric or distribution values. The value type of the output is DOUBLE.",
"Reduce by computing the minimum across time series for each alignment period. This reducer is valid for delta and gauge metrics with numeric values. The value type of the output is the same as the value type of the input.",
"Reduce by computing the maximum across time series for each alignment period. This reducer is valid for delta and gauge metrics with numeric values. The value type of the output is the same as the value type of the input.",
"Reduce by computing the sum across time series for each alignment period. This reducer is valid for delta and gauge metrics with numeric and distribution values. The value type of the output is the same as the value type of the input.",
"Reduce by computing the standard deviation across time series for each alignment period. This reducer is valid for delta and gauge metrics with numeric or distribution values. The value type of the output is DOUBLE.",
"Reduce by computing the count of data points across time series for each alignment period. This reducer is valid for delta and gauge metrics of numeric, Boolean, distribution, and string value type. The value type of the output is INT64.",
"Reduce by computing the count of True-valued data points across time series for each alignment period. This reducer is valid for delta and gauge metrics of Boolean value type. The value type of the output is INT64.",
"Reduce by computing the count of False-valued data points across time series for each alignment period. This reducer is valid for delta and gauge metrics of Boolean value type. The value type of the output is INT64.",
"Reduce by computing the fraction of True-valued data points across time series for each alignment period. This reducer is valid for delta and gauge metrics of Boolean value type. The output value is in the range 0, 1 and has value type DOUBLE.",
"Reduce by computing 99th percentile of data points across time series for each alignment period. This reducer is valid for gauge and delta metrics of numeric and distribution type. The value of the output is DOUBLE",
"Reduce by computing 95th percentile of data points across time series for each alignment period. This reducer is valid for gauge and delta metrics of numeric and distribution type. The value of the output is DOUBLE",
"Reduce by computing 50th percentile of data points across time series for each alignment period. This reducer is valid for gauge and delta metrics of numeric and distribution type. The value of the output is DOUBLE",
"Reduce by computing 5th percentile of data points across time series for each alignment period. This reducer is valid for gauge and delta metrics of numeric and distribution type. The value of the output is DOUBLE"
],
"type": "string"
},
"groupByFields": {
"description": "The set of fields to preserve when crossSeriesReducer is specified. The groupByFields determine how the time series are partitioned into subsets prior to applying the aggregation function. Each subset contains time series that have the same value for each of the grouping fields. Each individual time series is a member of exactly one subset. The crossSeriesReducer is applied to each subset of time series. It is not possible to reduce across different resource types, so this field implicitly contains resource.type. Fields not specified in groupByFields are aggregated away. If groupByFields is not specified and all the time series have the same resource type, then the time series are aggregated into a single output time series. If crossSeriesReducer is not defined, this field is ignored.",
"items": {
"type": "string"
},
"type": "array"
},
"perSeriesAligner": {
"description": "The approach to be used to align individual time series. Not all alignment functions may be applied to all time series, depending on the metric type and value type of the original time series. Alignment may change the metric type or the value type of the time series.Time series data must be aligned in order to perform cross-time series reduction. If crossSeriesReducer is specified, then perSeriesAligner must be specified and not equal ALIGN_NONE and alignmentPeriod must be specified; otherwise, an error is returned.",
"enum": [
"ALIGN_NONE",
"ALIGN_DELTA",
"ALIGN_RATE",
"ALIGN_INTERPOLATE",
"ALIGN_NEXT_OLDER",
"ALIGN_MIN",
"ALIGN_MAX",
"ALIGN_MEAN",
"ALIGN_COUNT",
"ALIGN_SUM",
"ALIGN_STDDEV",
"ALIGN_COUNT_TRUE",
"ALIGN_COUNT_FALSE",
"ALIGN_FRACTION_TRUE",
"ALIGN_PERCENTILE_99",
"ALIGN_PERCENTILE_95",
"ALIGN_PERCENTILE_50",
"ALIGN_PERCENTILE_05",
"ALIGN_PERCENT_CHANGE"
],
"enumDescriptions": [
"No alignment. Raw data is returned. Not valid if cross-time series reduction is requested. The value type of the result is the same as the value type of the input.",
"Align and convert to delta metric type. This alignment is valid for cumulative metrics and delta metrics. Aligning an existing delta metric to a delta metric requires that the alignment period be increased. The value type of the result is the same as the value type of the input.One can think of this aligner as a rate but without time units; that is, the output is conceptually (second_point - first_point).",
"Align and convert to a rate. This alignment is valid for cumulative metrics and delta metrics with numeric values. The output is a gauge metric with value type DOUBLE.One can think of this aligner as conceptually providing the slope of the line that passes through the value at the start and end of the window. In other words, this is conceptually ((y1 - y0)/(t1 - t0)), and the output unit is one that has a \"/time\" dimension.If, by rate, you are looking for percentage change, see the ALIGN_PERCENT_CHANGE aligner option.",
"Align by interpolating between adjacent points around the period boundary. This alignment is valid for gauge metrics with numeric values. The value type of the result is the same as the value type of the input.",
"Align by shifting the oldest data point before the period boundary to the boundary. This alignment is valid for gauge metrics. The value type of the result is the same as the value type of the input.",
"Align time series via aggregation. The resulting data point in the alignment period is the minimum of all data points in the period. This alignment is valid for gauge and delta metrics with numeric values. The value type of the result is the same as the value type of the input.",
"Align time series via aggregation. The resulting data point in the alignment period is the maximum of all data points in the period. This alignment is valid for gauge and delta metrics with numeric values. The value type of the result is the same as the value type of the input.",
"Align time series via aggregation. The resulting data point in the alignment period is the average or arithmetic mean of all data points in the period. This alignment is valid for gauge and delta metrics with numeric values. The value type of the output is DOUBLE.",
"Align time series via aggregation. The resulting data point in the alignment period is the count of all data points in the period. This alignment is valid for gauge and delta metrics with numeric or Boolean values. The value type of the output is INT64.",
"Align time series via aggregation. The resulting data point in the alignment period is the sum of all data points in the period. This alignment is valid for gauge and delta metrics with numeric and distribution values. The value type of the output is the same as the value type of the input.",
"Align time series via aggregation. The resulting data point in the alignment period is the standard deviation of all data points in the period. This alignment is valid for gauge and delta metrics with numeric values. The value type of the output is DOUBLE.",
"Align time series via aggregation. The resulting data point in the alignment period is the count of True-valued data points in the period. This alignment is valid for gauge metrics with Boolean values. The value type of the output is INT64.",
"Align time series via aggregation. The resulting data point in the alignment period is the count of False-valued data points in the period. This alignment is valid for gauge metrics with Boolean values. The value type of the output is INT64.",
"Align time series via aggregation. The resulting data point in the alignment period is the fraction of True-valued data points in the period. This alignment is valid for gauge metrics with Boolean values. The output value is in the range 0, 1 and has value type DOUBLE.",
"Align time series via aggregation. The resulting data point in the alignment period is the 99th percentile of all data points in the period. This alignment is valid for gauge and delta metrics with distribution values. The output is a gauge metric with value type DOUBLE.",
"Align time series via aggregation. The resulting data point in the alignment period is the 95th percentile of all data points in the period. This alignment is valid for gauge and delta metrics with distribution values. The output is a gauge metric with value type DOUBLE.",
"Align time series via aggregation. The resulting data point in the alignment period is the 50th percentile of all data points in the period. This alignment is valid for gauge and delta metrics with distribution values. The output is a gauge metric with value type DOUBLE.",
"Align time series via aggregation. The resulting data point in the alignment period is the 5th percentile of all data points in the period. This alignment is valid for gauge and delta metrics with distribution values. The output is a gauge metric with value type DOUBLE.",
"Align and convert to a percentage change. This alignment is valid for gauge and delta metrics with numeric values. This alignment conceptually computes the equivalent of \"((current - previous)/previous)*100\" where previous value is determined based on the alignmentPeriod. In the event that previous is 0 the calculated value is infinity with the exception that if both (current - previous) and previous are 0 the calculated value is 0. A 10 minute moving mean is computed at each point of the time window prior to the above calculation to smooth the metric and prevent false positives from very short lived spikes. Only applicable for data that is \u003e= 0. Any values \u003c 0 are treated as no data. While delta metrics are accepted by this alignment special care should be taken that the values for the metric will always be positive. The output is a gauge metric with value type DOUBLE."
],
"type": "string"
}
},
"type": "object"
},
"AlertPolicy": {
"description": "A description of the conditions under which some aspect of your system is considered to be \"unhealthy\" and the ways to notify people or services about this state. For an overview of alert policies, see Introduction to Alerting.",
"id": "AlertPolicy",
"properties": {
"combiner": {
"description": "How to combine the results of multiple conditions to determine if an incident should be opened.",
"enum": [
"COMBINE_UNSPECIFIED",
"AND",
"OR",
"AND_WITH_MATCHING_RESOURCE"
],
"enumDescriptions": [
"An unspecified combiner.",
"Combine conditions using the logical AND operator. An incident is created only if all conditions are met simultaneously. This combiner is satisfied if all conditions are met, even if they are met on completely different resources.",
"Combine conditions using the logical OR operator. An incident is created if any of the listed conditions is met.",
"Combine conditions using logical AND operator, but unlike the regular AND option, an incident is created only if all conditions are met simultaneously on at least one resource."
],
"type": "string"
},
"conditions": {
"description": "A list of conditions for the policy. The conditions are combined by AND or OR according to the combiner field. If the combined conditions evaluate to true, then an incident is created. A policy can have from one to six conditions.",
"items": {
"$ref": "Condition"
},
"type": "array"
},
"creationRecord": {
"$ref": "MutationRecord",
"description": "A read-only record of the creation of the alerting policy. If provided in a call to create or update, this field will be ignored."
},
"displayName": {
"description": "A short name or phrase used to identify the policy in dashboards, notifications, and incidents. To avoid confusion, don't use the same display name for multiple policies in the same project. The name is limited to 512 Unicode characters.",
"type": "string"
},
"documentation": {
"$ref": "Documentation",
"description": "Documentation that is included with notifications and incidents related to this policy. Best practice is for the documentation to include information to help responders understand, mitigate, escalate, and correct the underlying problems detected by the alerting policy. Notification channels that have limited capacity might not show this documentation."
},
"enabled": {
"description": "Whether or not the policy is enabled. On write, the default interpretation if unset is that the policy is enabled. On read, clients should not make any assumption about the state if it has not been populated. The field should always be populated on List and Get operations, unless a field projection has been specified that strips it out.",
"type": "boolean"
},
"mutationRecord": {
"$ref": "MutationRecord",
"description": "A read-only record of the most recent change to the alerting policy. If provided in a call to create or update, this field will be ignored."
},
"name": {
"description": "Required if the policy exists. The resource name for this policy. The syntax is:\nprojects/[PROJECT_ID]/alertPolicies/[ALERT_POLICY_ID]\n[ALERT_POLICY_ID] is assigned by Stackdriver Monitoring when the policy is created. When calling the alertPolicies.create method, do not include the name field in the alerting policy passed as part of the request.",
"type": "string"
},
"notificationChannels": {
"description": "Identifies the notification channels to which notifications should be sent when incidents are opened or closed or when new violations occur on an already opened incident. Each element of this array corresponds to the name field in each of the NotificationChannel objects that are returned from the ListNotificationChannels method. The syntax of the entries in this field is:\nprojects/[PROJECT_ID]/notificationChannels/[CHANNEL_ID]\n",
"items": {
"type": "string"
},
"type": "array"
},
"userLabels": {
"additionalProperties": {
"type": "string"
},
"description": "User-supplied key/value data to be used for organizing and identifying the AlertPolicy objects.The field can contain up to 64 entries. Each key and value is limited to 63 Unicode characters or 128 bytes, whichever is smaller. Labels and values can contain only lowercase letters, numerals, underscores, and dashes. Keys must begin with a letter.",
"type": "object"
}
}
}
},
"revision": "20180225",
"rootUrl": "https://monitoring.googleapis.com/",
"schemas": {
},
"type": "object"
},
"BasicAuthentication": {
"description": "A type of authentication to perform against the specified resource or URL that uses username and password. Currently, only Basic authentication is supported in Uptime Monitoring.",
"id": "BasicAuthentication",
......@@ -1120,6 +1788,29 @@
},
"type": "object"
},
"Condition": {
"description": "A condition is a true/false test that determines when an alerting policy should open an incident. If a condition evaluates to true, it signifies that something is wrong.",
"id": "Condition",
"properties": {
"conditionAbsent": {
"$ref": "MetricAbsence",
"description": "A condition that checks that a time series continues to receive new data points."
},
"conditionThreshold": {
"$ref": "MetricThreshold",
"description": "A condition that compares a time series against a threshold."
},
"displayName": {
"description": "A short name or phrase used to identify the condition in dashboards, notifications, and incidents. To avoid confusion, don't use the same display name for multiple conditions in the same policy.",
"type": "string"
},
"name": {
"description": "Required if the condition exists. The unique resource name for this condition. Its syntax is:\nprojects/[PROJECT_ID]/alertPolicies/[POLICY_ID]/conditions/[CONDITION_ID]\n[CONDITION_ID] is assigned by Stackdriver Monitoring when the condition is created as part of a new or updated alerting policy.When calling the alertPolicies.create method, do not include the name field in the conditions of the requested alerting policy. Stackdriver Monitoring creates the condition identifiers and includes them in the new policy.When calling the alertPolicies.update method to update a policy, including a condition name causes the existing condition to be updated. Conditions without names are added to the updated policy. Existing conditions are deleted if they are not updated.Best practice is to preserve [CONDITION_ID] if you make only small changes, such as those to condition thresholds, durations, or trigger values. Otherwise, treat the change as a new condition and let the existing condition be deleted.",
"type": "string"
}
},
"type": "object"
},
"ContentMatcher": {
"description": "Used to perform string matching. Currently, this matches on the exact content. In the future, it can be expanded to allow for regular expressions and more complex matching.",
"id": "ContentMatcher",
......@@ -1202,6 +1893,13 @@
"format": "int64",
"type": "string"
},
"exemplars": {
"description": "Must be in increasing order of |value| field. The current requirement enforced by the backend is that at most one Exemplar will fall into any bucket.",
"items": {
"$ref": "Exemplar"
},
"type": "array"
},
"mean": {
"description": "The arithmetic mean of the values in the population. If count is zero then this field must be zero.",
"format": "double",
......@@ -1219,12 +1917,55 @@
},
"type": "object"
},
"Documentation": {
"description": "A content string and a MIME type that describes the content string's format.",
"id": "Documentation",
"properties": {
"content": {
"description": "The text of the documentation, interpreted according to mime_type. The content may not exceed 8,192 Unicode characters and may not exceed more than 10,240 bytes when encoded in UTF-8 format, whichever is smaller.",
"type": "string"
},
"mimeType": {
"description": "The format of the content field. Presently, only the value \"text/markdown\" is supported. See Markdown (https://en.wikipedia.org/wiki/Markdown) for more information.",
"type": "string"
}
},
"type": "object"
},
"Empty": {
"description": "A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance:\nservice Foo {\n rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty);\n}\nThe JSON representation for Empty is empty JSON object {}.",
"id": "Empty",
"properties": {},
"type": "object"
},
"Exemplar": {
"description": "Exemplars are example points that may be used to annotate aggregated distribution values. They are metadata that gives information about a particular value added to a Distribution bucket, such as a trace ID that was active when a value was added. They may contain further information, such as a example values and timestamps, origin, etc.",
"id": "Exemplar",
"properties": {
"attachments": {
"description": "Contextual information about the example value. Examples are:Trace ID: type.googleapis.com/google.devtools.cloudtrace.v1.TraceLiteral string: type.googleapis.com/google.protobuf.StringValueLabels dropped during aggregation: type.googleapis.com/google.monitoring.v3.DroppedLabelsThere may be only a single attachment of any given message type in a single exemplar, and this is enforced by the system.",
"items": {
"additionalProperties": {
"description": "Properties of the object. Contains field @type with type URL.",
"type": "any"
},
"type": "object"
},
"type": "array"
},
"timestamp": {
"description": "The observation (sampling) time of the above value.",
"format": "google-datetime",
"type": "string"
},
"value": {
"description": "Value of the exemplar point. This value determines to which bucket the exemplar belongs.",
"format": "double",
"type": "number"
}
},
"type": "object"
},
"Explicit": {
"description": "Specifies a set of buckets with arbitrary widths.There are size(bounds) + 1 (= N) buckets. Bucket i has the following boundaries:Upper bound (0 \u003c= i \u003c N-1): boundsi Lower bound (1 \u003c= i \u003c N); boundsi - 1The bounds field must contain at least one element. If bounds has only one element, then there are no finite buckets, and that single element is the common boundary of the overflow and underflow buckets.",
"id": "Explicit",
......@@ -1368,6 +2109,34 @@
},
"type": "object"
},
"GetNotificationChannelVerificationCodeRequest": {
"description": "The GetNotificationChannelVerificationCode request.",
"id": "GetNotificationChannelVerificationCodeRequest",
"properties": {
"expireTime": {
"description": "The desired expiration time. If specified, the API will guarantee that the returned code will not be valid after the specified timestamp; however, the API cannot guarantee that the returned code will be valid for at least as long as the requested time (the API puts an upper bound on the amount of time for which a code may be valid). If omitted, a default expiration will be used, which may be less than the max permissible expiration (so specifying an expiration may extend the code's lifetime over omitting an expiration, even though the API does impose an upper limit on the maximum expiration that is permitted).",
"format": "google-datetime",
"type": "string"
}
},
"type": "object"
},
"GetNotificationChannelVerificationCodeResponse": {
"description": "The GetNotificationChannelVerificationCode request.",
"id": "GetNotificationChannelVerificationCodeResponse",
"properties": {
"code": {
"description": "The verification code, which may be used to verify other channels that have an equivalent identity (i.e. other channels of the same type with the same fingerprint such as other email channels with the same email address or other sms channels with the same number).",
"type": "string"
},
"expireTime": {
"description": "The expiration time associated with the code that was returned. If an expiration was provided in the request, this is the minimum of the requested expiration in the request and the max permitted expiration.",
"format": "google-datetime",
"type": "string"
}
},
"type": "object"
},
"Group": {
"description": "The description of a dynamic collection of monitored resources. Each group has a filter that is matched against monitored resources and their associated metadata. If a group's filter matches an available monitored resource, then that resource is a member of that group. Groups can contain any number of monitored resources, and each monitored resource can be a member of any number of groups.Groups can be nested in parent-child hierarchies. The parentName field identifies an optional parent for each group. If a group has a parent, then the only monitored resources available to be matched by the group's filter are the resources contained in the parent group. In other words, a group contains the monitored resources that match its filter and the filters of all the group's ancestors. A group without a parent can contain any monitored resource.For example, consider an infrastructure running a set of instances with two user-defined tags: \"environment\" and \"role\". A parent group has a filter, environment=\"production\". A child of that parent group has a filter, role=\"transcoder\". The parent group contains all instances in the production environment, regardless of their roles. The child group contains instances that have the transcoder role and are in the production environment.The monitored resources contained in a group can change at any moment, depending on what resources exist and what filters are associated with the group and its ancestors.",
"id": "Group",
......@@ -1508,6 +2277,24 @@
},
"type": "object"
},
"ListAlertPoliciesResponse": {
"description": "The protocol for the ListAlertPolicies response.",
"id": "ListAlertPoliciesResponse",
"properties": {
"alertPolicies": {
"description": "The returned alert policies.",
"items": {
"$ref": "AlertPolicy"
},
"type": "array"
},
"nextPageToken": {
"description": "If there might be more results than were returned, then this field is set to a non-empty value. To see the additional results, use that value as pageToken in the next call to this method.",
"type": "string"
}
},
"type": "object"
},
"ListGroupMembersResponse": {
"description": "The ListGroupMembers response.",
"id": "ListGroupMembersResponse",
......@@ -1585,10 +2372,53 @@
},
"type": "object"
},
"ListNotificationChannelDescriptorsResponse": {
"description": "The ListNotificationChannelDescriptors response.",
"id": "ListNotificationChannelDescriptorsResponse",
"properties": {
"channelDescriptors": {
"description": "The monitored resource descriptors supported for the specified project, optionally filtered.",
"items": {
"$ref": "NotificationChannelDescriptor"
},
"type": "array"
},
"nextPageToken": {
"description": "If not empty, indicates that there may be more results that match the request. Use the value in the page_token field in a subsequent request to fetch the next set of results. If empty, all results have been returned.",
"type": "string"
}
},
"type": "object"
},
"ListNotificationChannelsResponse": {
"description": "The ListNotificationChannels response.",
"id": "ListNotificationChannelsResponse",
"properties": {
"nextPageToken": {
"description": "If not empty, indicates that there may be more results that match the request. Use the value in the page_token field in a subsequent request to fetch the next set of results. If empty, all results have been returned.",
"type": "string"
},
"notificationChannels": {
"description": "The notification channels defined for the specified project.",
"items": {
"$ref": "NotificationChannel"
},
"type": "array"
}
},
"type": "object"
},
"ListTimeSeriesResponse": {
"description": "The ListTimeSeries response.",
"id": "ListTimeSeriesResponse",
"properties": {
"executionErrors": {
"description": "Query execution errors that may have caused the time series data returned to be incomplete.",
"items": {
"$ref": "Status"
},
"type": "array"
},
"nextPageToken": {
"description": "If there are more results than have been returned, then this field is set to a non-empty value. To see the additional results, use that value as pageToken in the next call to this method.",
"type": "string"
......@@ -1662,6 +2492,33 @@
},
"type": "object"
},
"MetricAbsence": {
"description": "A condition type that checks that monitored resources are reporting data. The configuration defines a metric and a set of monitored resources. The predicate is considered in violation when a time series for the specified metric of a monitored resource does not include any data in the specified duration.",
"id": "MetricAbsence",
"properties": {
"aggregations": {
"description": "Specifies the alignment of data points in individual time series as well as how to combine the retrieved time series together (such as when aggregating multiple streams on each resource to a single stream for each resource or when aggregating streams across all members of a group of resrouces). Multiple aggregations are applied in the order specified.This field is similar to the one in the MetricService.ListTimeSeries request. It is advisable to use the ListTimeSeries method when debugging this field.",
"items": {
"$ref": "Aggregation"
},
"type": "array"
},
"duration": {
"description": "The amount of time that a time series must fail to report new data to be considered failing. Currently, only values that are a multiple of a minute--e.g. 60, 120, or 300 seconds--are supported. If an invalid value is given, an error will be returned. The Duration.nanos field is ignored.",
"format": "google-duration",
"type": "string"
},
"filter": {
"description": "A filter that identifies which time series should be compared with the threshold.The filter is similar to the one that is specified in the MetricService.ListTimeSeries request (that call is useful to verify the time series that will be retrieved / processed) and must specify the metric type and optionally may contain restrictions on resource type, resource labels, and metric labels. This field may not exceed 2048 Unicode characters in length.",
"type": "string"
},
"trigger": {
"$ref": "Trigger",
"description": "The number/percent of time series for which the comparison must hold in order for the condition to trigger. If unspecified, then the condition will trigger if the comparison is true for any of the time series that have been identified by filter and aggregations."
}
},
"type": "object"
},
"MetricDescriptor": {
"description": "Defines a metric type and its schema. Once a metric descriptor is created, deleting or altering it stops data collection and makes the metric type's existing data unusable.",
"id": "MetricDescriptor",
......@@ -1734,6 +2591,71 @@
},
"type": "object"
},
"MetricThreshold": {
"description": "A condition type that compares a collection of time series against a threshold.",
"id": "MetricThreshold",
"properties": {
"aggregations": {
"description": "Specifies the alignment of data points in individual time series as well as how to combine the retrieved time series together (such as when aggregating multiple streams on each resource to a single stream for each resource or when aggregating streams across all members of a group of resrouces). Multiple aggregations are applied in the order specified.This field is similar to the one in the MetricService.ListTimeSeries request. It is advisable to use the ListTimeSeries method when debugging this field.",
"items": {
"$ref": "Aggregation"
},
"type": "array"
},
"comparison": {
"description": "The comparison to apply between the time series (indicated by filter and aggregation) and the threshold (indicated by threshold_value). The comparison is applied on each time series, with the time series on the left-hand side and the threshold on the right-hand side.Only COMPARISON_LT and COMPARISON_GT are supported currently.",
"enum": [
"COMPARISON_UNSPECIFIED",
"COMPARISON_GT",
"COMPARISON_GE",
"COMPARISON_LT",
"COMPARISON_LE",
"COMPARISON_EQ",
"COMPARISON_NE"
],
"enumDescriptions": [
"No ordering relationship is specified.",
"The left argument is greater than the right argument.",
"The left argument is greater than or equal to the right argument.",
"The left argument is less than the right argument.",
"The left argument is less than or equal to the right argument.",
"The left argument is equal to the right argument.",
"The left argument is not equal to the right argument."
],
"type": "string"
},
"denominatorAggregations": {
"description": "Specifies the alignment of data points in individual time series selected by denominatorFilter as well as how to combine the retrieved time series together (such as when aggregating multiple streams on each resource to a single stream for each resource or when aggregating streams across all members of a group of resources).When computing ratios, the aggregations and denominator_aggregations fields must use the same alignment period and produce time series that have the same periodicity and labels.This field is similar to the one in the MetricService.ListTimeSeries request. It is advisable to use the ListTimeSeries method when debugging this field.",
"items": {
"$ref": "Aggregation"
},
"type": "array"
},
"denominatorFilter": {
"description": "A filter that identifies a time series that should be used as the denominator of a ratio that will be compared with the threshold. If a denominator_filter is specified, the time series specified by the filter field will be used as the numerator.The filter is similar to the one that is specified in the MetricService.ListTimeSeries request (that call is useful to verify the time series that will be retrieved / processed) and must specify the metric type and optionally may contain restrictions on resource type, resource labels, and metric labels. This field may not exceed 2048 Unicode characters in length.",
"type": "string"
},
"duration": {
"description": "The amount of time that a time series must violate the threshold to be considered failing. Currently, only values that are a multiple of a minute--e.g., 0, 60, 120, or 300 seconds--are supported. If an invalid value is given, an error will be returned. When choosing a duration, it is useful to keep in mind the frequency of the underlying time series data (which may also be affected by any alignments specified in the aggregations field); a good duration is long enough so that a single outlier does not generate spurious alerts, but short enough that unhealthy states are detected and alerted on quickly.",
"format": "google-duration",
"type": "string"
},
"filter": {
"description": "A filter that identifies which time series should be compared with the threshold.The filter is similar to the one that is specified in the MetricService.ListTimeSeries request (that call is useful to verify the time series that will be retrieved / processed) and must specify the metric type and optionally may contain restrictions on resource type, resource labels, and metric labels. This field may not exceed 2048 Unicode characters in length.",
"type": "string"
},
"thresholdValue": {
"description": "A value against which to compare the time series.",
"format": "double",
"type": "number"
},
"trigger": {
"$ref": "Trigger",
"description": "The number/percent of time series for which the comparison must hold in order for the condition to trigger. If unspecified, then the condition will trigger if the comparison is true for any of the time series that have been identified by filter and aggregations, or by the ratio, if denominator_filter and denominator_aggregations are specified."
}
},
"type": "object"
},
"MonitoredResource": {
"description": "An object representing a resource that can be used for monitoring, logging, billing, or other purposes. Examples include virtual machine instances, databases, and storage devices such as disks. The type field identifies a MonitoredResourceDescriptor object that describes the resource's schema. Information in the labels field identifies the actual resource and its attributes according to the schema. For example, a particular Compute Engine VM instance could be represented by the following object, because the MonitoredResourceDescriptor for \"gce_instance\" has labels \"instance_id\" and \"zone\":\n{ \"type\": \"gce_instance\",\n \"labels\": { \"instance_id\": \"12345678901234\",\n \"zone\": \"us-central1-a\" }}\n",
"id": "MonitoredResource",
......@@ -1804,6 +2726,124 @@
},
"type": "object"
},
"MutationRecord": {
"description": "Describes a change made to a configuration.",
"id": "MutationRecord",
"properties": {
"mutateTime": {
"description": "When the change occurred.",
"format": "google-datetime",
"type": "string"
},
"mutatedBy": {
"description": "The email address of the user making the change.",
"type": "string"
}
},
"type": "object"
},
"NotificationChannel": {
"description": "A NotificationChannel is a medium through which an alert is delivered when a policy violation is detected. Examples of channels include email, SMS, and third-party messaging applications. Fields containing sensitive information like authentication tokens or contact info are only partially populated on retrieval.",
"id": "NotificationChannel",
"properties": {
"description": {
"description": "An optional human-readable description of this notification channel. This description may provide additional details, beyond the display name, for the channel. This may not exceeed 1024 Unicode characters.",
"type": "string"
},
"displayName": {
"description": "An optional human-readable name for this notification channel. It is recommended that you specify a non-empty and unique name in order to make it easier to identify the channels in your project, though this is not enforced. The display name is limited to 512 Unicode characters.",
"type": "string"
},
"enabled": {
"description": "Whether notifications are forwarded to the described channel. This makes it possible to disable delivery of notifications to a particular channel without removing the channel from all alerting policies that reference the channel. This is a more convenient approach when the change is temporary and you want to receive notifications from the same set of alerting policies on the channel at some point in the future.",
"type": "boolean"
},
"labels": {
"additionalProperties": {
"type": "string"
},
"description": "Configuration fields that define the channel and its behavior. The permissible and required labels are specified in the NotificationChannelDescriptor.labels of the NotificationChannelDescriptor corresponding to the type field.",
"type": "object"
},
"name": {
"description": "The full REST resource name for this channel. The syntax is:\nprojects/[PROJECT_ID]/notificationChannels/[CHANNEL_ID]\nThe [CHANNEL_ID] is automatically assigned by the server on creation.",
"type": "string"
},
"type": {
"description": "The type of the notification channel. This field matches the value of the NotificationChannelDescriptor.type field.",
"type": "string"
},
"userLabels": {
"additionalProperties": {
"type": "string"
},
"description": "User-supplied key/value data that does not need to conform to the corresponding NotificationChannelDescriptor's schema, unlike the labels field. This field is intended to be used for organizing and identifying the NotificationChannel objects.The field can contain up to 64 entries. Each key and value is limited to 63 Unicode characters or 128 bytes, whichever is smaller. Labels and values can contain only lowercase letters, numerals, underscores, and dashes. Keys must begin with a letter.",
"type": "object"
},
"verificationStatus": {
"description": "Indicates whether this channel has been verified or not. On a ListNotificationChannels or GetNotificationChannel operation, this field is expected to be populated.If the value is UNVERIFIED, then it indicates that the channel is non-functioning (it both requires verification and lacks verification); otherwise, it is assumed that the channel works.If the channel is neither VERIFIED nor UNVERIFIED, it implies that the channel is of a type that does not require verification or that this specific channel has been exempted from verification because it was created prior to verification being required for channels of this type.This field cannot be modified using a standard UpdateNotificationChannel operation. To change the value of this field, you must call VerifyNotificationChannel.",
"enum": [
"VERIFICATION_STATUS_UNSPECIFIED",
"UNVERIFIED",
"VERIFIED"
],
"enumDescriptions": [
"Sentinel value used to indicate that the state is unknown, omitted, or is not applicable (as in the case of channels that neither support nor require verification in order to function).",
"The channel has yet to be verified and requires verification to function. Note that this state also applies to the case where the verification process has been initiated by sending a verification code but where the verification code has not been submitted to complete the process.",
"It has been proven that notifications can be received on this notification channel and that someone on the project has access to messages that are delivered to that channel."
],
"type": "string"
}
},
"type": "object"
},
"NotificationChannelDescriptor": {
"description": "A description of a notification channel. The descriptor includes the properties of the channel and the set of labels or fields that must be specified to configure channels of a given type.",
"id": "NotificationChannelDescriptor",
"properties": {
"description": {
"description": "A human-readable description of the notification channel type. The description may include a description of the properties of the channel and pointers to external documentation.",
"type": "string"
},
"displayName": {
"description": "A human-readable name for the notification channel type. This form of the name is suitable for a user interface.",
"type": "string"
},
"labels": {
"description": "The set of labels that must be defined to identify a particular channel of the corresponding type. Each label includes a description for how that field should be populated.",
"items": {
"$ref": "LabelDescriptor"
},
"type": "array"
},
"name": {
"description": "The full REST resource name for this descriptor. The syntax is:\nprojects/[PROJECT_ID]/notificationChannelDescriptors/[TYPE]\nIn the above, [TYPE] is the value of the type field.",
"type": "string"
},
"supportedTiers": {
"description": "The tiers that support this notification channel; the project service tier must be one of the supported_tiers.",
"enumDescriptions": [
"An invalid sentinel value, used to indicate that a tier has not been provided explicitly.",
"The Stackdriver Basic tier, a free tier of service that provides basic features, a moderate allotment of logs, and access to built-in metrics. A number of features are not available in this tier. For more details, see the service tiers documentation (https://cloud.google.com/monitoring/accounts/tiers).",
"The Stackdriver Premium tier, a higher, more expensive tier of service that provides access to all Stackdriver features, lets you use Stackdriver with AWS accounts, and has a larger allotments for logs and metrics. For more details, see the service tiers documentation (https://cloud.google.com/monitoring/accounts/tiers)."
],
"items": {
"enum": [
"SERVICE_TIER_UNSPECIFIED",
"SERVICE_TIER_BASIC",
"SERVICE_TIER_PREMIUM"
],
"type": "string"
},
"type": "array"
},
"type": {
"description": "The type of notification channel, such as \"email\", \"sms\", etc. Notification channel types are globally unique.",
"type": "string"
}
},
"type": "object"
},
"Option": {
"description": "A protocol buffer option, which can be attached to a message, field, enumeration, etc.",
"id": "Option",
......@@ -1880,6 +2920,12 @@
},
"type": "object"
},
"SendNotificationChannelVerificationCodeRequest": {
"description": "The SendNotificationChannelVerificationCode request.",
"id": "SendNotificationChannelVerificationCodeRequest",
"properties": {},
"type": "object"
},
"SourceContext": {
"description": "SourceContext represents information about the source of a protobuf element, like the file in which it is defined.",
"id": "SourceContext",
......@@ -2011,6 +3057,23 @@
},
"type": "object"
},
"Trigger": {
"description": "Specifies how many time series must fail a predicate to trigger a condition. If not specified, then a {count: 1} trigger is used.",
"id": "Trigger",
"properties": {
"count": {
"description": "The absolute number of time series that must fail the predicate for the condition to be triggered.",
"format": "int32",
"type": "integer"
},
"percent": {
"description": "The percentage of time series that must fail the predicate for the condition to be triggered.",
"format": "double",
"type": "number"
}
},
"type": "object"
},
"Type": {
"description": "A protocol buffer message type.",
"id": "Type",
......@@ -2127,7 +3190,7 @@
"type": "string"
},
"period": {
"description": "How often, in seconds, the uptime check is performed. Currently, the only supported values are 60s (1 minute), 300s (5 minutes), 600s (10 minutes), and 900s (15 minutes). Required.",
"description": "How often, in seconds, the uptime check is performed. Currently, the only supported values are 60s (1 minute), 300s (5 minutes), 600s (10 minutes), and 900s (15 minutes). Optional, defaults to 300s.",
"format": "google-duration",
"type": "string"
},
......@@ -2200,6 +3263,17 @@
}
},
"type": "object"
},
"VerifyNotificationChannelRequest": {
"description": "The VerifyNotificationChannel request.",
"id": "VerifyNotificationChannelRequest",
"properties": {
"code": {
"description": "The verification code that was delivered to the channel as a result of invoking the SendNotificationChannelVerificationCode API method or that was retrieved from a verified channel via GetNotificationChannelVerificationCode. For example, one might have \"G-123456\" or \"TKNZGhhd2EyN3I1MnRnMjRv\" (in general, one is only guaranteed that the code is valid UTF-8; one should not make any assumptions regarding the structure or format of the code).",
"type": "string"
}
},
"type": "object"
}
},
"servicePath": "",
......
This source diff could not be displayed because it is too large. You can view the blob instead.
......@@ -122,7 +122,7 @@
"snapshots": {
"methods": {
"create": {
"description": "Creates a snapshot from the requested subscription.\nIf the snapshot already exists, returns `ALREADY_EXISTS`.\nIf the requested subscription doesn't exist, returns `NOT_FOUND`.\nIf the backlog in the subscription is too old -- and the resulting snapshot\nwould expire in less than 1 hour -- then `FAILED_PRECONDITION` is returned.\nSee also the `Snapshot.expire_time` field.\n\nIf the name is not provided in the request, the server will assign a random\nname for this snapshot on the same project as the subscription, conforming\nto the\n[resource name\nformat](https://cloud.google.com/pubsub/docs/overview#names). The generated\nname is populated in the returned Snapshot object. Note that for REST API\nrequests, you must specify a name in the request.",
"description": "Creates a snapshot from the requested subscription.\u003cbr\u003e\u003cbr\u003e\n\u003cb\u003eALPHA:\u003c/b\u003e This feature is part of an alpha release. This API might be\nchanged in backward-incompatible ways and is not recommended for production\nuse. It is not subject to any SLA or deprecation policy.\nIf the snapshot already exists, returns `ALREADY_EXISTS`.\nIf the requested subscription doesn't exist, returns `NOT_FOUND`.\nIf the backlog in the subscription is too old -- and the resulting snapshot\nwould expire in less than 1 hour -- then `FAILED_PRECONDITION` is returned.\nSee also the `Snapshot.expire_time` field. If the name is not provided in\nthe request, the server will assign a random\nname for this snapshot on the same project as the subscription, conforming\nto the [resource name format](https://cloud.google.com/pubsub/docs/overview#names).\nThe generated\nname is populated in the returned Snapshot object. Note that for REST API\nrequests, you must specify a name in the request.",
"flatPath": "v1/projects/{projectsId}/snapshots/{snapshotsId}",
"httpMethod": "PUT",
"id": "pubsub.projects.snapshots.create",
......@@ -151,7 +151,7 @@
]
},
"delete": {
"description": "Removes an existing snapshot. All messages retained in the snapshot\nare immediately dropped. After a snapshot is deleted, a new one may be\ncreated with the same name, but the new one has no association with the old\nsnapshot or its subscription, unless the same subscription is specified.",
"description": "Removes an existing snapshot. \u003cbr\u003e\u003cbr\u003e\n\u003cb\u003eALPHA:\u003c/b\u003e This feature is part of an alpha release. This API might be\nchanged in backward-incompatible ways and is not recommended for production\nuse. It is not subject to any SLA or deprecation policy.\nWhen the snapshot is deleted, all messages retained in the snapshot\nare immediately dropped. After a snapshot is deleted, a new one may be\ncreated with the same name, but the new one has no association with the old\nsnapshot or its subscription, unless the same subscription is specified.",
"flatPath": "v1/projects/{projectsId}/snapshots/{snapshotsId}",
"httpMethod": "DELETE",
"id": "pubsub.projects.snapshots.delete",
......@@ -177,7 +177,7 @@
]
},
"get": {
"description": "Gets the configuration details of a snapshot.",
"description": "Gets the configuration details of a snapshot.\u003cbr\u003e\u003cbr\u003e\n\u003cb\u003eALPHA:\u003c/b\u003e This feature is part of an alpha release. This API might be\nchanged in backward-incompatible ways and is not recommended for production\nuse. It is not subject to any SLA or deprecation policy.",
"flatPath": "v1/projects/{projectsId}/snapshots/{snapshotsId}",
"httpMethod": "GET",
"id": "pubsub.projects.snapshots.get",
......@@ -229,7 +229,7 @@
]
},
"list": {
"description": "Lists the existing snapshots.",
"description": "Lists the existing snapshots.\u003cbr\u003e\u003cbr\u003e\n\u003cb\u003eALPHA:\u003c/b\u003e This feature is part of an alpha release. This API might be\nchanged in backward-incompatible ways and is not recommended for production\nuse. It is not subject to any SLA or deprecation policy.",
"flatPath": "v1/projects/{projectsId}/snapshots",
"httpMethod": "GET",
"id": "pubsub.projects.snapshots.list",
......@@ -266,7 +266,7 @@
]
},
"patch": {
"description": "Updates an existing snapshot. Note that certain properties of a\nsnapshot are not modifiable.",
"description": "Updates an existing snapshot.\u003cbr\u003e\u003cbr\u003e\n\u003cb\u003eALPHA:\u003c/b\u003e This feature is part of an alpha release. This API might be\nchanged in backward-incompatible ways and is not recommended for production\nuse. It is not subject to any SLA or deprecation policy.\nNote that certain properties of a snapshot are not modifiable.",
"flatPath": "v1/projects/{projectsId}/snapshots/{snapshotsId}",
"httpMethod": "PATCH",
"id": "pubsub.projects.snapshots.patch",
......@@ -386,7 +386,7 @@
]
},
"create": {
"description": "Creates a subscription to a given topic.\nIf the subscription already exists, returns `ALREADY_EXISTS`.\nIf the corresponding topic doesn't exist, returns `NOT_FOUND`.\n\nIf the name is not provided in the request, the server will assign a random\nname for this subscription on the same project as the topic, conforming\nto the\n[resource name format](https://cloud.google.com/pubsub/docs/overview#names).\nThe generated name is populated in the returned Subscription object.\nNote that for REST API requests, you must specify a name in the request.",
"description": "Creates a subscription to a given topic. See the\n\u003ca href=\"/pubsub/docs/admin#resource_names\"\u003e resource name rules\u003c/a\u003e.\nIf the subscription already exists, returns `ALREADY_EXISTS`.\nIf the corresponding topic doesn't exist, returns `NOT_FOUND`.\n\nIf the name is not provided in the request, the server will assign a random\nname for this subscription on the same project as the topic, conforming\nto the\n[resource name format](https://cloud.google.com/pubsub/docs/overview#names).\nThe generated name is populated in the returned Subscription object.\nNote that for REST API requests, you must specify a name in the request.",
"flatPath": "v1/projects/{projectsId}/subscriptions/{subscriptionsId}",
"httpMethod": "PUT",
"id": "pubsub.projects.subscriptions.create",
......@@ -646,7 +646,7 @@
]
},
"seek": {
"description": "Seeks an existing subscription to a point in time or to a given snapshot,\nwhichever is provided in the request.",
"description": "Seeks an existing subscription to a point in time or to a given snapshot,\nwhichever is provided in the request.\u003cbr\u003e\u003cbr\u003e\n\u003cb\u003eALPHA:\u003c/b\u003e This feature is part of an alpha release. This API might be\nchanged in backward-incompatible ways and is not recommended for production\nuse. It is not subject to any SLA or deprecation policy.",
"flatPath": "v1/projects/{projectsId}/subscriptions/{subscriptionsId}:seek",
"httpMethod": "POST",
"id": "pubsub.projects.subscriptions.seek",
......@@ -737,7 +737,7 @@
"topics": {
"methods": {
"create": {
"description": "Creates the given topic with the given name.",
"description": "Creates the given topic with the given name. See the\n\u003ca href=\"/pubsub/docs/admin#resource_names\"\u003e resource name rules\u003c/a\u003e.",
"flatPath": "v1/projects/{projectsId}/topics/{topicsId}",
"httpMethod": "PUT",
"id": "pubsub.projects.topics.create",
......@@ -972,7 +972,7 @@
"snapshots": {
"methods": {
"list": {
"description": "Lists the names of the snapshots on this topic.",
"description": "Lists the names of the snapshots on this topic.\u003cbr\u003e\u003cbr\u003e\n\u003cb\u003eALPHA:\u003c/b\u003e This feature is part of an alpha release. This API might be\nchanged in backward-incompatible ways and is not recommended for production\nuse. It is not subject to any SLA or deprecation policy.",
"flatPath": "v1/projects/{projectsId}/topics/{topicsId}/snapshots",
"httpMethod": "GET",
"id": "pubsub.projects.topics.snapshots.list",
......@@ -1056,7 +1056,7 @@
}
}
},
"revision": "20180129",
"revision": "20180522",
"rootUrl": "https://pubsub.googleapis.com/",
"schemas": {
"AcknowledgeRequest": {
......@@ -1078,7 +1078,7 @@
"id": "Binding",
"properties": {
"members": {
"description": "Specifies the identities requesting access for a Cloud Platform resource.\n`members` can have the following values:\n\n* `allUsers`: A special identifier that represents anyone who is\n on the internet; with or without a Google account.\n\n* `allAuthenticatedUsers`: A special identifier that represents anyone\n who is authenticated with a Google account or a service account.\n\n* `user:{emailid}`: An email address that represents a specific Google\n account. For example, `alice@gmail.com` or `joe@example.com`.\n\n\n* `serviceAccount:{emailid}`: An email address that represents a service\n account. For example, `my-other-app@appspot.gserviceaccount.com`.\n\n* `group:{emailid}`: An email address that represents a Google group.\n For example, `admins@example.com`.\n\n\n* `domain:{domain}`: A Google Apps domain name that represents all the\n users of that domain. For example, `google.com` or `example.com`.\n\n",
"description": "Specifies the identities requesting access for a Cloud Platform resource.\n`members` can have the following values:\n\n* `allUsers`: A special identifier that represents anyone who is\n on the internet; with or without a Google account.\n\n* `allAuthenticatedUsers`: A special identifier that represents anyone\n who is authenticated with a Google account or a service account.\n\n* `user:{emailid}`: An email address that represents a specific Google\n account. For example, `alice@gmail.com` .\n\n\n* `serviceAccount:{emailid}`: An email address that represents a service\n account. For example, `my-other-app@appspot.gserviceaccount.com`.\n\n* `group:{emailid}`: An email address that represents a Google group.\n For example, `admins@example.com`.\n\n\n* `domain:{domain}`: A Google Apps domain name that represents all the\n users of that domain. For example, `google.com` or `example.com`.\n\n",
"items": {
"type": "string"
},
......@@ -1092,7 +1092,7 @@
"type": "object"
},
"CreateSnapshotRequest": {
"description": "Request for the `CreateSnapshot` method.",
"description": "Request for the `CreateSnapshot` method.\u003cbr\u003e\u003cbr\u003e\n\u003cb\u003eALPHA:\u003c/b\u003e This feature is part of an alpha release. This API might be changed in\nbackward-incompatible ways and is not recommended for production use.\nIt is not subject to any SLA or deprecation policy.",
"id": "CreateSnapshotRequest",
"properties": {
"subscription": {
......@@ -1109,7 +1109,7 @@
"type": "object"
},
"ListSnapshotsResponse": {
"description": "Response for the `ListSnapshots` method.",
"description": "Response for the `ListSnapshots` method.\u003cbr\u003e\u003cbr\u003e\n\u003cb\u003eALPHA:\u003c/b\u003e This feature is part of an alpha release. This API might be\nchanged in backward-incompatible ways and is not recommended for production\nuse. It is not subject to any SLA or deprecation policy.",
"id": "ListSnapshotsResponse",
"properties": {
"nextPageToken": {
......@@ -1145,7 +1145,7 @@
"type": "object"
},
"ListTopicSnapshotsResponse": {
"description": "Response for the `ListTopicSnapshots` method.",
"description": "Response for the `ListTopicSnapshots` method.\u003cbr\u003e\u003cbr\u003e\n\u003cb\u003eALPHA:\u003c/b\u003e This feature is part of an alpha release. This API might be\nchanged in backward-incompatible ways and is not recommended for production\nuse. It is not subject to any SLA or deprecation policy.",
"id": "ListTopicSnapshotsResponse",
"properties": {
"nextPageToken": {
......@@ -1229,7 +1229,7 @@
"type": "object"
},
"Policy": {
"description": "Defines an Identity and Access Management (IAM) policy. It is used to\nspecify access control policies for Cloud Platform resources.\n\n\nA `Policy` consists of a list of `bindings`. A `Binding` binds a list of\n`members` to a `role`, where the members can be user accounts, Google groups,\nGoogle domains, and service accounts. A `role` is a named list of permissions\ndefined by IAM.\n\n**Example**\n\n {\n \"bindings\": [\n {\n \"role\": \"roles/owner\",\n \"members\": [\n \"user:mike@example.com\",\n \"group:admins@example.com\",\n \"domain:google.com\",\n \"serviceAccount:my-other-app@appspot.gserviceaccount.com\",\n ]\n },\n {\n \"role\": \"roles/viewer\",\n \"members\": [\"user:sean@example.com\"]\n }\n ]\n }\n\nFor a description of IAM and its features, see the\n[IAM developer's guide](https://cloud.google.com/iam/docs).",
"description": "Defines an Identity and Access Management (IAM) policy. It is used to\nspecify access control policies for Cloud Platform resources.\n\n\nA `Policy` consists of a list of `bindings`. A `binding` binds a list of\n`members` to a `role`, where the members can be user accounts, Google groups,\nGoogle domains, and service accounts. A `role` is a named list of permissions\ndefined by IAM.\n\n**JSON Example**\n\n {\n \"bindings\": [\n {\n \"role\": \"roles/owner\",\n \"members\": [\n \"user:mike@example.com\",\n \"group:admins@example.com\",\n \"domain:google.com\",\n \"serviceAccount:my-other-app@appspot.gserviceaccount.com\"\n ]\n },\n {\n \"role\": \"roles/viewer\",\n \"members\": [\"user:sean@example.com\"]\n }\n ]\n }\n\n**YAML Example**\n\n bindings:\n - members:\n - user:mike@example.com\n - group:admins@example.com\n - domain:google.com\n - serviceAccount:my-other-app@appspot.gserviceaccount.com\n role: roles/owner\n - members:\n - user:sean@example.com\n role: roles/viewer\n\n\nFor a description of IAM and its features, see the\n[IAM developer's guide](https://cloud.google.com/iam/docs).",
"id": "Policy",
"properties": {
"bindings": {
......@@ -1372,7 +1372,7 @@
"type": "object"
},
"SeekRequest": {
"description": "Request for the `Seek` method.",
"description": "Request for the `Seek` method.\u003cbr\u003e\u003cbr\u003e\n\u003cb\u003eALPHA:\u003c/b\u003e This feature is part of an alpha release. This API might be\nchanged in backward-incompatible ways and is not recommended for production\nuse. It is not subject to any SLA or deprecation policy.",
"id": "SeekRequest",
"properties": {
"snapshot": {
......@@ -1404,7 +1404,7 @@
"type": "object"
},
"Snapshot": {
"description": "A snapshot resource.",
"description": "A snapshot resource.\u003cbr\u003e\u003cbr\u003e\n\u003cb\u003eALPHA:\u003c/b\u003e This feature is part of an alpha release. This API might be\nchanged in backward-incompatible ways and is not recommended for production\nuse. It is not subject to any SLA or deprecation policy.",
"id": "Snapshot",
"properties": {
"expireTime": {
......@@ -1433,7 +1433,7 @@
"type": "integer"
},
"messageRetentionDuration": {
"description": "How long to retain unacknowledged messages in the subscription's backlog,\nfrom the moment a message is published.\nIf `retain_acked_messages` is true, then this also configures the retention\nof acknowledged messages, and thus configures how far back in time a `Seek`\ncan be done. Defaults to 7 days. Cannot be more than 7 days or less than 10\nminutes.",
"description": "How long to retain unacknowledged messages in the subscription's backlog,\nfrom the moment a message is published.\nIf `retain_acked_messages` is true, then this also configures the retention\nof acknowledged messages, and thus configures how far back in time a `Seek`\ncan be done. Defaults to 7 days. Cannot be more than 7 days or less than 10\nminutes.\u003cbr\u003e\u003cbr\u003e\n\u003cb\u003eALPHA:\u003c/b\u003e This feature is part of an alpha release. This API might be\nchanged in backward-incompatible ways and is not recommended for production\nuse. It is not subject to any SLA or deprecation policy.",
"format": "google-duration",
"type": "string"
},
......@@ -1446,7 +1446,7 @@
"description": "If push delivery is used with this subscription, this field is\nused to configure it. An empty `pushConfig` signifies that the subscriber\nwill pull and ack messages using API methods."
},
"retainAckedMessages": {
"description": "Indicates whether to retain acknowledged messages. If true, then\nmessages are not expunged from the subscription's backlog, even if they are\nacknowledged, until they fall out of the `message_retention_duration`\nwindow.",
"description": "Indicates whether to retain acknowledged messages. If true, then\nmessages are not expunged from the subscription's backlog, even if they are\nacknowledged, until they fall out of the `message_retention_duration`\nwindow.\u003cbr\u003e\u003cbr\u003e\n\u003cb\u003eALPHA:\u003c/b\u003e This feature is part of an alpha release. This API might be\nchanged in backward-incompatible ways and is not recommended for production\nuse. It is not subject to any SLA or deprecation policy.",
"type": "boolean"
},
"topic": {
......@@ -1496,12 +1496,12 @@
"type": "object"
},
"UpdateSnapshotRequest": {
"description": "Request for the UpdateSnapshot method.",
"description": "Request for the UpdateSnapshot method.\u003cbr\u003e\u003cbr\u003e\n\u003cb\u003eALPHA:\u003c/b\u003e This feature is part of an alpha release. This API might be\nchanged in backward-incompatible ways and is not recommended for production\nuse. It is not subject to any SLA or deprecation policy.",
"id": "UpdateSnapshotRequest",
"properties": {
"snapshot": {
"$ref": "Snapshot",
"description": "The updated snpashot object."
"description": "The updated snapshot object."
},
"updateMask": {
"description": "Indicates which fields in the provided snapshot to update.\nMust be specified and non-empty.",
......@@ -1529,6 +1529,6 @@
}
},
"servicePath": "",
"title": "Google Cloud Pub/Sub API",
"title": "Cloud Pub/Sub API",
"version": "v1"
}
\ No newline at end of file
// Package pubsub provides access to the Google Cloud Pub/Sub API.
// Package pubsub provides access to the Cloud Pub/Sub API.
//
// See https://cloud.google.com/pubsub/docs
//
......@@ -193,7 +193,7 @@ type Binding struct {
//
// * `user:{emailid}`: An email address that represents a specific
// Google
// account. For example, `alice@gmail.com` or `joe@example.com`.
// account. For example, `alice@gmail.com` .
//
//
// * `serviceAccount:{emailid}`: An email address that represents a
......@@ -243,7 +243,13 @@ func (s *Binding) MarshalJSON() ([]byte, error) {
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
// CreateSnapshotRequest: Request for the `CreateSnapshot` method.
// CreateSnapshotRequest: Request for the `CreateSnapshot`
// method.<br><br>
// <b>ALPHA:</b> This feature is part of an alpha release. This API
// might be changed in
// backward-incompatible ways and is not recommended for production
// use.
// It is not subject to any SLA or deprecation policy.
type CreateSnapshotRequest struct {
// Subscription: The subscription whose backlog the snapshot
// retains.
......@@ -300,7 +306,13 @@ type Empty struct {
googleapi.ServerResponse `json:"-"`
}
// ListSnapshotsResponse: Response for the `ListSnapshots` method.
// ListSnapshotsResponse: Response for the `ListSnapshots`
// method.<br><br>
// <b>ALPHA:</b> This feature is part of an alpha release. This API
// might be
// changed in backward-incompatible ways and is not recommended for
// production
// use. It is not subject to any SLA or deprecation policy.
type ListSnapshotsResponse struct {
// NextPageToken: If not empty, indicates that there may be more
// snapshot that match the
......@@ -378,7 +390,12 @@ func (s *ListSubscriptionsResponse) MarshalJSON() ([]byte, error) {
}
// ListTopicSnapshotsResponse: Response for the `ListTopicSnapshots`
// method.
// method.<br><br>
// <b>ALPHA:</b> This feature is part of an alpha release. This API
// might be
// changed in backward-incompatible ways and is not recommended for
// production
// use. It is not subject to any SLA or deprecation policy.
type ListTopicSnapshotsResponse struct {
// NextPageToken: If not empty, indicates that there may be more
// snapshots that match
......@@ -573,7 +590,7 @@ func (s *ModifyPushConfigRequest) MarshalJSON() ([]byte, error) {
// specify access control policies for Cloud Platform resources.
//
//
// A `Policy` consists of a list of `bindings`. A `Binding` binds a list
// A `Policy` consists of a list of `bindings`. A `binding` binds a list
// of
// `members` to a `role`, where the members can be user accounts, Google
// groups,
......@@ -581,7 +598,7 @@ func (s *ModifyPushConfigRequest) MarshalJSON() ([]byte, error) {
// permissions
// defined by IAM.
//
// **Example**
// **JSON Example**
//
// {
// "bindings": [
......@@ -592,7 +609,7 @@ func (s *ModifyPushConfigRequest) MarshalJSON() ([]byte, error) {
// "group:admins@example.com",
// "domain:google.com",
//
// "serviceAccount:my-other-app@appspot.gserviceaccount.com",
// "serviceAccount:my-other-app@appspot.gserviceaccount.com"
// ]
// },
// {
......@@ -602,6 +619,20 @@ func (s *ModifyPushConfigRequest) MarshalJSON() ([]byte, error) {
// ]
// }
//
// **YAML Example**
//
// bindings:
// - members:
// - user:mike@example.com
// - group:admins@example.com
// - domain:google.com
// - serviceAccount:my-other-app@appspot.gserviceaccount.com
// role: roles/owner
// - members:
// - user:sean@example.com
// role: roles/viewer
//
//
// For a description of IAM and its features, see the
// [IAM developer's guide](https://cloud.google.com/iam/docs).
type Policy struct {
......@@ -951,7 +982,12 @@ func (s *ReceivedMessage) MarshalJSON() ([]byte, error) {
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
// SeekRequest: Request for the `Seek` method.
// SeekRequest: Request for the `Seek` method.<br><br>
// <b>ALPHA:</b> This feature is part of an alpha release. This API
// might be
// changed in backward-incompatible ways and is not recommended for
// production
// use. It is not subject to any SLA or deprecation policy.
type SeekRequest struct {
// Snapshot: The snapshot to seek to. The snapshot's topic must be the
// same as that of
......@@ -1042,7 +1078,12 @@ func (s *SetIamPolicyRequest) MarshalJSON() ([]byte, error) {
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
// Snapshot: A snapshot resource.
// Snapshot: A snapshot resource.<br><br>
// <b>ALPHA:</b> This feature is part of an alpha release. This API
// might be
// changed in backward-incompatible ways and is not recommended for
// production
// use. It is not subject to any SLA or deprecation policy.
type Snapshot struct {
// ExpireTime: The snapshot is guaranteed to exist up until this time.
// A newly-created snapshot expires no later than 7 days from the time
......@@ -1141,7 +1182,12 @@ type Subscription struct {
// `Seek`
// can be done. Defaults to 7 days. Cannot be more than 7 days or less
// than 10
// minutes.
// minutes.<br><br>
// <b>ALPHA:</b> This feature is part of an alpha release. This API
// might be
// changed in backward-incompatible ways and is not recommended for
// production
// use. It is not subject to any SLA or deprecation policy.
MessageRetentionDuration string `json:"messageRetentionDuration,omitempty"`
// Name: The name of the subscription. It must have the
......@@ -1170,7 +1216,12 @@ type Subscription struct {
// they are
// acknowledged, until they fall out of the
// `message_retention_duration`
// window.
// window.<br><br>
// <b>ALPHA:</b> This feature is part of an alpha release. This API
// might be
// changed in backward-incompatible ways and is not recommended for
// production
// use. It is not subject to any SLA or deprecation policy.
RetainAckedMessages bool `json:"retainAckedMessages,omitempty"`
// Topic: The name of the topic from which this subscription is
......@@ -1321,9 +1372,15 @@ func (s *Topic) MarshalJSON() ([]byte, error) {
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
// UpdateSnapshotRequest: Request for the UpdateSnapshot method.
// UpdateSnapshotRequest: Request for the UpdateSnapshot
// method.<br><br>
// <b>ALPHA:</b> This feature is part of an alpha release. This API
// might be
// changed in backward-incompatible ways and is not recommended for
// production
// use. It is not subject to any SLA or deprecation policy.
type UpdateSnapshotRequest struct {
// Snapshot: The updated snpashot object.
// Snapshot: The updated snapshot object.
Snapshot *Snapshot `json:"snapshot,omitempty"`
// UpdateMask: Indicates which fields in the provided snapshot to
......@@ -1398,24 +1455,27 @@ type ProjectsSnapshotsCreateCall struct {
header_ http.Header
}
// Create: Creates a snapshot from the requested subscription.
// Create: Creates a snapshot from the requested
// subscription.<br><br>
// <b>ALPHA:</b> This feature is part of an alpha release. This API
// might be
// changed in backward-incompatible ways and is not recommended for
// production
// use. It is not subject to any SLA or deprecation policy.
// If the snapshot already exists, returns `ALREADY_EXISTS`.
// If the requested subscription doesn't exist, returns `NOT_FOUND`.
// If the backlog in the subscription is too old -- and the resulting
// snapshot
// would expire in less than 1 hour -- then `FAILED_PRECONDITION` is
// returned.
// See also the `Snapshot.expire_time` field.
//
// If the name is not provided in the request, the server will assign a
// random
// See also the `Snapshot.expire_time` field. If the name is not
// provided in
// the request, the server will assign a random
// name for this snapshot on the same project as the subscription,
// conforming
// to the
// [resource
// name
// format](https://cloud.google.com/pubsub/docs/overview#names). The
// generated
// to the [resource name
// format](https://cloud.google.com/pubsub/docs/overview#names).
// The generated
// name is populated in the returned Snapshot object. Note that for REST
// API
// requests, you must specify a name in the request.
......@@ -1512,7 +1572,7 @@ func (c *ProjectsSnapshotsCreateCall) Do(opts ...googleapi.CallOption) (*Snapsho
}
return ret, nil
// {
// "description": "Creates a snapshot from the requested subscription.\nIf the snapshot already exists, returns `ALREADY_EXISTS`.\nIf the requested subscription doesn't exist, returns `NOT_FOUND`.\nIf the backlog in the subscription is too old -- and the resulting snapshot\nwould expire in less than 1 hour -- then `FAILED_PRECONDITION` is returned.\nSee also the `Snapshot.expire_time` field.\n\nIf the name is not provided in the request, the server will assign a random\nname for this snapshot on the same project as the subscription, conforming\nto the\n[resource name\nformat](https://cloud.google.com/pubsub/docs/overview#names). The generated\nname is populated in the returned Snapshot object. Note that for REST API\nrequests, you must specify a name in the request.",
// "description": "Creates a snapshot from the requested subscription.\u003cbr\u003e\u003cbr\u003e\n\u003cb\u003eALPHA:\u003c/b\u003e This feature is part of an alpha release. This API might be\nchanged in backward-incompatible ways and is not recommended for production\nuse. It is not subject to any SLA or deprecation policy.\nIf the snapshot already exists, returns `ALREADY_EXISTS`.\nIf the requested subscription doesn't exist, returns `NOT_FOUND`.\nIf the backlog in the subscription is too old -- and the resulting snapshot\nwould expire in less than 1 hour -- then `FAILED_PRECONDITION` is returned.\nSee also the `Snapshot.expire_time` field. If the name is not provided in\nthe request, the server will assign a random\nname for this snapshot on the same project as the subscription, conforming\nto the [resource name format](https://cloud.google.com/pubsub/docs/overview#names).\nThe generated\nname is populated in the returned Snapshot object. Note that for REST API\nrequests, you must specify a name in the request.",
// "flatPath": "v1/projects/{projectsId}/snapshots/{snapshotsId}",
// "httpMethod": "PUT",
// "id": "pubsub.projects.snapshots.create",
......@@ -1553,7 +1613,13 @@ type ProjectsSnapshotsDeleteCall struct {
header_ http.Header
}
// Delete: Removes an existing snapshot. All messages retained in the
// Delete: Removes an existing snapshot. <br><br>
// <b>ALPHA:</b> This feature is part of an alpha release. This API
// might be
// changed in backward-incompatible ways and is not recommended for
// production
// use. It is not subject to any SLA or deprecation policy.
// When the snapshot is deleted, all messages retained in the
// snapshot
// are immediately dropped. After a snapshot is deleted, a new one may
// be
......@@ -1648,7 +1714,7 @@ func (c *ProjectsSnapshotsDeleteCall) Do(opts ...googleapi.CallOption) (*Empty,
}
return ret, nil
// {
// "description": "Removes an existing snapshot. All messages retained in the snapshot\nare immediately dropped. After a snapshot is deleted, a new one may be\ncreated with the same name, but the new one has no association with the old\nsnapshot or its subscription, unless the same subscription is specified.",
// "description": "Removes an existing snapshot. \u003cbr\u003e\u003cbr\u003e\n\u003cb\u003eALPHA:\u003c/b\u003e This feature is part of an alpha release. This API might be\nchanged in backward-incompatible ways and is not recommended for production\nuse. It is not subject to any SLA or deprecation policy.\nWhen the snapshot is deleted, all messages retained in the snapshot\nare immediately dropped. After a snapshot is deleted, a new one may be\ncreated with the same name, but the new one has no association with the old\nsnapshot or its subscription, unless the same subscription is specified.",
// "flatPath": "v1/projects/{projectsId}/snapshots/{snapshotsId}",
// "httpMethod": "DELETE",
// "id": "pubsub.projects.snapshots.delete",
......@@ -1687,7 +1753,13 @@ type ProjectsSnapshotsGetCall struct {
header_ http.Header
}
// Get: Gets the configuration details of a snapshot.
// Get: Gets the configuration details of a
// snapshot.<br><br>
// <b>ALPHA:</b> This feature is part of an alpha release. This API
// might be
// changed in backward-incompatible ways and is not recommended for
// production
// use. It is not subject to any SLA or deprecation policy.
func (r *ProjectsSnapshotsService) Get(snapshot string) *ProjectsSnapshotsGetCall {
c := &ProjectsSnapshotsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
c.snapshot = snapshot
......@@ -1788,7 +1860,7 @@ func (c *ProjectsSnapshotsGetCall) Do(opts ...googleapi.CallOption) (*Snapshot,
}
return ret, nil
// {
// "description": "Gets the configuration details of a snapshot.",
// "description": "Gets the configuration details of a snapshot.\u003cbr\u003e\u003cbr\u003e\n\u003cb\u003eALPHA:\u003c/b\u003e This feature is part of an alpha release. This API might be\nchanged in backward-incompatible ways and is not recommended for production\nuse. It is not subject to any SLA or deprecation policy.",
// "flatPath": "v1/projects/{projectsId}/snapshots/{snapshotsId}",
// "httpMethod": "GET",
// "id": "pubsub.projects.snapshots.get",
......@@ -1970,7 +2042,12 @@ type ProjectsSnapshotsListCall struct {
header_ http.Header
}
// List: Lists the existing snapshots.
// List: Lists the existing snapshots.<br><br>
// <b>ALPHA:</b> This feature is part of an alpha release. This API
// might be
// changed in backward-incompatible ways and is not recommended for
// production
// use. It is not subject to any SLA or deprecation policy.
func (r *ProjectsSnapshotsService) List(project string) *ProjectsSnapshotsListCall {
c := &ProjectsSnapshotsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
c.project = project
......@@ -2088,7 +2165,7 @@ func (c *ProjectsSnapshotsListCall) Do(opts ...googleapi.CallOption) (*ListSnaps
}
return ret, nil
// {
// "description": "Lists the existing snapshots.",
// "description": "Lists the existing snapshots.\u003cbr\u003e\u003cbr\u003e\n\u003cb\u003eALPHA:\u003c/b\u003e This feature is part of an alpha release. This API might be\nchanged in backward-incompatible ways and is not recommended for production\nuse. It is not subject to any SLA or deprecation policy.",
// "flatPath": "v1/projects/{projectsId}/snapshots",
// "httpMethod": "GET",
// "id": "pubsub.projects.snapshots.list",
......@@ -2159,9 +2236,13 @@ type ProjectsSnapshotsPatchCall struct {
header_ http.Header
}
// Patch: Updates an existing snapshot. Note that certain properties of
// a
// snapshot are not modifiable.
// Patch: Updates an existing snapshot.<br><br>
// <b>ALPHA:</b> This feature is part of an alpha release. This API
// might be
// changed in backward-incompatible ways and is not recommended for
// production
// use. It is not subject to any SLA or deprecation policy.
// Note that certain properties of a snapshot are not modifiable.
func (r *ProjectsSnapshotsService) Patch(name string, updatesnapshotrequest *UpdateSnapshotRequest) *ProjectsSnapshotsPatchCall {
c := &ProjectsSnapshotsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
c.name = name
......@@ -2255,7 +2336,7 @@ func (c *ProjectsSnapshotsPatchCall) Do(opts ...googleapi.CallOption) (*Snapshot
}
return ret, nil
// {
// "description": "Updates an existing snapshot. Note that certain properties of a\nsnapshot are not modifiable.",
// "description": "Updates an existing snapshot.\u003cbr\u003e\u003cbr\u003e\n\u003cb\u003eALPHA:\u003c/b\u003e This feature is part of an alpha release. This API might be\nchanged in backward-incompatible ways and is not recommended for production\nuse. It is not subject to any SLA or deprecation policy.\nNote that certain properties of a snapshot are not modifiable.",
// "flatPath": "v1/projects/{projectsId}/snapshots/{snapshotsId}",
// "httpMethod": "PATCH",
// "id": "pubsub.projects.snapshots.patch",
......@@ -2727,7 +2808,9 @@ type ProjectsSubscriptionsCreateCall struct {
header_ http.Header
}
// Create: Creates a subscription to a given topic.
// Create: Creates a subscription to a given topic. See the
// <a href="/pubsub/docs/admin#resource_names"> resource name
// rules</a>.
// If the subscription already exists, returns `ALREADY_EXISTS`.
// If the corresponding topic doesn't exist, returns `NOT_FOUND`.
//
......@@ -2835,7 +2918,7 @@ func (c *ProjectsSubscriptionsCreateCall) Do(opts ...googleapi.CallOption) (*Sub
}
return ret, nil
// {
// "description": "Creates a subscription to a given topic.\nIf the subscription already exists, returns `ALREADY_EXISTS`.\nIf the corresponding topic doesn't exist, returns `NOT_FOUND`.\n\nIf the name is not provided in the request, the server will assign a random\nname for this subscription on the same project as the topic, conforming\nto the\n[resource name format](https://cloud.google.com/pubsub/docs/overview#names).\nThe generated name is populated in the returned Subscription object.\nNote that for REST API requests, you must specify a name in the request.",
// "description": "Creates a subscription to a given topic. See the\n\u003ca href=\"/pubsub/docs/admin#resource_names\"\u003e resource name rules\u003c/a\u003e.\nIf the subscription already exists, returns `ALREADY_EXISTS`.\nIf the corresponding topic doesn't exist, returns `NOT_FOUND`.\n\nIf the name is not provided in the request, the server will assign a random\nname for this subscription on the same project as the topic, conforming\nto the\n[resource name format](https://cloud.google.com/pubsub/docs/overview#names).\nThe generated name is populated in the returned Subscription object.\nNote that for REST API requests, you must specify a name in the request.",
// "flatPath": "v1/projects/{projectsId}/subscriptions/{subscriptionsId}",
// "httpMethod": "PUT",
// "id": "pubsub.projects.subscriptions.create",
......@@ -4055,7 +4138,12 @@ type ProjectsSubscriptionsSeekCall struct {
// Seek: Seeks an existing subscription to a point in time or to a given
// snapshot,
// whichever is provided in the request.
// whichever is provided in the request.<br><br>
// <b>ALPHA:</b> This feature is part of an alpha release. This API
// might be
// changed in backward-incompatible ways and is not recommended for
// production
// use. It is not subject to any SLA or deprecation policy.
func (r *ProjectsSubscriptionsService) Seek(subscription string, seekrequest *SeekRequest) *ProjectsSubscriptionsSeekCall {
c := &ProjectsSubscriptionsSeekCall{s: r.s, urlParams_: make(gensupport.URLParams)}
c.subscription = subscription
......@@ -4149,7 +4237,7 @@ func (c *ProjectsSubscriptionsSeekCall) Do(opts ...googleapi.CallOption) (*SeekR
}
return ret, nil
// {
// "description": "Seeks an existing subscription to a point in time or to a given snapshot,\nwhichever is provided in the request.",
// "description": "Seeks an existing subscription to a point in time or to a given snapshot,\nwhichever is provided in the request.\u003cbr\u003e\u003cbr\u003e\n\u003cb\u003eALPHA:\u003c/b\u003e This feature is part of an alpha release. This API might be\nchanged in backward-incompatible ways and is not recommended for production\nuse. It is not subject to any SLA or deprecation policy.",
// "flatPath": "v1/projects/{projectsId}/subscriptions/{subscriptionsId}:seek",
// "httpMethod": "POST",
// "id": "pubsub.projects.subscriptions.seek",
......@@ -4475,7 +4563,8 @@ type ProjectsTopicsCreateCall struct {
header_ http.Header
}
// Create: Creates the given topic with the given name.
// Create: Creates the given topic with the given name. See the
// <a href="/pubsub/docs/admin#resource_names"> resource name rules</a>.
func (r *ProjectsTopicsService) Create(name string, topic *Topic) *ProjectsTopicsCreateCall {
c := &ProjectsTopicsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
c.name = name
......@@ -4569,7 +4658,7 @@ func (c *ProjectsTopicsCreateCall) Do(opts ...googleapi.CallOption) (*Topic, err
}
return ret, nil
// {
// "description": "Creates the given topic with the given name.",
// "description": "Creates the given topic with the given name. See the\n\u003ca href=\"/pubsub/docs/admin#resource_names\"\u003e resource name rules\u003c/a\u003e.",
// "flatPath": "v1/projects/{projectsId}/topics/{topicsId}",
// "httpMethod": "PUT",
// "id": "pubsub.projects.topics.create",
......@@ -5641,7 +5730,13 @@ type ProjectsTopicsSnapshotsListCall struct {
header_ http.Header
}
// List: Lists the names of the snapshots on this topic.
// List: Lists the names of the snapshots on this
// topic.<br><br>
// <b>ALPHA:</b> This feature is part of an alpha release. This API
// might be
// changed in backward-incompatible ways and is not recommended for
// production
// use. It is not subject to any SLA or deprecation policy.
func (r *ProjectsTopicsSnapshotsService) List(topic string) *ProjectsTopicsSnapshotsListCall {
c := &ProjectsTopicsSnapshotsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
c.topic = topic
......@@ -5759,7 +5854,7 @@ func (c *ProjectsTopicsSnapshotsListCall) Do(opts ...googleapi.CallOption) (*Lis
}
return ret, nil
// {
// "description": "Lists the names of the snapshots on this topic.",
// "description": "Lists the names of the snapshots on this topic.\u003cbr\u003e\u003cbr\u003e\n\u003cb\u003eALPHA:\u003c/b\u003e This feature is part of an alpha release. This API might be\nchanged in backward-incompatible ways and is not recommended for production\nuse. It is not subject to any SLA or deprecation policy.",
// "flatPath": "v1/projects/{projectsId}/topics/{topicsId}/snapshots",
// "httpMethod": "GET",
// "id": "pubsub.projects.topics.snapshots.list",
......
......@@ -3,7 +3,7 @@ load("@io_bazel_rules_go//go:def.bzl", "go_library")
go_library(
name = "go_default_library",
srcs = ["tpu-gen.go"],
importpath = "google.golang.org/api/tpu/v1alpha1",
importpath = "google.golang.org/api/tpu/v1",
visibility = ["//visibility:public"],
deps = [
"//vendor/golang.org/x/net/context:go_default_library",
......
......@@ -20,7 +20,7 @@
"x16": "http://www.google.com/images/icons/product/search-16.gif",
"x32": "http://www.google.com/images/icons/product/search-32.gif"
},
"id": "tpu:v1alpha1",
"id": "tpu:v1",
"kind": "discovery#restDescription",
"name": "tpu",
"ownerDomain": "google.com",
......@@ -60,11 +60,6 @@
"location": "query",
"type": "string"
},
"bearer_token": {
"description": "OAuth bearer token.",
"location": "query",
"type": "string"
},
"callback": {
"description": "JSONP",
"location": "query",
......@@ -85,12 +80,6 @@
"location": "query",
"type": "string"
},
"pp": {
"default": "true",
"description": "Pretty-print response.",
"location": "query",
"type": "boolean"
},
"prettyPrint": {
"default": "true",
"description": "Returns response with indentations and line breaks.",
......@@ -120,8 +109,8 @@
"locations": {
"methods": {
"get": {
"description": "Get information about a location.",
"flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}",
"description": "Gets information about a location.",
"flatPath": "v1/projects/{projectsId}/locations/{locationsId}",
"httpMethod": "GET",
"id": "tpu.projects.locations.get",
"parameterOrder": [
......@@ -136,7 +125,7 @@
"type": "string"
}
},
"path": "v1alpha1/{+name}",
"path": "v1/{+name}",
"response": {
"$ref": "Location"
},
......@@ -146,7 +135,7 @@
},
"list": {
"description": "Lists information about the supported locations for this service.",
"flatPath": "v1alpha1/projects/{projectsId}/locations",
"flatPath": "v1/projects/{projectsId}/locations",
"httpMethod": "GET",
"id": "tpu.projects.locations.list",
"parameterOrder": [
......@@ -177,7 +166,7 @@
"type": "string"
}
},
"path": "v1alpha1/{+name}/locations",
"path": "v1/{+name}/locations",
"response": {
"$ref": "ListLocationsResponse"
},
......@@ -187,11 +176,86 @@
}
},
"resources": {
"acceleratorTypes": {
"methods": {
"get": {
"description": "Gets AcceleratorType.",
"flatPath": "v1/projects/{projectsId}/locations/{locationsId}/acceleratorTypes/{acceleratorTypesId}",
"httpMethod": "GET",
"id": "tpu.projects.locations.acceleratorTypes.get",
"parameterOrder": [
"name"
],
"parameters": {
"name": {
"description": "The resource name.",
"location": "path",
"pattern": "^projects/[^/]+/locations/[^/]+/acceleratorTypes/[^/]+$",
"required": true,
"type": "string"
}
},
"path": "v1/{+name}",
"response": {
"$ref": "AcceleratorType"
},
"scopes": [
"https://www.googleapis.com/auth/cloud-platform"
]
},
"list": {
"description": "Lists accelerator types supported by this API.",
"flatPath": "v1/projects/{projectsId}/locations/{locationsId}/acceleratorTypes",
"httpMethod": "GET",
"id": "tpu.projects.locations.acceleratorTypes.list",
"parameterOrder": [
"parent"
],
"parameters": {
"filter": {
"description": "List filter.",
"location": "query",
"type": "string"
},
"orderBy": {
"description": "Sort results.",
"location": "query",
"type": "string"
},
"pageSize": {
"description": "The maximum number of items to return.",
"format": "int32",
"location": "query",
"type": "integer"
},
"pageToken": {
"description": "The next_page_token value returned from a previous List request, if any.",
"location": "query",
"type": "string"
},
"parent": {
"description": "The parent resource name.",
"location": "path",
"pattern": "^projects/[^/]+/locations/[^/]+$",
"required": true,
"type": "string"
}
},
"path": "v1/{+parent}/acceleratorTypes",
"response": {
"$ref": "ListAcceleratorTypesResponse"
},
"scopes": [
"https://www.googleapis.com/auth/cloud-platform"
]
}
}
},
"nodes": {
"methods": {
"create": {
"description": "Creates a node.",
"flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/nodes",
"flatPath": "v1/projects/{projectsId}/locations/{locationsId}/nodes",
"httpMethod": "POST",
"id": "tpu.projects.locations.nodes.create",
"parameterOrder": [
......@@ -211,7 +275,7 @@
"type": "string"
}
},
"path": "v1alpha1/{+parent}/nodes",
"path": "v1/{+parent}/nodes",
"request": {
"$ref": "Node"
},
......@@ -224,7 +288,7 @@
},
"delete": {
"description": "Deletes a node.",
"flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/nodes/{nodesId}",
"flatPath": "v1/projects/{projectsId}/locations/{locationsId}/nodes/{nodesId}",
"httpMethod": "DELETE",
"id": "tpu.projects.locations.nodes.delete",
"parameterOrder": [
......@@ -239,7 +303,7 @@
"type": "string"
}
},
"path": "v1alpha1/{+name}",
"path": "v1/{+name}",
"response": {
"$ref": "Operation"
},
......@@ -249,7 +313,7 @@
},
"get": {
"description": "Gets the details of a node.",
"flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/nodes/{nodesId}",
"flatPath": "v1/projects/{projectsId}/locations/{locationsId}/nodes/{nodesId}",
"httpMethod": "GET",
"id": "tpu.projects.locations.nodes.get",
"parameterOrder": [
......@@ -264,7 +328,7 @@
"type": "string"
}
},
"path": "v1alpha1/{+name}",
"path": "v1/{+name}",
"response": {
"$ref": "Node"
},
......@@ -274,7 +338,7 @@
},
"list": {
"description": "Lists nodes.",
"flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/nodes",
"flatPath": "v1/projects/{projectsId}/locations/{locationsId}/nodes",
"httpMethod": "GET",
"id": "tpu.projects.locations.nodes.list",
"parameterOrder": [
......@@ -300,7 +364,7 @@
"type": "string"
}
},
"path": "v1alpha1/{+parent}/nodes",
"path": "v1/{+parent}/nodes",
"response": {
"$ref": "ListNodesResponse"
},
......@@ -310,7 +374,7 @@
},
"reimage": {
"description": "Reimages a node's OS.",
"flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/nodes/{nodesId}:reimage",
"flatPath": "v1/projects/{projectsId}/locations/{locationsId}/nodes/{nodesId}:reimage",
"httpMethod": "POST",
"id": "tpu.projects.locations.nodes.reimage",
"parameterOrder": [
......@@ -325,7 +389,7 @@
"type": "string"
}
},
"path": "v1alpha1/{+name}:reimage",
"path": "v1/{+name}:reimage",
"request": {
"$ref": "ReimageNodeRequest"
},
......@@ -338,7 +402,7 @@
},
"reset": {
"description": "Resets a node, which stops and starts the VM.",
"flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/nodes/{nodesId}:reset",
"flatPath": "v1/projects/{projectsId}/locations/{locationsId}/nodes/{nodesId}:reset",
"httpMethod": "POST",
"id": "tpu.projects.locations.nodes.reset",
"parameterOrder": [
......@@ -353,7 +417,7 @@
"type": "string"
}
},
"path": "v1alpha1/{+name}:reset",
"path": "v1/{+name}:reset",
"request": {
"$ref": "ResetNodeRequest"
},
......@@ -366,7 +430,7 @@
},
"start": {
"description": "Starts a node.",
"flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/nodes/{nodesId}:start",
"flatPath": "v1/projects/{projectsId}/locations/{locationsId}/nodes/{nodesId}:start",
"httpMethod": "POST",
"id": "tpu.projects.locations.nodes.start",
"parameterOrder": [
......@@ -381,7 +445,7 @@
"type": "string"
}
},
"path": "v1alpha1/{+name}:start",
"path": "v1/{+name}:start",
"request": {
"$ref": "StartNodeRequest"
},
......@@ -394,7 +458,7 @@
},
"stop": {
"description": "Stops a node.",
"flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/nodes/{nodesId}:stop",
"flatPath": "v1/projects/{projectsId}/locations/{locationsId}/nodes/{nodesId}:stop",
"httpMethod": "POST",
"id": "tpu.projects.locations.nodes.stop",
"parameterOrder": [
......@@ -409,7 +473,7 @@
"type": "string"
}
},
"path": "v1alpha1/{+name}:stop",
"path": "v1/{+name}:stop",
"request": {
"$ref": "StopNodeRequest"
},
......@@ -426,7 +490,7 @@
"methods": {
"cancel": {
"description": "Starts asynchronous cancellation on a long-running operation. The server\nmakes a best effort to cancel the operation, but success is not\nguaranteed. If the server doesn't support this method, it returns\n`google.rpc.Code.UNIMPLEMENTED`. Clients can use\nOperations.GetOperation or\nother methods to check whether the cancellation succeeded or whether the\noperation completed despite cancellation. On successful cancellation,\nthe operation is not deleted; instead, it becomes an operation with\nan Operation.error value with a google.rpc.Status.code of 1,\ncorresponding to `Code.CANCELLED`.",
"flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}:cancel",
"flatPath": "v1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}:cancel",
"httpMethod": "POST",
"id": "tpu.projects.locations.operations.cancel",
"parameterOrder": [
......@@ -441,7 +505,7 @@
"type": "string"
}
},
"path": "v1alpha1/{+name}:cancel",
"path": "v1/{+name}:cancel",
"response": {
"$ref": "Empty"
},
......@@ -451,7 +515,7 @@
},
"delete": {
"description": "Deletes a long-running operation. This method indicates that the client is\nno longer interested in the operation result. It does not cancel the\noperation. If the server doesn't support this method, it returns\n`google.rpc.Code.UNIMPLEMENTED`.",
"flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}",
"flatPath": "v1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}",
"httpMethod": "DELETE",
"id": "tpu.projects.locations.operations.delete",
"parameterOrder": [
......@@ -466,7 +530,7 @@
"type": "string"
}
},
"path": "v1alpha1/{+name}",
"path": "v1/{+name}",
"response": {
"$ref": "Empty"
},
......@@ -476,7 +540,7 @@
},
"get": {
"description": "Gets the latest state of a long-running operation. Clients can use this\nmethod to poll the operation result at intervals as recommended by the API\nservice.",
"flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}",
"flatPath": "v1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}",
"httpMethod": "GET",
"id": "tpu.projects.locations.operations.get",
"parameterOrder": [
......@@ -491,7 +555,7 @@
"type": "string"
}
},
"path": "v1alpha1/{+name}",
"path": "v1/{+name}",
"response": {
"$ref": "Operation"
},
......@@ -501,7 +565,7 @@
},
"list": {
"description": "Lists operations that match the specified filter in the request. If the\nserver doesn't support this method, it returns `UNIMPLEMENTED`.\n\nNOTE: the `name` binding allows API services to override the binding\nto use different resource name schemes, such as `users/*/operations`. To\noverride the binding, API services can add a binding such as\n`\"/v1/{name=users/*}/operations\"` to their service configuration.\nFor backwards compatibility, the default name includes the operations\ncollection id, however overriding users must ensure the name binding\nis the parent resource, without the operations collection id.",
"flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/operations",
"flatPath": "v1/projects/{projectsId}/locations/{locationsId}/operations",
"httpMethod": "GET",
"id": "tpu.projects.locations.operations.list",
"parameterOrder": [
......@@ -532,7 +596,7 @@
"type": "string"
}
},
"path": "v1alpha1/{+name}/operations",
"path": "v1/{+name}/operations",
"response": {
"$ref": "ListOperationsResponse"
},
......@@ -546,7 +610,7 @@
"methods": {
"get": {
"description": "Gets TensorFlow Version.",
"flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/tensorflowVersions/{tensorflowVersionsId}",
"flatPath": "v1/projects/{projectsId}/locations/{locationsId}/tensorflowVersions/{tensorflowVersionsId}",
"httpMethod": "GET",
"id": "tpu.projects.locations.tensorflowVersions.get",
"parameterOrder": [
......@@ -561,7 +625,7 @@
"type": "string"
}
},
"path": "v1alpha1/{+name}",
"path": "v1/{+name}",
"response": {
"$ref": "TensorFlowVersion"
},
......@@ -570,8 +634,8 @@
]
},
"list": {
"description": "Lists TensorFlow versions supported by this API.",
"flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/tensorflowVersions",
"description": "List TensorFlow versions supported by this API.",
"flatPath": "v1/projects/{projectsId}/locations/{locationsId}/tensorflowVersions",
"httpMethod": "GET",
"id": "tpu.projects.locations.tensorflowVersions.list",
"parameterOrder": [
......@@ -607,7 +671,7 @@
"type": "string"
}
},
"path": "v1alpha1/{+parent}/tensorflowVersions",
"path": "v1/{+parent}/tensorflowVersions",
"response": {
"$ref": "ListTensorFlowVersionsResponse"
},
......@@ -622,15 +686,48 @@
}
}
},
"revision": "20180202",
"revision": "20180601",
"rootUrl": "https://tpu.googleapis.com/",
"schemas": {
"AcceleratorType": {
"description": "A accelerator type that a Node can be configured with.",
"id": "AcceleratorType",
"properties": {
"name": {
"description": "The resource name.",
"type": "string"
},
"type": {
"description": "the accelerator type.",
"type": "string"
}
},
"type": "object"
},
"Empty": {
"description": "A generic empty message that you can re-use to avoid defining duplicated\nempty messages in your APIs. A typical example is to use it as the request\nor the response type of an API method. For instance:\n\n service Foo {\n rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty);\n }\n\nThe JSON representation for `Empty` is empty JSON object `{}`.",
"id": "Empty",
"properties": {},
"type": "object"
},
"ListAcceleratorTypesResponse": {
"description": "Response for ListAcceleratorTypes.",
"id": "ListAcceleratorTypesResponse",
"properties": {
"acceleratorTypes": {
"description": "The listed nodes.",
"items": {
"$ref": "AcceleratorType"
},
"type": "array"
},
"nextPageToken": {
"description": "The next page token or empty if none.",
"type": "string"
}
},
"type": "object"
},
"ListLocationsResponse": {
"description": "The response message for Locations.ListLocations.",
"id": "ListLocationsResponse",
......@@ -707,6 +804,10 @@
"description": "A resource that represents Google Cloud Platform location.",
"id": "Location",
"properties": {
"displayName": {
"description": "The friendly name for this location, typically a nearby city name.\nFor example, \"Tokyo\".",
"type": "string"
},
"labels": {
"additionalProperties": {
"type": "string"
......@@ -820,6 +921,9 @@
"description": "Output only.\nDEPRECATED! Use network_endpoints instead.\nThe network port for the TPU Node as visible to Compute Engine instances.",
"type": "string"
},
"schedulingConfig": {
"$ref": "SchedulingConfig"
},
"serviceAccount": {
"description": "Output only.\nThe service account used to run the tensor flow services within the node.\nTo share resources, including Google Cloud Storage data, with the\nTensorflow job running in the Node, this account must have permissions to\nthat data.",
"type": "string"
......@@ -834,7 +938,9 @@
"REIMAGING",
"DELETING",
"REPAIRING",
"STOPPED"
"STOPPED",
"STOPPING",
"STARTING"
],
"enumDescriptions": [
"TPU node state is not known/set.",
......@@ -844,7 +950,9 @@
"TPU node is undergoing reimaging.",
"TPU node is being deleted.",
"TPU node is being repaired and may be unusable. Details can be\nfound in the `help_description` field.",
"7 - Reserved. Was SUSPENDED.\nTPU node is stopped."
"7 - Reserved. Was SUSPENDED.\nTPU node is stopped.",
"TPU node is currently stopping.",
"TPU node is currently starting."
],
"type": "string"
},
......@@ -944,6 +1052,15 @@
"properties": {},
"type": "object"
},
"SchedulingConfig": {
"id": "SchedulingConfig",
"properties": {
"preemptible": {
"type": "boolean"
}
},
"type": "object"
},
"StartNodeRequest": {
"description": "Request for StartNode.",
"id": "StartNodeRequest",
......@@ -1001,6 +1118,6 @@
},
"servicePath": "",
"title": "Cloud TPU API",
"version": "v1alpha1",
"version": "v1",
"version_module": true
}
\ No newline at end of file
......@@ -4,7 +4,7 @@
//
// Usage example:
//
// import "google.golang.org/api/tpu/v1alpha1"
// import "google.golang.org/api/tpu/v1"
// ...
// tpuService, err := tpu.New(oauthHttpClient)
package tpu
......@@ -40,9 +40,9 @@ var _ = strings.Replace
var _ = context.Canceled
var _ = ctxhttp.Do
const apiId = "tpu:v1alpha1"
const apiId = "tpu:v1"
const apiName = "tpu"
const apiVersion = "v1alpha1"
const apiVersion = "v1"
const basePath = "https://tpu.googleapis.com/"
// OAuth2 scopes used by this API.
......@@ -89,6 +89,7 @@ type ProjectsService struct {
func NewProjectsLocationsService(s *Service) *ProjectsLocationsService {
rs := &ProjectsLocationsService{s: s}
rs.AcceleratorTypes = NewProjectsLocationsAcceleratorTypesService(s)
rs.Nodes = NewProjectsLocationsNodesService(s)
rs.Operations = NewProjectsLocationsOperationsService(s)
rs.TensorflowVersions = NewProjectsLocationsTensorflowVersionsService(s)
......@@ -98,6 +99,8 @@ func NewProjectsLocationsService(s *Service) *ProjectsLocationsService {
type ProjectsLocationsService struct {
s *Service
AcceleratorTypes *ProjectsLocationsAcceleratorTypesService
Nodes *ProjectsLocationsNodesService
Operations *ProjectsLocationsOperationsService
......@@ -105,6 +108,15 @@ type ProjectsLocationsService struct {
TensorflowVersions *ProjectsLocationsTensorflowVersionsService
}
func NewProjectsLocationsAcceleratorTypesService(s *Service) *ProjectsLocationsAcceleratorTypesService {
rs := &ProjectsLocationsAcceleratorTypesService{s: s}
return rs
}
type ProjectsLocationsAcceleratorTypesService struct {
s *Service
}
func NewProjectsLocationsNodesService(s *Service) *ProjectsLocationsNodesService {
rs := &ProjectsLocationsNodesService{s: s}
return rs
......@@ -132,6 +144,42 @@ type ProjectsLocationsTensorflowVersionsService struct {
s *Service
}
// AcceleratorType: A accelerator type that a Node can be configured
// with.
type AcceleratorType struct {
// Name: The resource name.
Name string `json:"name,omitempty"`
// Type: the accelerator type.
Type string `json:"type,omitempty"`
// ServerResponse contains the HTTP response code and headers from the
// server.
googleapi.ServerResponse `json:"-"`
// ForceSendFields is a list of field names (e.g. "Name") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Name") to include in API
// requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *AcceleratorType) MarshalJSON() ([]byte, error) {
type NoMethod AcceleratorType
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
// Empty: A generic empty message that you can re-use to avoid defining
// duplicated
// empty messages in your APIs. A typical example is to use it as the
......@@ -150,6 +198,42 @@ type Empty struct {
googleapi.ServerResponse `json:"-"`
}
// ListAcceleratorTypesResponse: Response for ListAcceleratorTypes.
type ListAcceleratorTypesResponse struct {
// AcceleratorTypes: The listed nodes.
AcceleratorTypes []*AcceleratorType `json:"acceleratorTypes,omitempty"`
// NextPageToken: The next page token or empty if none.
NextPageToken string `json:"nextPageToken,omitempty"`
// ServerResponse contains the HTTP response code and headers from the
// server.
googleapi.ServerResponse `json:"-"`
// ForceSendFields is a list of field names (e.g. "AcceleratorTypes") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "AcceleratorTypes") to
// include in API requests with the JSON null value. By default, fields
// with empty values are omitted from API requests. However, any field
// with an empty value appearing in NullFields will be sent to the
// server as null. It is an error if a field in this list has a
// non-empty value. This may be used to include null fields in Patch
// requests.
NullFields []string `json:"-"`
}
func (s *ListAcceleratorTypesResponse) MarshalJSON() ([]byte, error) {
type NoMethod ListAcceleratorTypesResponse
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
// ListLocationsResponse: The response message for
// Locations.ListLocations.
type ListLocationsResponse struct {
......@@ -296,6 +380,11 @@ func (s *ListTensorFlowVersionsResponse) MarshalJSON() ([]byte, error) {
// Location: A resource that represents Google Cloud Platform location.
type Location struct {
// DisplayName: The friendly name for this location, typically a nearby
// city name.
// For example, "Tokyo".
DisplayName string `json:"displayName,omitempty"`
// Labels: Cross-service attributes for the location. For example
//
// {"cloud.googleapis.com/region": "us-east1"}
......@@ -319,7 +408,7 @@ type Location struct {
// server.
googleapi.ServerResponse `json:"-"`
// ForceSendFields is a list of field names (e.g. "Labels") to
// ForceSendFields is a list of field names (e.g. "DisplayName") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
......@@ -327,10 +416,10 @@ type Location struct {
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Labels") to include in API
// requests with the JSON null value. By default, fields with empty
// values are omitted from API requests. However, any field with an
// empty value appearing in NullFields will be sent to the server as
// NullFields is a list of field names (e.g. "DisplayName") to include
// in API requests with the JSON null value. By default, fields with
// empty values are omitted from API requests. However, any field with
// an empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
......@@ -457,6 +546,8 @@ type Node struct {
// instances.
Port string `json:"port,omitempty"`
SchedulingConfig *SchedulingConfig `json:"schedulingConfig,omitempty"`
// ServiceAccount: Output only.
// The service account used to run the tensor flow services within the
// node.
......@@ -482,6 +573,8 @@ type Node struct {
// found in the `help_description` field.
// "STOPPED" - 7 - Reserved. Was SUSPENDED.
// TPU node is stopped.
// "STOPPING" - TPU node is currently stopping.
// "STARTING" - TPU node is currently starting.
State string `json:"state,omitempty"`
// TensorflowVersion: The version of Tensorflow running in the
......@@ -680,6 +773,32 @@ func (s *ReimageNodeRequest) MarshalJSON() ([]byte, error) {
type ResetNodeRequest struct {
}
type SchedulingConfig struct {
Preemptible bool `json:"preemptible,omitempty"`
// ForceSendFields is a list of field names (e.g. "Preemptible") to
// unconditionally include in API requests. By default, fields with
// empty values are omitted from API requests. However, any non-pointer,
// non-interface field appearing in ForceSendFields will be sent to the
// server regardless of whether the field is empty or not. This may be
// used to include empty fields in Patch requests.
ForceSendFields []string `json:"-"`
// NullFields is a list of field names (e.g. "Preemptible") to include
// in API requests with the JSON null value. By default, fields with
// empty values are omitted from API requests. However, any field with
// an empty value appearing in NullFields will be sent to the server as
// null. It is an error if a field in this list has a non-empty value.
// This may be used to include null fields in Patch requests.
NullFields []string `json:"-"`
}
func (s *SchedulingConfig) MarshalJSON() ([]byte, error) {
type NoMethod SchedulingConfig
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
// StartNodeRequest: Request for StartNode.
type StartNodeRequest struct {
}
......@@ -854,7 +973,7 @@ type ProjectsLocationsGetCall struct {
header_ http.Header
}
// Get: Get information about a location.
// Get: Gets information about a location.
func (r *ProjectsLocationsService) Get(name string) *ProjectsLocationsGetCall {
c := &ProjectsLocationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
c.name = name
......@@ -907,7 +1026,7 @@ func (c *ProjectsLocationsGetCall) doRequest(alt string) (*http.Response, error)
}
var body io.Reader = nil
c.urlParams_.Set("alt", alt)
urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha1/{+name}")
urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
urls += "?" + c.urlParams_.Encode()
req, _ := http.NewRequest("GET", urls, body)
req.Header = reqHeaders
......@@ -955,8 +1074,8 @@ func (c *ProjectsLocationsGetCall) Do(opts ...googleapi.CallOption) (*Location,
}
return ret, nil
// {
// "description": "Get information about a location.",
// "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}",
// "description": "Gets information about a location.",
// "flatPath": "v1/projects/{projectsId}/locations/{locationsId}",
// "httpMethod": "GET",
// "id": "tpu.projects.locations.get",
// "parameterOrder": [
......@@ -971,7 +1090,7 @@ func (c *ProjectsLocationsGetCall) Do(opts ...googleapi.CallOption) (*Location,
// "type": "string"
// }
// },
// "path": "v1alpha1/{+name}",
// "path": "v1/{+name}",
// "response": {
// "$ref": "Location"
// },
......@@ -1068,7 +1187,7 @@ func (c *ProjectsLocationsListCall) doRequest(alt string) (*http.Response, error
}
var body io.Reader = nil
c.urlParams_.Set("alt", alt)
urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha1/{+name}/locations")
urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}/locations")
urls += "?" + c.urlParams_.Encode()
req, _ := http.NewRequest("GET", urls, body)
req.Header = reqHeaders
......@@ -1117,7 +1236,7 @@ func (c *ProjectsLocationsListCall) Do(opts ...googleapi.CallOption) (*ListLocat
return ret, nil
// {
// "description": "Lists information about the supported locations for this service.",
// "flatPath": "v1alpha1/projects/{projectsId}/locations",
// "flatPath": "v1/projects/{projectsId}/locations",
// "httpMethod": "GET",
// "id": "tpu.projects.locations.list",
// "parameterOrder": [
......@@ -1148,7 +1267,7 @@ func (c *ProjectsLocationsListCall) Do(opts ...googleapi.CallOption) (*ListLocat
// "type": "string"
// }
// },
// "path": "v1alpha1/{+name}/locations",
// "path": "v1/{+name}/locations",
// "response": {
// "$ref": "ListLocationsResponse"
// },
......@@ -1180,6 +1299,352 @@ func (c *ProjectsLocationsListCall) Pages(ctx context.Context, f func(*ListLocat
}
}
// method id "tpu.projects.locations.acceleratorTypes.get":
type ProjectsLocationsAcceleratorTypesGetCall struct {
s *Service
name string
urlParams_ gensupport.URLParams
ifNoneMatch_ string
ctx_ context.Context
header_ http.Header
}
// Get: Gets AcceleratorType.
func (r *ProjectsLocationsAcceleratorTypesService) Get(name string) *ProjectsLocationsAcceleratorTypesGetCall {
c := &ProjectsLocationsAcceleratorTypesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
c.name = name
return c
}
// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *ProjectsLocationsAcceleratorTypesGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsAcceleratorTypesGetCall {
c.urlParams_.Set("fields", googleapi.CombineFields(s))
return c
}
// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *ProjectsLocationsAcceleratorTypesGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsAcceleratorTypesGetCall {
c.ifNoneMatch_ = entityTag
return c
}
// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *ProjectsLocationsAcceleratorTypesGetCall) Context(ctx context.Context) *ProjectsLocationsAcceleratorTypesGetCall {
c.ctx_ = ctx
return c
}
// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *ProjectsLocationsAcceleratorTypesGetCall) Header() http.Header {
if c.header_ == nil {
c.header_ = make(http.Header)
}
return c.header_
}
func (c *ProjectsLocationsAcceleratorTypesGetCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
for k, v := range c.header_ {
reqHeaders[k] = v
}
reqHeaders.Set("User-Agent", c.s.userAgent())
if c.ifNoneMatch_ != "" {
reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
}
var body io.Reader = nil
c.urlParams_.Set("alt", alt)
urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
urls += "?" + c.urlParams_.Encode()
req, _ := http.NewRequest("GET", urls, body)
req.Header = reqHeaders
googleapi.Expand(req.URL, map[string]string{
"name": c.name,
})
return gensupport.SendRequest(c.ctx_, c.s.client, req)
}
// Do executes the "tpu.projects.locations.acceleratorTypes.get" call.
// Exactly one of *AcceleratorType or error will be non-nil. Any non-2xx
// status code is an error. Response headers are in either
// *AcceleratorType.ServerResponse.Header or (if a response was returned
// at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *ProjectsLocationsAcceleratorTypesGetCall) Do(opts ...googleapi.CallOption) (*AcceleratorType, error) {
gensupport.SetOptions(c.urlParams_, opts...)
res, err := c.doRequest("json")
if res != nil && res.StatusCode == http.StatusNotModified {
if res.Body != nil {
res.Body.Close()
}
return nil, &googleapi.Error{
Code: res.StatusCode,
Header: res.Header,
}
}
if err != nil {
return nil, err
}
defer googleapi.CloseBody(res)
if err := googleapi.CheckResponse(res); err != nil {
return nil, err
}
ret := &AcceleratorType{
ServerResponse: googleapi.ServerResponse{
Header: res.Header,
HTTPStatusCode: res.StatusCode,
},
}
target := &ret
if err := gensupport.DecodeResponse(target, res); err != nil {
return nil, err
}
return ret, nil
// {
// "description": "Gets AcceleratorType.",
// "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/acceleratorTypes/{acceleratorTypesId}",
// "httpMethod": "GET",
// "id": "tpu.projects.locations.acceleratorTypes.get",
// "parameterOrder": [
// "name"
// ],
// "parameters": {
// "name": {
// "description": "The resource name.",
// "location": "path",
// "pattern": "^projects/[^/]+/locations/[^/]+/acceleratorTypes/[^/]+$",
// "required": true,
// "type": "string"
// }
// },
// "path": "v1/{+name}",
// "response": {
// "$ref": "AcceleratorType"
// },
// "scopes": [
// "https://www.googleapis.com/auth/cloud-platform"
// ]
// }
}
// method id "tpu.projects.locations.acceleratorTypes.list":
type ProjectsLocationsAcceleratorTypesListCall struct {
s *Service
parent string
urlParams_ gensupport.URLParams
ifNoneMatch_ string
ctx_ context.Context
header_ http.Header
}
// List: Lists accelerator types supported by this API.
func (r *ProjectsLocationsAcceleratorTypesService) List(parent string) *ProjectsLocationsAcceleratorTypesListCall {
c := &ProjectsLocationsAcceleratorTypesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
c.parent = parent
return c
}
// Filter sets the optional parameter "filter": List filter.
func (c *ProjectsLocationsAcceleratorTypesListCall) Filter(filter string) *ProjectsLocationsAcceleratorTypesListCall {
c.urlParams_.Set("filter", filter)
return c
}
// OrderBy sets the optional parameter "orderBy": Sort results.
func (c *ProjectsLocationsAcceleratorTypesListCall) OrderBy(orderBy string) *ProjectsLocationsAcceleratorTypesListCall {
c.urlParams_.Set("orderBy", orderBy)
return c
}
// PageSize sets the optional parameter "pageSize": The maximum number
// of items to return.
func (c *ProjectsLocationsAcceleratorTypesListCall) PageSize(pageSize int64) *ProjectsLocationsAcceleratorTypesListCall {
c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
return c
}
// PageToken sets the optional parameter "pageToken": The
// next_page_token value returned from a previous List request, if any.
func (c *ProjectsLocationsAcceleratorTypesListCall) PageToken(pageToken string) *ProjectsLocationsAcceleratorTypesListCall {
c.urlParams_.Set("pageToken", pageToken)
return c
}
// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *ProjectsLocationsAcceleratorTypesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsAcceleratorTypesListCall {
c.urlParams_.Set("fields", googleapi.CombineFields(s))
return c
}
// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *ProjectsLocationsAcceleratorTypesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsAcceleratorTypesListCall {
c.ifNoneMatch_ = entityTag
return c
}
// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *ProjectsLocationsAcceleratorTypesListCall) Context(ctx context.Context) *ProjectsLocationsAcceleratorTypesListCall {
c.ctx_ = ctx
return c
}
// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *ProjectsLocationsAcceleratorTypesListCall) Header() http.Header {
if c.header_ == nil {
c.header_ = make(http.Header)
}
return c.header_
}
func (c *ProjectsLocationsAcceleratorTypesListCall) doRequest(alt string) (*http.Response, error) {
reqHeaders := make(http.Header)
for k, v := range c.header_ {
reqHeaders[k] = v
}
reqHeaders.Set("User-Agent", c.s.userAgent())
if c.ifNoneMatch_ != "" {
reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
}
var body io.Reader = nil
c.urlParams_.Set("alt", alt)
urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/acceleratorTypes")
urls += "?" + c.urlParams_.Encode()
req, _ := http.NewRequest("GET", urls, body)
req.Header = reqHeaders
googleapi.Expand(req.URL, map[string]string{
"parent": c.parent,
})
return gensupport.SendRequest(c.ctx_, c.s.client, req)
}
// Do executes the "tpu.projects.locations.acceleratorTypes.list" call.
// Exactly one of *ListAcceleratorTypesResponse or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *ListAcceleratorTypesResponse.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *ProjectsLocationsAcceleratorTypesListCall) Do(opts ...googleapi.CallOption) (*ListAcceleratorTypesResponse, error) {
gensupport.SetOptions(c.urlParams_, opts...)
res, err := c.doRequest("json")
if res != nil && res.StatusCode == http.StatusNotModified {
if res.Body != nil {
res.Body.Close()
}
return nil, &googleapi.Error{
Code: res.StatusCode,
Header: res.Header,
}
}
if err != nil {
return nil, err
}
defer googleapi.CloseBody(res)
if err := googleapi.CheckResponse(res); err != nil {
return nil, err
}
ret := &ListAcceleratorTypesResponse{
ServerResponse: googleapi.ServerResponse{
Header: res.Header,
HTTPStatusCode: res.StatusCode,
},
}
target := &ret
if err := gensupport.DecodeResponse(target, res); err != nil {
return nil, err
}
return ret, nil
// {
// "description": "Lists accelerator types supported by this API.",
// "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/acceleratorTypes",
// "httpMethod": "GET",
// "id": "tpu.projects.locations.acceleratorTypes.list",
// "parameterOrder": [
// "parent"
// ],
// "parameters": {
// "filter": {
// "description": "List filter.",
// "location": "query",
// "type": "string"
// },
// "orderBy": {
// "description": "Sort results.",
// "location": "query",
// "type": "string"
// },
// "pageSize": {
// "description": "The maximum number of items to return.",
// "format": "int32",
// "location": "query",
// "type": "integer"
// },
// "pageToken": {
// "description": "The next_page_token value returned from a previous List request, if any.",
// "location": "query",
// "type": "string"
// },
// "parent": {
// "description": "The parent resource name.",
// "location": "path",
// "pattern": "^projects/[^/]+/locations/[^/]+$",
// "required": true,
// "type": "string"
// }
// },
// "path": "v1/{+parent}/acceleratorTypes",
// "response": {
// "$ref": "ListAcceleratorTypesResponse"
// },
// "scopes": [
// "https://www.googleapis.com/auth/cloud-platform"
// ]
// }
}
// Pages invokes f for each page of results.
// A non-nil error returned from f will halt the iteration.
// The provided context supersedes any context provided to the Context method.
func (c *ProjectsLocationsAcceleratorTypesListCall) Pages(ctx context.Context, f func(*ListAcceleratorTypesResponse) error) error {
c.ctx_ = ctx
defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
for {
x, err := c.Do()
if err != nil {
return err
}
if err := f(x); err != nil {
return err
}
if x.NextPageToken == "" {
return nil
}
c.PageToken(x.NextPageToken)
}
}
// method id "tpu.projects.locations.nodes.create":
type ProjectsLocationsNodesCreateCall struct {
......@@ -1244,7 +1709,7 @@ func (c *ProjectsLocationsNodesCreateCall) doRequest(alt string) (*http.Response
}
reqHeaders.Set("Content-Type", "application/json")
c.urlParams_.Set("alt", alt)
urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha1/{+parent}/nodes")
urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/nodes")
urls += "?" + c.urlParams_.Encode()
req, _ := http.NewRequest("POST", urls, body)
req.Header = reqHeaders
......@@ -1293,7 +1758,7 @@ func (c *ProjectsLocationsNodesCreateCall) Do(opts ...googleapi.CallOption) (*Op
return ret, nil
// {
// "description": "Creates a node.",
// "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/nodes",
// "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/nodes",
// "httpMethod": "POST",
// "id": "tpu.projects.locations.nodes.create",
// "parameterOrder": [
......@@ -1313,7 +1778,7 @@ func (c *ProjectsLocationsNodesCreateCall) Do(opts ...googleapi.CallOption) (*Op
// "type": "string"
// }
// },
// "path": "v1alpha1/{+parent}/nodes",
// "path": "v1/{+parent}/nodes",
// "request": {
// "$ref": "Node"
// },
......@@ -1377,7 +1842,7 @@ func (c *ProjectsLocationsNodesDeleteCall) doRequest(alt string) (*http.Response
reqHeaders.Set("User-Agent", c.s.userAgent())
var body io.Reader = nil
c.urlParams_.Set("alt", alt)
urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha1/{+name}")
urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
urls += "?" + c.urlParams_.Encode()
req, _ := http.NewRequest("DELETE", urls, body)
req.Header = reqHeaders
......@@ -1426,7 +1891,7 @@ func (c *ProjectsLocationsNodesDeleteCall) Do(opts ...googleapi.CallOption) (*Op
return ret, nil
// {
// "description": "Deletes a node.",
// "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/nodes/{nodesId}",
// "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/nodes/{nodesId}",
// "httpMethod": "DELETE",
// "id": "tpu.projects.locations.nodes.delete",
// "parameterOrder": [
......@@ -1441,7 +1906,7 @@ func (c *ProjectsLocationsNodesDeleteCall) Do(opts ...googleapi.CallOption) (*Op
// "type": "string"
// }
// },
// "path": "v1alpha1/{+name}",
// "path": "v1/{+name}",
// "response": {
// "$ref": "Operation"
// },
......@@ -1516,7 +1981,7 @@ func (c *ProjectsLocationsNodesGetCall) doRequest(alt string) (*http.Response, e
}
var body io.Reader = nil
c.urlParams_.Set("alt", alt)
urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha1/{+name}")
urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
urls += "?" + c.urlParams_.Encode()
req, _ := http.NewRequest("GET", urls, body)
req.Header = reqHeaders
......@@ -1565,7 +2030,7 @@ func (c *ProjectsLocationsNodesGetCall) Do(opts ...googleapi.CallOption) (*Node,
return ret, nil
// {
// "description": "Gets the details of a node.",
// "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/nodes/{nodesId}",
// "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/nodes/{nodesId}",
// "httpMethod": "GET",
// "id": "tpu.projects.locations.nodes.get",
// "parameterOrder": [
......@@ -1580,7 +2045,7 @@ func (c *ProjectsLocationsNodesGetCall) Do(opts ...googleapi.CallOption) (*Node,
// "type": "string"
// }
// },
// "path": "v1alpha1/{+name}",
// "path": "v1/{+name}",
// "response": {
// "$ref": "Node"
// },
......@@ -1669,7 +2134,7 @@ func (c *ProjectsLocationsNodesListCall) doRequest(alt string) (*http.Response,
}
var body io.Reader = nil
c.urlParams_.Set("alt", alt)
urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha1/{+parent}/nodes")
urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/nodes")
urls += "?" + c.urlParams_.Encode()
req, _ := http.NewRequest("GET", urls, body)
req.Header = reqHeaders
......@@ -1718,7 +2183,7 @@ func (c *ProjectsLocationsNodesListCall) Do(opts ...googleapi.CallOption) (*List
return ret, nil
// {
// "description": "Lists nodes.",
// "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/nodes",
// "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/nodes",
// "httpMethod": "GET",
// "id": "tpu.projects.locations.nodes.list",
// "parameterOrder": [
......@@ -1744,7 +2209,7 @@ func (c *ProjectsLocationsNodesListCall) Do(opts ...googleapi.CallOption) (*List
// "type": "string"
// }
// },
// "path": "v1alpha1/{+parent}/nodes",
// "path": "v1/{+parent}/nodes",
// "response": {
// "$ref": "ListNodesResponse"
// },
......@@ -1833,7 +2298,7 @@ func (c *ProjectsLocationsNodesReimageCall) doRequest(alt string) (*http.Respons
}
reqHeaders.Set("Content-Type", "application/json")
c.urlParams_.Set("alt", alt)
urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha1/{+name}:reimage")
urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:reimage")
urls += "?" + c.urlParams_.Encode()
req, _ := http.NewRequest("POST", urls, body)
req.Header = reqHeaders
......@@ -1882,7 +2347,7 @@ func (c *ProjectsLocationsNodesReimageCall) Do(opts ...googleapi.CallOption) (*O
return ret, nil
// {
// "description": "Reimages a node's OS.",
// "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/nodes/{nodesId}:reimage",
// "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/nodes/{nodesId}:reimage",
// "httpMethod": "POST",
// "id": "tpu.projects.locations.nodes.reimage",
// "parameterOrder": [
......@@ -1897,7 +2362,7 @@ func (c *ProjectsLocationsNodesReimageCall) Do(opts ...googleapi.CallOption) (*O
// "type": "string"
// }
// },
// "path": "v1alpha1/{+name}:reimage",
// "path": "v1/{+name}:reimage",
// "request": {
// "$ref": "ReimageNodeRequest"
// },
......@@ -1968,7 +2433,7 @@ func (c *ProjectsLocationsNodesResetCall) doRequest(alt string) (*http.Response,
}
reqHeaders.Set("Content-Type", "application/json")
c.urlParams_.Set("alt", alt)
urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha1/{+name}:reset")
urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:reset")
urls += "?" + c.urlParams_.Encode()
req, _ := http.NewRequest("POST", urls, body)
req.Header = reqHeaders
......@@ -2017,7 +2482,7 @@ func (c *ProjectsLocationsNodesResetCall) Do(opts ...googleapi.CallOption) (*Ope
return ret, nil
// {
// "description": "Resets a node, which stops and starts the VM.",
// "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/nodes/{nodesId}:reset",
// "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/nodes/{nodesId}:reset",
// "httpMethod": "POST",
// "id": "tpu.projects.locations.nodes.reset",
// "parameterOrder": [
......@@ -2032,7 +2497,7 @@ func (c *ProjectsLocationsNodesResetCall) Do(opts ...googleapi.CallOption) (*Ope
// "type": "string"
// }
// },
// "path": "v1alpha1/{+name}:reset",
// "path": "v1/{+name}:reset",
// "request": {
// "$ref": "ResetNodeRequest"
// },
......@@ -2103,7 +2568,7 @@ func (c *ProjectsLocationsNodesStartCall) doRequest(alt string) (*http.Response,
}
reqHeaders.Set("Content-Type", "application/json")
c.urlParams_.Set("alt", alt)
urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha1/{+name}:start")
urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:start")
urls += "?" + c.urlParams_.Encode()
req, _ := http.NewRequest("POST", urls, body)
req.Header = reqHeaders
......@@ -2152,7 +2617,7 @@ func (c *ProjectsLocationsNodesStartCall) Do(opts ...googleapi.CallOption) (*Ope
return ret, nil
// {
// "description": "Starts a node.",
// "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/nodes/{nodesId}:start",
// "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/nodes/{nodesId}:start",
// "httpMethod": "POST",
// "id": "tpu.projects.locations.nodes.start",
// "parameterOrder": [
......@@ -2167,7 +2632,7 @@ func (c *ProjectsLocationsNodesStartCall) Do(opts ...googleapi.CallOption) (*Ope
// "type": "string"
// }
// },
// "path": "v1alpha1/{+name}:start",
// "path": "v1/{+name}:start",
// "request": {
// "$ref": "StartNodeRequest"
// },
......@@ -2238,7 +2703,7 @@ func (c *ProjectsLocationsNodesStopCall) doRequest(alt string) (*http.Response,
}
reqHeaders.Set("Content-Type", "application/json")
c.urlParams_.Set("alt", alt)
urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha1/{+name}:stop")
urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:stop")
urls += "?" + c.urlParams_.Encode()
req, _ := http.NewRequest("POST", urls, body)
req.Header = reqHeaders
......@@ -2287,7 +2752,7 @@ func (c *ProjectsLocationsNodesStopCall) Do(opts ...googleapi.CallOption) (*Oper
return ret, nil
// {
// "description": "Stops a node.",
// "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/nodes/{nodesId}:stop",
// "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/nodes/{nodesId}:stop",
// "httpMethod": "POST",
// "id": "tpu.projects.locations.nodes.stop",
// "parameterOrder": [
......@@ -2302,7 +2767,7 @@ func (c *ProjectsLocationsNodesStopCall) Do(opts ...googleapi.CallOption) (*Oper
// "type": "string"
// }
// },
// "path": "v1alpha1/{+name}:stop",
// "path": "v1/{+name}:stop",
// "request": {
// "$ref": "StopNodeRequest"
// },
......@@ -2383,7 +2848,7 @@ func (c *ProjectsLocationsOperationsCancelCall) doRequest(alt string) (*http.Res
reqHeaders.Set("User-Agent", c.s.userAgent())
var body io.Reader = nil
c.urlParams_.Set("alt", alt)
urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha1/{+name}:cancel")
urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:cancel")
urls += "?" + c.urlParams_.Encode()
req, _ := http.NewRequest("POST", urls, body)
req.Header = reqHeaders
......@@ -2432,7 +2897,7 @@ func (c *ProjectsLocationsOperationsCancelCall) Do(opts ...googleapi.CallOption)
return ret, nil
// {
// "description": "Starts asynchronous cancellation on a long-running operation. The server\nmakes a best effort to cancel the operation, but success is not\nguaranteed. If the server doesn't support this method, it returns\n`google.rpc.Code.UNIMPLEMENTED`. Clients can use\nOperations.GetOperation or\nother methods to check whether the cancellation succeeded or whether the\noperation completed despite cancellation. On successful cancellation,\nthe operation is not deleted; instead, it becomes an operation with\nan Operation.error value with a google.rpc.Status.code of 1,\ncorresponding to `Code.CANCELLED`.",
// "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}:cancel",
// "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}:cancel",
// "httpMethod": "POST",
// "id": "tpu.projects.locations.operations.cancel",
// "parameterOrder": [
......@@ -2447,7 +2912,7 @@ func (c *ProjectsLocationsOperationsCancelCall) Do(opts ...googleapi.CallOption)
// "type": "string"
// }
// },
// "path": "v1alpha1/{+name}:cancel",
// "path": "v1/{+name}:cancel",
// "response": {
// "$ref": "Empty"
// },
......@@ -2514,7 +2979,7 @@ func (c *ProjectsLocationsOperationsDeleteCall) doRequest(alt string) (*http.Res
reqHeaders.Set("User-Agent", c.s.userAgent())
var body io.Reader = nil
c.urlParams_.Set("alt", alt)
urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha1/{+name}")
urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
urls += "?" + c.urlParams_.Encode()
req, _ := http.NewRequest("DELETE", urls, body)
req.Header = reqHeaders
......@@ -2563,7 +3028,7 @@ func (c *ProjectsLocationsOperationsDeleteCall) Do(opts ...googleapi.CallOption)
return ret, nil
// {
// "description": "Deletes a long-running operation. This method indicates that the client is\nno longer interested in the operation result. It does not cancel the\noperation. If the server doesn't support this method, it returns\n`google.rpc.Code.UNIMPLEMENTED`.",
// "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}",
// "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}",
// "httpMethod": "DELETE",
// "id": "tpu.projects.locations.operations.delete",
// "parameterOrder": [
......@@ -2578,7 +3043,7 @@ func (c *ProjectsLocationsOperationsDeleteCall) Do(opts ...googleapi.CallOption)
// "type": "string"
// }
// },
// "path": "v1alpha1/{+name}",
// "path": "v1/{+name}",
// "response": {
// "$ref": "Empty"
// },
......@@ -2657,7 +3122,7 @@ func (c *ProjectsLocationsOperationsGetCall) doRequest(alt string) (*http.Respon
}
var body io.Reader = nil
c.urlParams_.Set("alt", alt)
urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha1/{+name}")
urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
urls += "?" + c.urlParams_.Encode()
req, _ := http.NewRequest("GET", urls, body)
req.Header = reqHeaders
......@@ -2706,7 +3171,7 @@ func (c *ProjectsLocationsOperationsGetCall) Do(opts ...googleapi.CallOption) (*
return ret, nil
// {
// "description": "Gets the latest state of a long-running operation. Clients can use this\nmethod to poll the operation result at intervals as recommended by the API\nservice.",
// "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}",
// "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}",
// "httpMethod": "GET",
// "id": "tpu.projects.locations.operations.get",
// "parameterOrder": [
......@@ -2721,7 +3186,7 @@ func (c *ProjectsLocationsOperationsGetCall) Do(opts ...googleapi.CallOption) (*
// "type": "string"
// }
// },
// "path": "v1alpha1/{+name}",
// "path": "v1/{+name}",
// "response": {
// "$ref": "Operation"
// },
......@@ -2833,7 +3298,7 @@ func (c *ProjectsLocationsOperationsListCall) doRequest(alt string) (*http.Respo
}
var body io.Reader = nil
c.urlParams_.Set("alt", alt)
urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha1/{+name}/operations")
urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}/operations")
urls += "?" + c.urlParams_.Encode()
req, _ := http.NewRequest("GET", urls, body)
req.Header = reqHeaders
......@@ -2882,7 +3347,7 @@ func (c *ProjectsLocationsOperationsListCall) Do(opts ...googleapi.CallOption) (
return ret, nil
// {
// "description": "Lists operations that match the specified filter in the request. If the\nserver doesn't support this method, it returns `UNIMPLEMENTED`.\n\nNOTE: the `name` binding allows API services to override the binding\nto use different resource name schemes, such as `users/*/operations`. To\noverride the binding, API services can add a binding such as\n`\"/v1/{name=users/*}/operations\"` to their service configuration.\nFor backwards compatibility, the default name includes the operations\ncollection id, however overriding users must ensure the name binding\nis the parent resource, without the operations collection id.",
// "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/operations",
// "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/operations",
// "httpMethod": "GET",
// "id": "tpu.projects.locations.operations.list",
// "parameterOrder": [
......@@ -2913,7 +3378,7 @@ func (c *ProjectsLocationsOperationsListCall) Do(opts ...googleapi.CallOption) (
// "type": "string"
// }
// },
// "path": "v1alpha1/{+name}/operations",
// "path": "v1/{+name}/operations",
// "response": {
// "$ref": "ListOperationsResponse"
// },
......@@ -3009,7 +3474,7 @@ func (c *ProjectsLocationsTensorflowVersionsGetCall) doRequest(alt string) (*htt
}
var body io.Reader = nil
c.urlParams_.Set("alt", alt)
urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha1/{+name}")
urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
urls += "?" + c.urlParams_.Encode()
req, _ := http.NewRequest("GET", urls, body)
req.Header = reqHeaders
......@@ -3058,7 +3523,7 @@ func (c *ProjectsLocationsTensorflowVersionsGetCall) Do(opts ...googleapi.CallOp
return ret, nil
// {
// "description": "Gets TensorFlow Version.",
// "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/tensorflowVersions/{tensorflowVersionsId}",
// "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/tensorflowVersions/{tensorflowVersionsId}",
// "httpMethod": "GET",
// "id": "tpu.projects.locations.tensorflowVersions.get",
// "parameterOrder": [
......@@ -3073,7 +3538,7 @@ func (c *ProjectsLocationsTensorflowVersionsGetCall) Do(opts ...googleapi.CallOp
// "type": "string"
// }
// },
// "path": "v1alpha1/{+name}",
// "path": "v1/{+name}",
// "response": {
// "$ref": "TensorFlowVersion"
// },
......@@ -3095,7 +3560,7 @@ type ProjectsLocationsTensorflowVersionsListCall struct {
header_ http.Header
}
// List: Lists TensorFlow versions supported by this API.
// List: List TensorFlow versions supported by this API.
func (r *ProjectsLocationsTensorflowVersionsService) List(parent string) *ProjectsLocationsTensorflowVersionsListCall {
c := &ProjectsLocationsTensorflowVersionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
c.parent = parent
......@@ -3174,7 +3639,7 @@ func (c *ProjectsLocationsTensorflowVersionsListCall) doRequest(alt string) (*ht
}
var body io.Reader = nil
c.urlParams_.Set("alt", alt)
urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha1/{+parent}/tensorflowVersions")
urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/tensorflowVersions")
urls += "?" + c.urlParams_.Encode()
req, _ := http.NewRequest("GET", urls, body)
req.Header = reqHeaders
......@@ -3222,8 +3687,8 @@ func (c *ProjectsLocationsTensorflowVersionsListCall) Do(opts ...googleapi.CallO
}
return ret, nil
// {
// "description": "Lists TensorFlow versions supported by this API.",
// "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/tensorflowVersions",
// "description": "List TensorFlow versions supported by this API.",
// "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/tensorflowVersions",
// "httpMethod": "GET",
// "id": "tpu.projects.locations.tensorflowVersions.list",
// "parameterOrder": [
......@@ -3259,7 +3724,7 @@ func (c *ProjectsLocationsTensorflowVersionsListCall) Do(opts ...googleapi.CallO
// "type": "string"
// }
// },
// "path": "v1alpha1/{+parent}/tensorflowVersions",
// "path": "v1/{+parent}/tensorflowVersions",
// "response": {
// "$ref": "ListTensorFlowVersionsResponse"
// },
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment