Bumping k8s dependencies to 1.13

This commit is contained in:
Cheng Xing
2018-11-16 14:08:25 -08:00
parent 305407125c
commit b4c0b68ec7
8002 changed files with 884099 additions and 276228 deletions

View File

@@ -3,18 +3,26 @@
package spanner
import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"
import _ "google.golang.org/genproto/googleapis/api/annotations"
import google_protobuf2 "github.com/golang/protobuf/ptypes/duration"
import google_protobuf3 "github.com/golang/protobuf/ptypes/timestamp"
import (
fmt "fmt"
proto "github.com/golang/protobuf/proto"
duration "github.com/golang/protobuf/ptypes/duration"
timestamp "github.com/golang/protobuf/ptypes/timestamp"
_ "google.golang.org/genproto/googleapis/api/annotations"
math "math"
)
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
var _ = fmt.Errorf
var _ = math.Inf
// This is a compile-time assertion to ensure that this generated file
// is compatible with the proto package it is being compiled against.
// A compilation error at this line likely means your copy of the
// proto package needs to be updated.
const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
// # Transactions
//
//
@@ -25,7 +33,7 @@ var _ = math.Inf
//
// # Transaction Modes
//
// Cloud Spanner supports two transaction modes:
// Cloud Spanner supports three transaction modes:
//
// 1. Locking read-write. This type of transaction is the only way
// to write data into Cloud Spanner. These transactions rely on
@@ -39,6 +47,13 @@ var _ = math.Inf
// read at timestamps in the past. Snapshot read-only
// transactions do not need to be committed.
//
// 3. Partitioned DML. This type of transaction is used to execute
// a single Partitioned DML statement. Partitioned DML partitions
// the key space and runs the DML statement over each partition
// in parallel using separate, internal transactions that commit
// independently. Partitioned DML transactions do not need to be
// committed.
//
// For transactions that only read, snapshot read-only transactions
// provide simpler semantics and are almost always faster. In
// particular, read-only transactions do not take locks, so they do
@@ -65,11 +80,8 @@ var _ = math.Inf
// inactivity at the client may cause Cloud Spanner to release a
// transaction's locks and abort it.
//
// Reads performed within a transaction acquire locks on the data
// being read. Writes can only be done at commit time, after all reads
// have been completed.
// Conceptually, a read-write transaction consists of zero or more
// reads or SQL queries followed by
// reads or SQL statements followed by
// [Commit][google.spanner.v1.Spanner.Commit]. At any time before
// [Commit][google.spanner.v1.Spanner.Commit], the client can send a
// [Rollback][google.spanner.v1.Spanner.Rollback] request to abort the
@@ -232,33 +244,121 @@ var _ = math.Inf
// restriction also applies to in-progress reads and/or SQL queries whose
// timestamp become too old while executing. Reads and SQL queries with
// too-old read timestamps fail with the error `FAILED_PRECONDITION`.
//
// ## Partitioned DML Transactions
//
// Partitioned DML transactions are used to execute DML statements with a
// different execution strategy that provides different, and often better,
// scalability properties for large, table-wide operations than DML in a
// ReadWrite transaction. Smaller scoped statements, such as an OLTP workload,
// should prefer using ReadWrite transactions.
//
// Partitioned DML partitions the keyspace and runs the DML statement on each
// partition in separate, internal transactions. These transactions commit
// automatically when complete, and run independently from one another.
//
// To reduce lock contention, this execution strategy only acquires read locks
// on rows that match the WHERE clause of the statement. Additionally, the
// smaller per-partition transactions hold locks for less time.
//
// That said, Partitioned DML is not a drop-in replacement for standard DML used
// in ReadWrite transactions.
//
// - The DML statement must be fully-partitionable. Specifically, the statement
// must be expressible as the union of many statements which each access only
// a single row of the table.
//
// - The statement is not applied atomically to all rows of the table. Rather,
// the statement is applied atomically to partitions of the table, in
// independent transactions. Secondary index rows are updated atomically
// with the base table rows.
//
// - Partitioned DML does not guarantee exactly-once execution semantics
// against a partition. The statement will be applied at least once to each
// partition. It is strongly recommended that the DML statement should be
// idempotent to avoid unexpected results. For instance, it is potentially
// dangerous to run a statement such as
// `UPDATE table SET column = column + 1` as it could be run multiple times
// against some rows.
//
// - The partitions are committed automatically - there is no support for
// Commit or Rollback. If the call returns an error, or if the client issuing
// the ExecuteSql call dies, it is possible that some rows had the statement
// executed on them successfully. It is also possible that statement was
// never executed against other rows.
//
// - Partitioned DML transactions may only contain the execution of a single
// DML statement via ExecuteSql or ExecuteStreamingSql.
//
// - If any error is encountered during the execution of the partitioned DML
// operation (for instance, a UNIQUE INDEX violation, division by zero, or a
// value that cannot be stored due to schema constraints), then the
// operation is stopped at that point and an error is returned. It is
// possible that at this point, some partitions have been committed (or even
// committed multiple times), and other partitions have not been run at all.
//
// Given the above, Partitioned DML is good fit for large, database-wide,
// operations that are idempotent, such as deleting old rows from a very large
// table.
type TransactionOptions struct {
// Required. The type of transaction.
//
// Types that are valid to be assigned to Mode:
// *TransactionOptions_ReadWrite_
// *TransactionOptions_PartitionedDml_
// *TransactionOptions_ReadOnly_
Mode isTransactionOptions_Mode `protobuf_oneof:"mode"`
Mode isTransactionOptions_Mode `protobuf_oneof:"mode"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *TransactionOptions) Reset() { *m = TransactionOptions{} }
func (m *TransactionOptions) String() string { return proto.CompactTextString(m) }
func (*TransactionOptions) ProtoMessage() {}
func (*TransactionOptions) Descriptor() ([]byte, []int) { return fileDescriptor5, []int{0} }
func (m *TransactionOptions) Reset() { *m = TransactionOptions{} }
func (m *TransactionOptions) String() string { return proto.CompactTextString(m) }
func (*TransactionOptions) ProtoMessage() {}
func (*TransactionOptions) Descriptor() ([]byte, []int) {
return fileDescriptor_a5743daa0b72b00f, []int{0}
}
func (m *TransactionOptions) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_TransactionOptions.Unmarshal(m, b)
}
func (m *TransactionOptions) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_TransactionOptions.Marshal(b, m, deterministic)
}
func (m *TransactionOptions) XXX_Merge(src proto.Message) {
xxx_messageInfo_TransactionOptions.Merge(m, src)
}
func (m *TransactionOptions) XXX_Size() int {
return xxx_messageInfo_TransactionOptions.Size(m)
}
func (m *TransactionOptions) XXX_DiscardUnknown() {
xxx_messageInfo_TransactionOptions.DiscardUnknown(m)
}
var xxx_messageInfo_TransactionOptions proto.InternalMessageInfo
type isTransactionOptions_Mode interface {
isTransactionOptions_Mode()
}
type TransactionOptions_ReadWrite_ struct {
ReadWrite *TransactionOptions_ReadWrite `protobuf:"bytes,1,opt,name=read_write,json=readWrite,oneof"`
ReadWrite *TransactionOptions_ReadWrite `protobuf:"bytes,1,opt,name=read_write,json=readWrite,proto3,oneof"`
}
type TransactionOptions_PartitionedDml_ struct {
PartitionedDml *TransactionOptions_PartitionedDml `protobuf:"bytes,3,opt,name=partitioned_dml,json=partitionedDml,proto3,oneof"`
}
type TransactionOptions_ReadOnly_ struct {
ReadOnly *TransactionOptions_ReadOnly `protobuf:"bytes,2,opt,name=read_only,json=readOnly,oneof"`
ReadOnly *TransactionOptions_ReadOnly `protobuf:"bytes,2,opt,name=read_only,json=readOnly,proto3,oneof"`
}
func (*TransactionOptions_ReadWrite_) isTransactionOptions_Mode() {}
func (*TransactionOptions_ReadOnly_) isTransactionOptions_Mode() {}
func (*TransactionOptions_PartitionedDml_) isTransactionOptions_Mode() {}
func (*TransactionOptions_ReadOnly_) isTransactionOptions_Mode() {}
func (m *TransactionOptions) GetMode() isTransactionOptions_Mode {
if m != nil {
@@ -274,6 +374,13 @@ func (m *TransactionOptions) GetReadWrite() *TransactionOptions_ReadWrite {
return nil
}
func (m *TransactionOptions) GetPartitionedDml() *TransactionOptions_PartitionedDml {
if x, ok := m.GetMode().(*TransactionOptions_PartitionedDml_); ok {
return x.PartitionedDml
}
return nil
}
func (m *TransactionOptions) GetReadOnly() *TransactionOptions_ReadOnly {
if x, ok := m.GetMode().(*TransactionOptions_ReadOnly_); ok {
return x.ReadOnly
@@ -285,6 +392,7 @@ func (m *TransactionOptions) GetReadOnly() *TransactionOptions_ReadOnly {
func (*TransactionOptions) XXX_OneofFuncs() (func(msg proto.Message, b *proto.Buffer) error, func(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error), func(msg proto.Message) (n int), []interface{}) {
return _TransactionOptions_OneofMarshaler, _TransactionOptions_OneofUnmarshaler, _TransactionOptions_OneofSizer, []interface{}{
(*TransactionOptions_ReadWrite_)(nil),
(*TransactionOptions_PartitionedDml_)(nil),
(*TransactionOptions_ReadOnly_)(nil),
}
}
@@ -298,6 +406,11 @@ func _TransactionOptions_OneofMarshaler(msg proto.Message, b *proto.Buffer) erro
if err := b.EncodeMessage(x.ReadWrite); err != nil {
return err
}
case *TransactionOptions_PartitionedDml_:
b.EncodeVarint(3<<3 | proto.WireBytes)
if err := b.EncodeMessage(x.PartitionedDml); err != nil {
return err
}
case *TransactionOptions_ReadOnly_:
b.EncodeVarint(2<<3 | proto.WireBytes)
if err := b.EncodeMessage(x.ReadOnly); err != nil {
@@ -321,6 +434,14 @@ func _TransactionOptions_OneofUnmarshaler(msg proto.Message, tag, wire int, b *p
err := b.DecodeMessage(msg)
m.Mode = &TransactionOptions_ReadWrite_{msg}
return true, err
case 3: // mode.partitioned_dml
if wire != proto.WireBytes {
return true, proto.ErrInternalBadWireType
}
msg := new(TransactionOptions_PartitionedDml)
err := b.DecodeMessage(msg)
m.Mode = &TransactionOptions_PartitionedDml_{msg}
return true, err
case 2: // mode.read_only
if wire != proto.WireBytes {
return true, proto.ErrInternalBadWireType
@@ -340,12 +461,17 @@ func _TransactionOptions_OneofSizer(msg proto.Message) (n int) {
switch x := m.Mode.(type) {
case *TransactionOptions_ReadWrite_:
s := proto.Size(x.ReadWrite)
n += proto.SizeVarint(1<<3 | proto.WireBytes)
n += 1 // tag and wire
n += proto.SizeVarint(uint64(s))
n += s
case *TransactionOptions_PartitionedDml_:
s := proto.Size(x.PartitionedDml)
n += 1 // tag and wire
n += proto.SizeVarint(uint64(s))
n += s
case *TransactionOptions_ReadOnly_:
s := proto.Size(x.ReadOnly)
n += proto.SizeVarint(2<<3 | proto.WireBytes)
n += 1 // tag and wire
n += proto.SizeVarint(uint64(s))
n += s
case nil:
@@ -358,12 +484,67 @@ func _TransactionOptions_OneofSizer(msg proto.Message) (n int) {
// Message type to initiate a read-write transaction. Currently this
// transaction type has no options.
type TransactionOptions_ReadWrite struct {
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *TransactionOptions_ReadWrite) Reset() { *m = TransactionOptions_ReadWrite{} }
func (m *TransactionOptions_ReadWrite) String() string { return proto.CompactTextString(m) }
func (*TransactionOptions_ReadWrite) ProtoMessage() {}
func (*TransactionOptions_ReadWrite) Descriptor() ([]byte, []int) { return fileDescriptor5, []int{0, 0} }
func (m *TransactionOptions_ReadWrite) Reset() { *m = TransactionOptions_ReadWrite{} }
func (m *TransactionOptions_ReadWrite) String() string { return proto.CompactTextString(m) }
func (*TransactionOptions_ReadWrite) ProtoMessage() {}
func (*TransactionOptions_ReadWrite) Descriptor() ([]byte, []int) {
return fileDescriptor_a5743daa0b72b00f, []int{0, 0}
}
func (m *TransactionOptions_ReadWrite) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_TransactionOptions_ReadWrite.Unmarshal(m, b)
}
func (m *TransactionOptions_ReadWrite) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_TransactionOptions_ReadWrite.Marshal(b, m, deterministic)
}
func (m *TransactionOptions_ReadWrite) XXX_Merge(src proto.Message) {
xxx_messageInfo_TransactionOptions_ReadWrite.Merge(m, src)
}
func (m *TransactionOptions_ReadWrite) XXX_Size() int {
return xxx_messageInfo_TransactionOptions_ReadWrite.Size(m)
}
func (m *TransactionOptions_ReadWrite) XXX_DiscardUnknown() {
xxx_messageInfo_TransactionOptions_ReadWrite.DiscardUnknown(m)
}
var xxx_messageInfo_TransactionOptions_ReadWrite proto.InternalMessageInfo
// Message type to initiate a Partitioned DML transaction.
type TransactionOptions_PartitionedDml struct {
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *TransactionOptions_PartitionedDml) Reset() { *m = TransactionOptions_PartitionedDml{} }
func (m *TransactionOptions_PartitionedDml) String() string { return proto.CompactTextString(m) }
func (*TransactionOptions_PartitionedDml) ProtoMessage() {}
func (*TransactionOptions_PartitionedDml) Descriptor() ([]byte, []int) {
return fileDescriptor_a5743daa0b72b00f, []int{0, 1}
}
func (m *TransactionOptions_PartitionedDml) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_TransactionOptions_PartitionedDml.Unmarshal(m, b)
}
func (m *TransactionOptions_PartitionedDml) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_TransactionOptions_PartitionedDml.Marshal(b, m, deterministic)
}
func (m *TransactionOptions_PartitionedDml) XXX_Merge(src proto.Message) {
xxx_messageInfo_TransactionOptions_PartitionedDml.Merge(m, src)
}
func (m *TransactionOptions_PartitionedDml) XXX_Size() int {
return xxx_messageInfo_TransactionOptions_PartitionedDml.Size(m)
}
func (m *TransactionOptions_PartitionedDml) XXX_DiscardUnknown() {
xxx_messageInfo_TransactionOptions_PartitionedDml.DiscardUnknown(m)
}
var xxx_messageInfo_TransactionOptions_PartitionedDml proto.InternalMessageInfo
// Message type to initiate a read-only transaction.
type TransactionOptions_ReadOnly struct {
@@ -378,39 +559,70 @@ type TransactionOptions_ReadOnly struct {
TimestampBound isTransactionOptions_ReadOnly_TimestampBound `protobuf_oneof:"timestamp_bound"`
// If true, the Cloud Spanner-selected read timestamp is included in
// the [Transaction][google.spanner.v1.Transaction] message that describes the transaction.
ReturnReadTimestamp bool `protobuf:"varint,6,opt,name=return_read_timestamp,json=returnReadTimestamp" json:"return_read_timestamp,omitempty"`
ReturnReadTimestamp bool `protobuf:"varint,6,opt,name=return_read_timestamp,json=returnReadTimestamp,proto3" json:"return_read_timestamp,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *TransactionOptions_ReadOnly) Reset() { *m = TransactionOptions_ReadOnly{} }
func (m *TransactionOptions_ReadOnly) String() string { return proto.CompactTextString(m) }
func (*TransactionOptions_ReadOnly) ProtoMessage() {}
func (*TransactionOptions_ReadOnly) Descriptor() ([]byte, []int) { return fileDescriptor5, []int{0, 1} }
func (m *TransactionOptions_ReadOnly) Reset() { *m = TransactionOptions_ReadOnly{} }
func (m *TransactionOptions_ReadOnly) String() string { return proto.CompactTextString(m) }
func (*TransactionOptions_ReadOnly) ProtoMessage() {}
func (*TransactionOptions_ReadOnly) Descriptor() ([]byte, []int) {
return fileDescriptor_a5743daa0b72b00f, []int{0, 2}
}
func (m *TransactionOptions_ReadOnly) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_TransactionOptions_ReadOnly.Unmarshal(m, b)
}
func (m *TransactionOptions_ReadOnly) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_TransactionOptions_ReadOnly.Marshal(b, m, deterministic)
}
func (m *TransactionOptions_ReadOnly) XXX_Merge(src proto.Message) {
xxx_messageInfo_TransactionOptions_ReadOnly.Merge(m, src)
}
func (m *TransactionOptions_ReadOnly) XXX_Size() int {
return xxx_messageInfo_TransactionOptions_ReadOnly.Size(m)
}
func (m *TransactionOptions_ReadOnly) XXX_DiscardUnknown() {
xxx_messageInfo_TransactionOptions_ReadOnly.DiscardUnknown(m)
}
var xxx_messageInfo_TransactionOptions_ReadOnly proto.InternalMessageInfo
type isTransactionOptions_ReadOnly_TimestampBound interface {
isTransactionOptions_ReadOnly_TimestampBound()
}
type TransactionOptions_ReadOnly_Strong struct {
Strong bool `protobuf:"varint,1,opt,name=strong,oneof"`
}
type TransactionOptions_ReadOnly_MinReadTimestamp struct {
MinReadTimestamp *google_protobuf3.Timestamp `protobuf:"bytes,2,opt,name=min_read_timestamp,json=minReadTimestamp,oneof"`
}
type TransactionOptions_ReadOnly_MaxStaleness struct {
MaxStaleness *google_protobuf2.Duration `protobuf:"bytes,3,opt,name=max_staleness,json=maxStaleness,oneof"`
}
type TransactionOptions_ReadOnly_ReadTimestamp struct {
ReadTimestamp *google_protobuf3.Timestamp `protobuf:"bytes,4,opt,name=read_timestamp,json=readTimestamp,oneof"`
}
type TransactionOptions_ReadOnly_ExactStaleness struct {
ExactStaleness *google_protobuf2.Duration `protobuf:"bytes,5,opt,name=exact_staleness,json=exactStaleness,oneof"`
Strong bool `protobuf:"varint,1,opt,name=strong,proto3,oneof"`
}
func (*TransactionOptions_ReadOnly_Strong) isTransactionOptions_ReadOnly_TimestampBound() {}
type TransactionOptions_ReadOnly_MinReadTimestamp struct {
MinReadTimestamp *timestamp.Timestamp `protobuf:"bytes,2,opt,name=min_read_timestamp,json=minReadTimestamp,proto3,oneof"`
}
type TransactionOptions_ReadOnly_MaxStaleness struct {
MaxStaleness *duration.Duration `protobuf:"bytes,3,opt,name=max_staleness,json=maxStaleness,proto3,oneof"`
}
type TransactionOptions_ReadOnly_ReadTimestamp struct {
ReadTimestamp *timestamp.Timestamp `protobuf:"bytes,4,opt,name=read_timestamp,json=readTimestamp,proto3,oneof"`
}
type TransactionOptions_ReadOnly_ExactStaleness struct {
ExactStaleness *duration.Duration `protobuf:"bytes,5,opt,name=exact_staleness,json=exactStaleness,proto3,oneof"`
}
func (*TransactionOptions_ReadOnly_Strong) isTransactionOptions_ReadOnly_TimestampBound() {}
func (*TransactionOptions_ReadOnly_MinReadTimestamp) isTransactionOptions_ReadOnly_TimestampBound() {}
func (*TransactionOptions_ReadOnly_MaxStaleness) isTransactionOptions_ReadOnly_TimestampBound() {}
func (*TransactionOptions_ReadOnly_ReadTimestamp) isTransactionOptions_ReadOnly_TimestampBound() {}
func (*TransactionOptions_ReadOnly_ExactStaleness) isTransactionOptions_ReadOnly_TimestampBound() {}
func (*TransactionOptions_ReadOnly_MaxStaleness) isTransactionOptions_ReadOnly_TimestampBound() {}
func (*TransactionOptions_ReadOnly_ReadTimestamp) isTransactionOptions_ReadOnly_TimestampBound() {}
func (*TransactionOptions_ReadOnly_ExactStaleness) isTransactionOptions_ReadOnly_TimestampBound() {}
func (m *TransactionOptions_ReadOnly) GetTimestampBound() isTransactionOptions_ReadOnly_TimestampBound {
if m != nil {
@@ -426,28 +638,28 @@ func (m *TransactionOptions_ReadOnly) GetStrong() bool {
return false
}
func (m *TransactionOptions_ReadOnly) GetMinReadTimestamp() *google_protobuf3.Timestamp {
func (m *TransactionOptions_ReadOnly) GetMinReadTimestamp() *timestamp.Timestamp {
if x, ok := m.GetTimestampBound().(*TransactionOptions_ReadOnly_MinReadTimestamp); ok {
return x.MinReadTimestamp
}
return nil
}
func (m *TransactionOptions_ReadOnly) GetMaxStaleness() *google_protobuf2.Duration {
func (m *TransactionOptions_ReadOnly) GetMaxStaleness() *duration.Duration {
if x, ok := m.GetTimestampBound().(*TransactionOptions_ReadOnly_MaxStaleness); ok {
return x.MaxStaleness
}
return nil
}
func (m *TransactionOptions_ReadOnly) GetReadTimestamp() *google_protobuf3.Timestamp {
func (m *TransactionOptions_ReadOnly) GetReadTimestamp() *timestamp.Timestamp {
if x, ok := m.GetTimestampBound().(*TransactionOptions_ReadOnly_ReadTimestamp); ok {
return x.ReadTimestamp
}
return nil
}
func (m *TransactionOptions_ReadOnly) GetExactStaleness() *google_protobuf2.Duration {
func (m *TransactionOptions_ReadOnly) GetExactStaleness() *duration.Duration {
if x, ok := m.GetTimestampBound().(*TransactionOptions_ReadOnly_ExactStaleness); ok {
return x.ExactStaleness
}
@@ -524,7 +736,7 @@ func _TransactionOptions_ReadOnly_OneofUnmarshaler(msg proto.Message, tag, wire
if wire != proto.WireBytes {
return true, proto.ErrInternalBadWireType
}
msg := new(google_protobuf3.Timestamp)
msg := new(timestamp.Timestamp)
err := b.DecodeMessage(msg)
m.TimestampBound = &TransactionOptions_ReadOnly_MinReadTimestamp{msg}
return true, err
@@ -532,7 +744,7 @@ func _TransactionOptions_ReadOnly_OneofUnmarshaler(msg proto.Message, tag, wire
if wire != proto.WireBytes {
return true, proto.ErrInternalBadWireType
}
msg := new(google_protobuf2.Duration)
msg := new(duration.Duration)
err := b.DecodeMessage(msg)
m.TimestampBound = &TransactionOptions_ReadOnly_MaxStaleness{msg}
return true, err
@@ -540,7 +752,7 @@ func _TransactionOptions_ReadOnly_OneofUnmarshaler(msg proto.Message, tag, wire
if wire != proto.WireBytes {
return true, proto.ErrInternalBadWireType
}
msg := new(google_protobuf3.Timestamp)
msg := new(timestamp.Timestamp)
err := b.DecodeMessage(msg)
m.TimestampBound = &TransactionOptions_ReadOnly_ReadTimestamp{msg}
return true, err
@@ -548,7 +760,7 @@ func _TransactionOptions_ReadOnly_OneofUnmarshaler(msg proto.Message, tag, wire
if wire != proto.WireBytes {
return true, proto.ErrInternalBadWireType
}
msg := new(google_protobuf2.Duration)
msg := new(duration.Duration)
err := b.DecodeMessage(msg)
m.TimestampBound = &TransactionOptions_ReadOnly_ExactStaleness{msg}
return true, err
@@ -562,26 +774,26 @@ func _TransactionOptions_ReadOnly_OneofSizer(msg proto.Message) (n int) {
// timestamp_bound
switch x := m.TimestampBound.(type) {
case *TransactionOptions_ReadOnly_Strong:
n += proto.SizeVarint(1<<3 | proto.WireVarint)
n += 1 // tag and wire
n += 1
case *TransactionOptions_ReadOnly_MinReadTimestamp:
s := proto.Size(x.MinReadTimestamp)
n += proto.SizeVarint(2<<3 | proto.WireBytes)
n += 1 // tag and wire
n += proto.SizeVarint(uint64(s))
n += s
case *TransactionOptions_ReadOnly_MaxStaleness:
s := proto.Size(x.MaxStaleness)
n += proto.SizeVarint(3<<3 | proto.WireBytes)
n += 1 // tag and wire
n += proto.SizeVarint(uint64(s))
n += s
case *TransactionOptions_ReadOnly_ReadTimestamp:
s := proto.Size(x.ReadTimestamp)
n += proto.SizeVarint(4<<3 | proto.WireBytes)
n += 1 // tag and wire
n += proto.SizeVarint(uint64(s))
n += s
case *TransactionOptions_ReadOnly_ExactStaleness:
s := proto.Size(x.ExactStaleness)
n += proto.SizeVarint(5<<3 | proto.WireBytes)
n += 1 // tag and wire
n += proto.SizeVarint(uint64(s))
n += s
case nil:
@@ -608,13 +820,36 @@ type Transaction struct {
//
// A timestamp in RFC3339 UTC \"Zulu\" format, accurate to nanoseconds.
// Example: `"2014-10-02T15:01:23.045123456Z"`.
ReadTimestamp *google_protobuf3.Timestamp `protobuf:"bytes,2,opt,name=read_timestamp,json=readTimestamp" json:"read_timestamp,omitempty"`
ReadTimestamp *timestamp.Timestamp `protobuf:"bytes,2,opt,name=read_timestamp,json=readTimestamp,proto3" json:"read_timestamp,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Transaction) Reset() { *m = Transaction{} }
func (m *Transaction) String() string { return proto.CompactTextString(m) }
func (*Transaction) ProtoMessage() {}
func (*Transaction) Descriptor() ([]byte, []int) { return fileDescriptor5, []int{1} }
func (m *Transaction) Reset() { *m = Transaction{} }
func (m *Transaction) String() string { return proto.CompactTextString(m) }
func (*Transaction) ProtoMessage() {}
func (*Transaction) Descriptor() ([]byte, []int) {
return fileDescriptor_a5743daa0b72b00f, []int{1}
}
func (m *Transaction) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Transaction.Unmarshal(m, b)
}
func (m *Transaction) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Transaction.Marshal(b, m, deterministic)
}
func (m *Transaction) XXX_Merge(src proto.Message) {
xxx_messageInfo_Transaction.Merge(m, src)
}
func (m *Transaction) XXX_Size() int {
return xxx_messageInfo_Transaction.Size(m)
}
func (m *Transaction) XXX_DiscardUnknown() {
xxx_messageInfo_Transaction.DiscardUnknown(m)
}
var xxx_messageInfo_Transaction proto.InternalMessageInfo
func (m *Transaction) GetId() []byte {
if m != nil {
@@ -623,7 +858,7 @@ func (m *Transaction) GetId() []byte {
return nil
}
func (m *Transaction) GetReadTimestamp() *google_protobuf3.Timestamp {
func (m *Transaction) GetReadTimestamp() *timestamp.Timestamp {
if m != nil {
return m.ReadTimestamp
}
@@ -643,31 +878,58 @@ type TransactionSelector struct {
// *TransactionSelector_SingleUse
// *TransactionSelector_Id
// *TransactionSelector_Begin
Selector isTransactionSelector_Selector `protobuf_oneof:"selector"`
Selector isTransactionSelector_Selector `protobuf_oneof:"selector"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *TransactionSelector) Reset() { *m = TransactionSelector{} }
func (m *TransactionSelector) String() string { return proto.CompactTextString(m) }
func (*TransactionSelector) ProtoMessage() {}
func (*TransactionSelector) Descriptor() ([]byte, []int) { return fileDescriptor5, []int{2} }
func (m *TransactionSelector) Reset() { *m = TransactionSelector{} }
func (m *TransactionSelector) String() string { return proto.CompactTextString(m) }
func (*TransactionSelector) ProtoMessage() {}
func (*TransactionSelector) Descriptor() ([]byte, []int) {
return fileDescriptor_a5743daa0b72b00f, []int{2}
}
func (m *TransactionSelector) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_TransactionSelector.Unmarshal(m, b)
}
func (m *TransactionSelector) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_TransactionSelector.Marshal(b, m, deterministic)
}
func (m *TransactionSelector) XXX_Merge(src proto.Message) {
xxx_messageInfo_TransactionSelector.Merge(m, src)
}
func (m *TransactionSelector) XXX_Size() int {
return xxx_messageInfo_TransactionSelector.Size(m)
}
func (m *TransactionSelector) XXX_DiscardUnknown() {
xxx_messageInfo_TransactionSelector.DiscardUnknown(m)
}
var xxx_messageInfo_TransactionSelector proto.InternalMessageInfo
type isTransactionSelector_Selector interface {
isTransactionSelector_Selector()
}
type TransactionSelector_SingleUse struct {
SingleUse *TransactionOptions `protobuf:"bytes,1,opt,name=single_use,json=singleUse,oneof"`
SingleUse *TransactionOptions `protobuf:"bytes,1,opt,name=single_use,json=singleUse,proto3,oneof"`
}
type TransactionSelector_Id struct {
Id []byte `protobuf:"bytes,2,opt,name=id,proto3,oneof"`
}
type TransactionSelector_Begin struct {
Begin *TransactionOptions `protobuf:"bytes,3,opt,name=begin,oneof"`
Begin *TransactionOptions `protobuf:"bytes,3,opt,name=begin,proto3,oneof"`
}
func (*TransactionSelector_SingleUse) isTransactionSelector_Selector() {}
func (*TransactionSelector_Id) isTransactionSelector_Selector() {}
func (*TransactionSelector_Begin) isTransactionSelector_Selector() {}
func (*TransactionSelector_Id) isTransactionSelector_Selector() {}
func (*TransactionSelector_Begin) isTransactionSelector_Selector() {}
func (m *TransactionSelector) GetSelector() isTransactionSelector_Selector {
if m != nil {
@@ -767,16 +1029,16 @@ func _TransactionSelector_OneofSizer(msg proto.Message) (n int) {
switch x := m.Selector.(type) {
case *TransactionSelector_SingleUse:
s := proto.Size(x.SingleUse)
n += proto.SizeVarint(1<<3 | proto.WireBytes)
n += 1 // tag and wire
n += proto.SizeVarint(uint64(s))
n += s
case *TransactionSelector_Id:
n += proto.SizeVarint(2<<3 | proto.WireBytes)
n += 1 // tag and wire
n += proto.SizeVarint(uint64(len(x.Id)))
n += len(x.Id)
case *TransactionSelector_Begin:
s := proto.Size(x.Begin)
n += proto.SizeVarint(3<<3 | proto.WireBytes)
n += 1 // tag and wire
n += proto.SizeVarint(uint64(s))
n += s
case nil:
@@ -789,47 +1051,52 @@ func _TransactionSelector_OneofSizer(msg proto.Message) (n int) {
func init() {
proto.RegisterType((*TransactionOptions)(nil), "google.spanner.v1.TransactionOptions")
proto.RegisterType((*TransactionOptions_ReadWrite)(nil), "google.spanner.v1.TransactionOptions.ReadWrite")
proto.RegisterType((*TransactionOptions_PartitionedDml)(nil), "google.spanner.v1.TransactionOptions.PartitionedDml")
proto.RegisterType((*TransactionOptions_ReadOnly)(nil), "google.spanner.v1.TransactionOptions.ReadOnly")
proto.RegisterType((*Transaction)(nil), "google.spanner.v1.Transaction")
proto.RegisterType((*TransactionSelector)(nil), "google.spanner.v1.TransactionSelector")
}
func init() { proto.RegisterFile("google/spanner/v1/transaction.proto", fileDescriptor5) }
var fileDescriptor5 = []byte{
// 537 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x94, 0xd1, 0x8a, 0xd3, 0x40,
0x14, 0x86, 0xd3, 0x6e, 0xb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6, 0xe8, 0x4f, 0x03, 0x4e, 0x2a, 0x2d, 0x66, 0x24, 0x26,
0x4b, 0xc5, 0x05, 0x7a, 0x0f, 0x20, 0x29, 0x8b, 0x62, 0x12, 0x64, 0xb2, 0x7c, 0xb6, 0xcf, 0x77,
0x7a, 0x65, 0xf9, 0x63, 0x2d, 0xac, 0x9f, 0x25, 0x41, 0x03, 0x8d, 0x9c, 0x63, 0xf5, 0x3c, 0x4b,
0x43, 0xbf, 0x81, 0xfd, 0x05, 0x89, 0x28, 0x33, 0x7b, 0xde, 0x39, 0xb4, 0x70, 0x4d, 0x00, 0x3a,
0xd2, 0x40, 0x4e, 0x7e, 0x35, 0xe0, 0x74, 0xc9, 0x93, 0x7a, 0xc2, 0x64, 0x50, 0x89, 0x98, 0xe6,
0x43, 0x98, 0x36, 0xbe, 0xbe, 0x32, 0xb2, 0x88, 0xc7, 0x98, 0x45, 0x0e, 0x17, 0x91, 0x1b, 0x11,
0xa6, 0x47, 0xe4, 0x16, 0x25, 0x9c, 0x52, 0x59, 0xf9, 0x5b, 0x79, 0x6d, 0x3e, 0x7f, 0x37, 0x1f,
0x7c, 0x28, 0xac, 0xe7, 0x31, 0xcf, 0x42, 0x67, 0x66, 0xfa, 0x5c, 0x8f, 0xff, 0x96, 0x95, 0xb9,
0xae, 0xcc, 0x4d, 0x65, 0x7e, 0x3d, 0x5e, 0xb4, 0x75, 0xf0, 0xcb, 0xff, 0x01, 0x00, 0x00, 0xff,
0xff, 0xa6, 0x28, 0x2f, 0x4a, 0xae, 0x04, 0x00, 0x00,
func init() {
proto.RegisterFile("google/spanner/v1/transaction.proto", fileDescriptor_a5743daa0b72b00f)
}
var fileDescriptor_a5743daa0b72b00f = []byte{
// 573 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x94, 0xdf, 0x6e, 0xd3, 0x3e,
0x14, 0xc7, 0xd3, 0x6e, 0xab, 0xba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