Skip to content

Commit c5883e9

Browse files
feat: Automated regeneration of Spanner client (googleapis#12186)
Auto-created at 2024-09-21 13:11:47 +0000 using the toys pull request generator.
1 parent 1b14f44 commit c5883e9

File tree

5 files changed

+56
-3
lines changed

5 files changed

+56
-3
lines changed

clients/spanner/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ Install this package from [Hex](https://hex.pm) by adding
1111

1212
```elixir
1313
def deps do
14-
[{:google_api_spanner, "~> 0.42"}]
14+
[{:google_api_spanner, "~> 0.43"}]
1515
end
1616
```
1717

clients/spanner/lib/google_api/spanner/v1/metadata.ex

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ defmodule GoogleApi.Spanner.V1 do
2020
API client metadata for GoogleApi.Spanner.V1.
2121
"""
2222

23-
@discovery_revision "20240814"
23+
@discovery_revision "20240910"
2424

2525
def discovery_revision(), do: @discovery_revision
2626
end
Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
# Copyright 2019 Google LLC
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License");
4+
# you may not use this file except in compliance with the License.
5+
# You may obtain a copy of the License at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# Unless required by applicable law or agreed to in writing, software
10+
# distributed under the License is distributed on an "AS IS" BASIS,
11+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
# See the License for the specific language governing permissions and
13+
# limitations under the License.
14+
15+
# NOTE: This file is auto generated by the elixir code generator program.
16+
# Do not edit this file manually.
17+
18+
defmodule GoogleApi.Spanner.V1.Model.MultiplexedSessionPrecommitToken do
19+
@moduledoc """
20+
When a read-write transaction is executed on a multiplexed session, this precommit token is sent back to the client as a part of the [Transaction] message in the BeginTransaction response and also as a part of the [ResultSet] and [PartialResultSet] responses.
21+
22+
## Attributes
23+
24+
* `precommitToken` (*type:* `String.t`, *default:* `nil`) - Opaque precommit token.
25+
* `seqNum` (*type:* `integer()`, *default:* `nil`) - An incrementing seq number is generated on every precommit token that is returned. Clients should remember the precommit token with the highest sequence number from the current transaction attempt.
26+
"""
27+
28+
use GoogleApi.Gax.ModelBase
29+
30+
@type t :: %__MODULE__{
31+
:precommitToken => String.t() | nil,
32+
:seqNum => integer() | nil
33+
}
34+
35+
field(:precommitToken)
36+
field(:seqNum)
37+
end
38+
39+
defimpl Poison.Decoder, for: GoogleApi.Spanner.V1.Model.MultiplexedSessionPrecommitToken do
40+
def decode(value, options) do
41+
GoogleApi.Spanner.V1.Model.MultiplexedSessionPrecommitToken.decode(value, options)
42+
end
43+
end
44+
45+
defimpl Poison.Encoder, for: GoogleApi.Spanner.V1.Model.MultiplexedSessionPrecommitToken do
46+
def encode(value, options) do
47+
GoogleApi.Gax.ModelBase.encode(value, options)
48+
end
49+
end

clients/spanner/lib/google_api/spanner/v1/model/transaction.ex

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,17 +22,21 @@ defmodule GoogleApi.Spanner.V1.Model.Transaction do
2222
## Attributes
2323
2424
* `id` (*type:* `String.t`, *default:* `nil`) - `id` may be used to identify the transaction in subsequent Read, ExecuteSql, Commit, or Rollback calls. Single-use read-only transactions do not have IDs, because single-use transactions do not support multiple requests.
25+
* `precommitToken` (*type:* `GoogleApi.Spanner.V1.Model.MultiplexedSessionPrecommitToken.t`, *default:* `nil`) - A precommit token will be included in the response of a BeginTransaction request if the read-write transaction is on a multiplexed session and a mutation_key was specified in the BeginTransaction. The precommit token with the highest sequence number from this transaction attempt should be passed to the Commit request for this transaction.
2526
* `readTimestamp` (*type:* `DateTime.t`, *default:* `nil`) - For snapshot read-only transactions, the read timestamp chosen for the transaction. Not returned by default: see TransactionOptions.ReadOnly.return_read_timestamp. A timestamp in RFC3339 UTC \\"Zulu\\" format, accurate to nanoseconds. Example: `"2014-10-02T15:01:23.045123456Z"`.
2627
"""
2728

2829
use GoogleApi.Gax.ModelBase
2930

3031
@type t :: %__MODULE__{
3132
:id => String.t() | nil,
33+
:precommitToken =>
34+
GoogleApi.Spanner.V1.Model.MultiplexedSessionPrecommitToken.t() | nil,
3235
:readTimestamp => DateTime.t() | nil
3336
}
3437

3538
field(:id)
39+
field(:precommitToken, as: GoogleApi.Spanner.V1.Model.MultiplexedSessionPrecommitToken)
3640
field(:readTimestamp, as: DateTime)
3741
end
3842

clients/spanner/mix.exs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
defmodule GoogleApi.Spanner.Mixfile do
1919
use Mix.Project
2020

21-
@version "0.42.1"
21+
@version "0.43.0"
2222

2323
def project() do
2424
[

0 commit comments

Comments
 (0)