vendor: update all dependencies

This commit is contained in:
Nick Craig-Wood
2018-03-19 15:51:38 +00:00
parent 940df88eb2
commit d64789528d
4309 changed files with 1327278 additions and 1001118 deletions

File diff suppressed because one or more lines are too long

View File

@ -629,6 +629,9 @@ func (s *Database) MarshalJSON() ([]byte, error) {
type Delete struct {
// KeySet: Required. The primary keys of the rows within table to
// delete.
// Delete is idempotent. The transaction will succeed even if some or
// all
// rows do not exist.
KeySet *KeySet `json:"keySet,omitempty"`
// Table: Required. The table whose rows will be deleted.
@ -711,9 +714,19 @@ type ExecuteSqlRequest struct {
// corresponding parameter values.
Params googleapi.RawMessage `json:"params,omitempty"`
// PartitionToken: If present, results will be restricted to the
// specified partition
// previously created using PartitionQuery(). There must be an
// exact
// match for the values of fields common to this message and
// the
// PartitionQueryRequest message used to create this partition_token.
PartitionToken string `json:"partitionToken,omitempty"`
// QueryMode: Used to control the amount of debugging information
// returned in
// ResultSetStats.
// ResultSetStats. If partition_token is set, query_mode can only
// be set to QueryMode.NORMAL.
//
// Possible values:
// "NORMAL" - The default mode where only the query result, without
@ -1669,6 +1682,267 @@ func (s *PartialResultSet) MarshalJSON() ([]byte, error) {
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
// Partition: Information returned for each partition returned in
// a
// PartitionResponse.
type Partition struct {
// PartitionToken: This token can be passed to Read, StreamingRead,
// ExecuteSql, or
// ExecuteStreamingSql requests to restrict the results to those
// identified by
// this partition token.
PartitionToken string `json:"partitionToken,omitempty"`
// ForceSendFields is a list of field names (e.g. "PartitionToken") 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. "PartitionToken") 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 *Partition) MarshalJSON() ([]byte, error) {
type NoMethod Partition
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
// PartitionOptions: Options for a PartitionQueryRequest
// and
// PartitionReadRequest.
type PartitionOptions struct {
// MaxPartitions: **Note:** This hint is currently ignored by
// PartitionQuery and
// PartitionRead requests.
//
// The desired maximum number of partitions to return. For example,
// this may
// be set to the number of workers available. The default for this
// option
// is currently 10,000. The maximum value is currently 200,000. This is
// only
// a hint. The actual number of partitions returned may be smaller or
// larger
// than this maximum count request.
MaxPartitions int64 `json:"maxPartitions,omitempty,string"`
// PartitionSizeBytes: **Note:** This hint is currently ignored by
// PartitionQuery and
// PartitionRead requests.
//
// The desired data size for each partition generated. The default for
// this
// option is currently 1 GiB. This is only a hint. The actual size of
// each
// partition may be smaller or larger than this size request.
PartitionSizeBytes int64 `json:"partitionSizeBytes,omitempty,string"`
// ForceSendFields is a list of field names (e.g. "MaxPartitions") 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. "MaxPartitions") 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 *PartitionOptions) MarshalJSON() ([]byte, error) {
type NoMethod PartitionOptions
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
// PartitionQueryRequest: The request for PartitionQuery
type PartitionQueryRequest struct {
// ParamTypes: It is not always possible for Cloud Spanner to infer the
// right SQL type
// from a JSON value. For example, values of type `BYTES` and values
// of type `STRING` both appear in params as JSON strings.
//
// In these cases, `param_types` can be used to specify the exact
// SQL type for some or all of the SQL query parameters. See
// the
// definition of Type for more information
// about SQL types.
ParamTypes map[string]Type `json:"paramTypes,omitempty"`
// Params: The SQL query string can contain parameter placeholders. A
// parameter
// placeholder consists of `'@'` followed by the parameter
// name. Parameter names consist of any combination of letters,
// numbers, and underscores.
//
// Parameters can appear anywhere that a literal value is expected. The
// same
// parameter name can be used more than once, for example:
// "WHERE id > @msg_id AND id < @msg_id + 100"
//
// It is an error to execute an SQL query with unbound
// parameters.
//
// Parameter values are specified using `params`, which is a JSON
// object whose keys are parameter names, and whose values are
// the
// corresponding parameter values.
Params googleapi.RawMessage `json:"params,omitempty"`
// PartitionOptions: Additional options that affect how many partitions
// are created.
PartitionOptions *PartitionOptions `json:"partitionOptions,omitempty"`
// Sql: The query request to generate partitions for. The request will
// fail if
// the query is not root partitionable. The query plan of a
// root
// partitionable query has a single distributed union operator. A
// distributed
// union operator conceptually divides one or more tables into
// multiple
// splits, remotely evaluates a subquery independently on each split,
// and
// then unions all results.
Sql string `json:"sql,omitempty"`
// Transaction: Read only snapshot transactions are supported,
// read/write and single use
// transactions are not.
Transaction *TransactionSelector `json:"transaction,omitempty"`
// ForceSendFields is a list of field names (e.g. "ParamTypes") 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. "ParamTypes") 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 *PartitionQueryRequest) MarshalJSON() ([]byte, error) {
type NoMethod PartitionQueryRequest
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
// PartitionReadRequest: The request for PartitionRead
type PartitionReadRequest struct {
// Columns: The columns of table to be returned for each row
// matching
// this request.
Columns []string `json:"columns,omitempty"`
// Index: If non-empty, the name of an index on table. This index
// is
// used instead of the table primary key when interpreting key_set
// and sorting result rows. See key_set for further information.
Index string `json:"index,omitempty"`
// KeySet: Required. `key_set` identifies the rows to be yielded.
// `key_set` names the
// primary keys of the rows in table to be yielded, unless index
// is present. If index is present, then key_set instead names
// index keys in index.
//
// It is not an error for the `key_set` to name rows that do not
// exist in the database. Read yields nothing for nonexistent rows.
KeySet *KeySet `json:"keySet,omitempty"`
// PartitionOptions: Additional options that affect how many partitions
// are created.
PartitionOptions *PartitionOptions `json:"partitionOptions,omitempty"`
// Table: Required. The name of the table in the database to be read.
Table string `json:"table,omitempty"`
// Transaction: Read only snapshot transactions are supported,
// read/write and single use
// transactions are not.
Transaction *TransactionSelector `json:"transaction,omitempty"`
// ForceSendFields is a list of field names (e.g. "Columns") 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. "Columns") 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 *PartitionReadRequest) MarshalJSON() ([]byte, error) {
type NoMethod PartitionReadRequest
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
// PartitionResponse: The response for PartitionQuery
// or PartitionRead
type PartitionResponse struct {
// Partitions: Partitions created by this request.
Partitions []*Partition `json:"partitions,omitempty"`
// Transaction: Transaction created by this request.
Transaction *Transaction `json:"transaction,omitempty"`
// ServerResponse contains the HTTP response code and headers from the
// server.
googleapi.ServerResponse `json:"-"`
// ForceSendFields is a list of field names (e.g. "Partitions") 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. "Partitions") 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 *PartitionResponse) MarshalJSON() ([]byte, error) {
type NoMethod PartitionResponse
raw := NoMethod(*s)
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}
// PlanNode: Node information for nodes appearing in a
// QueryPlan.plan_nodes.
type PlanNode struct {
@ -1789,7 +2063,7 @@ func (s *PlanNode) MarshalJSON() ([]byte, error) {
// }
//
// For a description of IAM and its features, see the
// [IAM developer's guide](https://cloud.google.com/iam).
// [IAM developer's guide](https://cloud.google.com/iam/docs).
type Policy struct {
// Bindings: Associates a list of `members` to a `role`.
// `bindings` with no members will result in an error.
@ -1815,7 +2089,7 @@ type Policy struct {
// policy is overwritten blindly.
Etag string `json:"etag,omitempty"`
// Version: Version of the `Policy`. The default version is 0.
// Version: Deprecated.
Version int64 `json:"version,omitempty"`
// ServerResponse contains the HTTP response code and headers from the
@ -2004,8 +2278,10 @@ type ReadRequest struct {
// is present. If index is present, then key_set instead names
// index keys in index.
//
// Rows are yielded in table primary key order (if index is empty)
// or index key order (if index is non-empty).
// If the partition_token field is empty, rows are yielded
// in table primary key order (if index is empty) or index key order
// (if index is non-empty). If the partition_token field is not
// empty, rows will be yielded in an unspecified order.
//
// It is not an error for the `key_set` to name rows that do not
// exist in the database. Read yields nothing for nonexistent rows.
@ -2013,9 +2289,20 @@ type ReadRequest struct {
// Limit: If greater than zero, only the first `limit` rows are yielded.
// If `limit`
// is zero, the default is no limit.
// is zero, the default is no limit. A limit cannot be specified
// if
// `partition_token` is set.
Limit int64 `json:"limit,omitempty,string"`
// PartitionToken: If present, results will be restricted to the
// specified partition
// previously created using PartitionRead(). There must be an
// exact
// match for the values of fields common to this message and
// the
// PartitionReadRequest message used to create this partition_token.
PartitionToken string `json:"partitionToken,omitempty"`
// ResumeToken: If this request is resuming a previously interrupted
// read,
// `resume_token` should be copied from the last
@ -8120,6 +8407,303 @@ func (c *ProjectsInstancesDatabasesSessionsListCall) Pages(ctx context.Context,
}
}
// method id "spanner.projects.instances.databases.sessions.partitionQuery":
type ProjectsInstancesDatabasesSessionsPartitionQueryCall struct {
s *Service
session string
partitionqueryrequest *PartitionQueryRequest
urlParams_ gensupport.URLParams
ctx_ context.Context
header_ http.Header
}
// PartitionQuery: Creates a set of partition tokens that can be used to
// execute a query
// operation in parallel. Each of the returned partition tokens can be
// used
// by ExecuteStreamingSql to specify a subset
// of the query result to read. The same session and read-only
// transaction
// must be used by the PartitionQueryRequest used to create
// the
// partition tokens and the ExecuteSqlRequests that use the partition
// tokens.
// Partition tokens become invalid when the session used to create
// them
// is deleted or begins a new transaction.
func (r *ProjectsInstancesDatabasesSessionsService) PartitionQuery(session string, partitionqueryrequest *PartitionQueryRequest) *ProjectsInstancesDatabasesSessionsPartitionQueryCall {
c := &ProjectsInstancesDatabasesSessionsPartitionQueryCall{s: r.s, urlParams_: make(gensupport.URLParams)}
c.session = session
c.partitionqueryrequest = partitionqueryrequest
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 *ProjectsInstancesDatabasesSessionsPartitionQueryCall) Fields(s ...googleapi.Field) *ProjectsInstancesDatabasesSessionsPartitionQueryCall {
c.urlParams_.Set("fields", googleapi.CombineFields(s))
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 *ProjectsInstancesDatabasesSessionsPartitionQueryCall) Context(ctx context.Context) *ProjectsInstancesDatabasesSessionsPartitionQueryCall {
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 *ProjectsInstancesDatabasesSessionsPartitionQueryCall) Header() http.Header {
if c.header_ == nil {
c.header_ = make(http.Header)
}
return c.header_
}
func (c *ProjectsInstancesDatabasesSessionsPartitionQueryCall) 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())
var body io.Reader = nil
body, err := googleapi.WithoutDataWrapper.JSONReader(c.partitionqueryrequest)
if err != nil {
return nil, err
}
reqHeaders.Set("Content-Type", "application/json")
c.urlParams_.Set("alt", alt)
urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+session}:partitionQuery")
urls += "?" + c.urlParams_.Encode()
req, _ := http.NewRequest("POST", urls, body)
req.Header = reqHeaders
googleapi.Expand(req.URL, map[string]string{
"session": c.session,
})
return gensupport.SendRequest(c.ctx_, c.s.client, req)
}
// Do executes the "spanner.projects.instances.databases.sessions.partitionQuery" call.
// Exactly one of *PartitionResponse or error will be non-nil. Any
// non-2xx status code is an error. Response headers are in either
// *PartitionResponse.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 *ProjectsInstancesDatabasesSessionsPartitionQueryCall) Do(opts ...googleapi.CallOption) (*PartitionResponse, 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 := &PartitionResponse{
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": "Creates a set of partition tokens that can be used to execute a query\noperation in parallel. Each of the returned partition tokens can be used\nby ExecuteStreamingSql to specify a subset\nof the query result to read. The same session and read-only transaction\nmust be used by the PartitionQueryRequest used to create the\npartition tokens and the ExecuteSqlRequests that use the partition tokens.\nPartition tokens become invalid when the session used to create them\nis deleted or begins a new transaction.",
// "flatPath": "v1/projects/{projectsId}/instances/{instancesId}/databases/{databasesId}/sessions/{sessionsId}:partitionQuery",
// "httpMethod": "POST",
// "id": "spanner.projects.instances.databases.sessions.partitionQuery",
// "parameterOrder": [
// "session"
// ],
// "parameters": {
// "session": {
// "description": "Required. The session used to create the partitions.",
// "location": "path",
// "pattern": "^projects/[^/]+/instances/[^/]+/databases/[^/]+/sessions/[^/]+$",
// "required": true,
// "type": "string"
// }
// },
// "path": "v1/{+session}:partitionQuery",
// "request": {
// "$ref": "PartitionQueryRequest"
// },
// "response": {
// "$ref": "PartitionResponse"
// },
// "scopes": [
// "https://www.googleapis.com/auth/cloud-platform",
// "https://www.googleapis.com/auth/spanner.data"
// ]
// }
}
// method id "spanner.projects.instances.databases.sessions.partitionRead":
type ProjectsInstancesDatabasesSessionsPartitionReadCall struct {
s *Service
session string
partitionreadrequest *PartitionReadRequest
urlParams_ gensupport.URLParams
ctx_ context.Context
header_ http.Header
}
// PartitionRead: Creates a set of partition tokens that can be used to
// execute a read
// operation in parallel. Each of the returned partition tokens can be
// used
// by StreamingRead to specify a subset of the read
// result to read. The same session and read-only transaction must be
// used by
// the PartitionReadRequest used to create the partition tokens and
// the
// ReadRequests that use the partition tokens.
// Partition tokens become invalid when the session used to create
// them
// is deleted or begins a new transaction.
func (r *ProjectsInstancesDatabasesSessionsService) PartitionRead(session string, partitionreadrequest *PartitionReadRequest) *ProjectsInstancesDatabasesSessionsPartitionReadCall {
c := &ProjectsInstancesDatabasesSessionsPartitionReadCall{s: r.s, urlParams_: make(gensupport.URLParams)}
c.session = session
c.partitionreadrequest = partitionreadrequest
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 *ProjectsInstancesDatabasesSessionsPartitionReadCall) Fields(s ...googleapi.Field) *ProjectsInstancesDatabasesSessionsPartitionReadCall {
c.urlParams_.Set("fields", googleapi.CombineFields(s))
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 *ProjectsInstancesDatabasesSessionsPartitionReadCall) Context(ctx context.Context) *ProjectsInstancesDatabasesSessionsPartitionReadCall {
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 *ProjectsInstancesDatabasesSessionsPartitionReadCall) Header() http.Header {
if c.header_ == nil {
c.header_ = make(http.Header)
}
return c.header_
}
func (c *ProjectsInstancesDatabasesSessionsPartitionReadCall) 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())
var body io.Reader = nil
body, err := googleapi.WithoutDataWrapper.JSONReader(c.partitionreadrequest)
if err != nil {
return nil, err
}
reqHeaders.Set("Content-Type", "application/json")
c.urlParams_.Set("alt", alt)
urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+session}:partitionRead")
urls += "?" + c.urlParams_.Encode()
req, _ := http.NewRequest("POST", urls, body)
req.Header = reqHeaders
googleapi.Expand(req.URL, map[string]string{
"session": c.session,
})
return gensupport.SendRequest(c.ctx_, c.s.client, req)
}
// Do executes the "spanner.projects.instances.databases.sessions.partitionRead" call.
// Exactly one of *PartitionResponse or error will be non-nil. Any
// non-2xx status code is an error. Response headers are in either
// *PartitionResponse.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 *ProjectsInstancesDatabasesSessionsPartitionReadCall) Do(opts ...googleapi.CallOption) (*PartitionResponse, 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 := &PartitionResponse{
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": "Creates a set of partition tokens that can be used to execute a read\noperation in parallel. Each of the returned partition tokens can be used\nby StreamingRead to specify a subset of the read\nresult to read. The same session and read-only transaction must be used by\nthe PartitionReadRequest used to create the partition tokens and the\nReadRequests that use the partition tokens.\nPartition tokens become invalid when the session used to create them\nis deleted or begins a new transaction.",
// "flatPath": "v1/projects/{projectsId}/instances/{instancesId}/databases/{databasesId}/sessions/{sessionsId}:partitionRead",
// "httpMethod": "POST",
// "id": "spanner.projects.instances.databases.sessions.partitionRead",
// "parameterOrder": [
// "session"
// ],
// "parameters": {
// "session": {
// "description": "Required. The session used to create the partitions.",
// "location": "path",
// "pattern": "^projects/[^/]+/instances/[^/]+/databases/[^/]+/sessions/[^/]+$",
// "required": true,
// "type": "string"
// }
// },
// "path": "v1/{+session}:partitionRead",
// "request": {
// "$ref": "PartitionReadRequest"
// },
// "response": {
// "$ref": "PartitionResponse"
// },
// "scopes": [
// "https://www.googleapis.com/auth/cloud-platform",
// "https://www.googleapis.com/auth/spanner.data"
// ]
// }
}
// method id "spanner.projects.instances.databases.sessions.read":
type ProjectsInstancesDatabasesSessionsReadCall struct {