statelydb 0.21.0 → 0.23.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/api/db/continue_list_pb.rb +1 -1
- data/lib/api/db/continue_scan_pb.rb +1 -1
- data/lib/api/db/delete_pb.rb +1 -1
- data/lib/api/db/get_pb.rb +1 -1
- data/lib/api/db/list_pb.rb +1 -1
- data/lib/api/db/scan_pb.rb +1 -1
- data/lib/api/db/scan_root_paths_pb.rb +1 -1
- data/lib/api/db/sync_list_pb.rb +1 -1
- data/lib/common/auth/interceptor.rb +1 -1
- data/lib/common/auth/token_fetcher.rb +2 -2
- data/lib/key_path.rb +2 -2
- data/lib/statelydb.rb +2 -2
- data/lib/transaction/transaction.rb +4 -4
- data/rbi/auth/get_auth_token_pb.rbi +169 -0
- data/rbi/auth/service_pb.rbi +3 -0
- data/rbi/auth/service_services_pb.rbi +31 -0
- data/rbi/db/continue_list_pb.rbi +163 -0
- data/rbi/db/continue_scan_pb.rbi +123 -0
- data/rbi/db/delete_pb.rbi +329 -0
- data/rbi/db/get_pb.rbi +293 -0
- data/rbi/db/item_pb.rbi +125 -0
- data/rbi/db/item_property_pb.rbi +24 -0
- data/rbi/db/list_pb.rbi +472 -0
- data/rbi/db/list_token_pb.rbi +154 -0
- data/rbi/db/put_pb.rbi +314 -0
- data/rbi/db/scan_pb.rbi +370 -0
- data/rbi/db/scan_root_paths_pb.rbi +301 -0
- data/rbi/db/service_pb.rbi +3 -0
- data/rbi/db/service_services_pb.rbi +184 -0
- data/rbi/db/sync_list_pb.rbi +452 -0
- data/rbi/db/transaction_pb.rbi +1366 -0
- data/rbi/errors/error_details_pb.rbi +146 -0
- data/rbi/statelydb.rbi +12 -83
- data/sig/statelydb.rbs +8 -8
- metadata +20 -1
@@ -0,0 +1,146 @@
|
|
1
|
+
# Code generated by protoc-gen-rbi. DO NOT EDIT.
|
2
|
+
# source: errors/error_details.proto
|
3
|
+
# typed: strict
|
4
|
+
|
5
|
+
# StatelyErrorDetails is a message containing detailed error information.
|
6
|
+
# This is returned from the Stately API via Connect error details:
|
7
|
+
# https://connectrpc.com/docs/go/errors#error-details
|
8
|
+
# Note: As a customer, you should not need to handle this message directly unless writing
|
9
|
+
# a custom low-level SDK. Instead, language-specific SDKs will provide a more user-friendly
|
10
|
+
# error object that wraps this message.
|
11
|
+
class Stately::Errors::StatelyErrorDetails
|
12
|
+
include ::Google::Protobuf::MessageExts
|
13
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
14
|
+
|
15
|
+
sig do
|
16
|
+
params(
|
17
|
+
stately_code: T.nilable(String),
|
18
|
+
message: T.nilable(String),
|
19
|
+
upstream_cause: T.nilable(String),
|
20
|
+
code: T.nilable(Integer)
|
21
|
+
).void
|
22
|
+
end
|
23
|
+
def initialize(
|
24
|
+
stately_code: "",
|
25
|
+
message: "",
|
26
|
+
upstream_cause: "",
|
27
|
+
code: 0
|
28
|
+
)
|
29
|
+
end
|
30
|
+
|
31
|
+
# stately_code is the error code that was returned by the Stately API.
|
32
|
+
# The full list of codes is available at https://docs.stately.cloud/api/error-codes/
|
33
|
+
# and documentation on a specific code can be found at https://docs.stately.cloud/api/error-codes/#{stately_code}
|
34
|
+
sig { returns(String) }
|
35
|
+
def stately_code
|
36
|
+
end
|
37
|
+
|
38
|
+
# stately_code is the error code that was returned by the Stately API.
|
39
|
+
# The full list of codes is available at https://docs.stately.cloud/api/error-codes/
|
40
|
+
# and documentation on a specific code can be found at https://docs.stately.cloud/api/error-codes/#{stately_code}
|
41
|
+
sig { params(value: String).void }
|
42
|
+
def stately_code=(value)
|
43
|
+
end
|
44
|
+
|
45
|
+
# stately_code is the error code that was returned by the Stately API.
|
46
|
+
# The full list of codes is available at https://docs.stately.cloud/api/error-codes/
|
47
|
+
# and documentation on a specific code can be found at https://docs.stately.cloud/api/error-codes/#{stately_code}
|
48
|
+
sig { void }
|
49
|
+
def clear_stately_code
|
50
|
+
end
|
51
|
+
|
52
|
+
# message is a human-readable error message that can be displayed to the user that
|
53
|
+
# provides more context about the error.
|
54
|
+
sig { returns(String) }
|
55
|
+
def message
|
56
|
+
end
|
57
|
+
|
58
|
+
# message is a human-readable error message that can be displayed to the user that
|
59
|
+
# provides more context about the error.
|
60
|
+
sig { params(value: String).void }
|
61
|
+
def message=(value)
|
62
|
+
end
|
63
|
+
|
64
|
+
# message is a human-readable error message that can be displayed to the user that
|
65
|
+
# provides more context about the error.
|
66
|
+
sig { void }
|
67
|
+
def clear_message
|
68
|
+
end
|
69
|
+
|
70
|
+
# upstream_cause is additional information about the error that can be used to help debug the error,
|
71
|
+
# This field will only optionally be supplied by the Stately API.
|
72
|
+
# Note: This may row over as the error is passed through multiple services.
|
73
|
+
sig { returns(String) }
|
74
|
+
def upstream_cause
|
75
|
+
end
|
76
|
+
|
77
|
+
# upstream_cause is additional information about the error that can be used to help debug the error,
|
78
|
+
# This field will only optionally be supplied by the Stately API.
|
79
|
+
# Note: This may row over as the error is passed through multiple services.
|
80
|
+
sig { params(value: String).void }
|
81
|
+
def upstream_cause=(value)
|
82
|
+
end
|
83
|
+
|
84
|
+
# upstream_cause is additional information about the error that can be used to help debug the error,
|
85
|
+
# This field will only optionally be supplied by the Stately API.
|
86
|
+
# Note: This may row over as the error is passed through multiple services.
|
87
|
+
sig { void }
|
88
|
+
def clear_upstream_cause
|
89
|
+
end
|
90
|
+
|
91
|
+
# The Connect/gRPC code associated with this error. This generally isn't set,
|
92
|
+
# because the overall API response has an error code. But this can be used in
|
93
|
+
# the case that we're returning multiple different errors, or communicating
|
94
|
+
# errors across non-Connect APIs.
|
95
|
+
sig { returns(Integer) }
|
96
|
+
def code
|
97
|
+
end
|
98
|
+
|
99
|
+
# The Connect/gRPC code associated with this error. This generally isn't set,
|
100
|
+
# because the overall API response has an error code. But this can be used in
|
101
|
+
# the case that we're returning multiple different errors, or communicating
|
102
|
+
# errors across non-Connect APIs.
|
103
|
+
sig { params(value: Integer).void }
|
104
|
+
def code=(value)
|
105
|
+
end
|
106
|
+
|
107
|
+
# The Connect/gRPC code associated with this error. This generally isn't set,
|
108
|
+
# because the overall API response has an error code. But this can be used in
|
109
|
+
# the case that we're returning multiple different errors, or communicating
|
110
|
+
# errors across non-Connect APIs.
|
111
|
+
sig { void }
|
112
|
+
def clear_code
|
113
|
+
end
|
114
|
+
|
115
|
+
sig { params(field: String).returns(T.untyped) }
|
116
|
+
def [](field)
|
117
|
+
end
|
118
|
+
|
119
|
+
sig { params(field: String, value: T.untyped).void }
|
120
|
+
def []=(field, value)
|
121
|
+
end
|
122
|
+
|
123
|
+
sig { returns(T::Hash[Symbol, T.untyped]) }
|
124
|
+
def to_h
|
125
|
+
end
|
126
|
+
|
127
|
+
sig { params(str: String).returns(Stately::Errors::StatelyErrorDetails) }
|
128
|
+
def self.decode(str)
|
129
|
+
end
|
130
|
+
|
131
|
+
sig { params(msg: Stately::Errors::StatelyErrorDetails).returns(String) }
|
132
|
+
def self.encode(msg)
|
133
|
+
end
|
134
|
+
|
135
|
+
sig { params(str: String, kw: T.untyped).returns(Stately::Errors::StatelyErrorDetails) }
|
136
|
+
def self.decode_json(str, **kw)
|
137
|
+
end
|
138
|
+
|
139
|
+
sig { params(msg: Stately::Errors::StatelyErrorDetails, kw: T.untyped).returns(String) }
|
140
|
+
def self.encode_json(msg, **kw)
|
141
|
+
end
|
142
|
+
|
143
|
+
sig { returns(::Google::Protobuf::Descriptor) }
|
144
|
+
def self.descriptor
|
145
|
+
end
|
146
|
+
end
|
data/rbi/statelydb.rbi
CHANGED
@@ -158,7 +158,7 @@ module StatelyDB
|
|
158
158
|
# _@param_ `namespace`
|
159
159
|
#
|
160
160
|
# _@param_ `identifier`
|
161
|
-
sig { params(namespace: String, identifier: T.nilable(T.any(String, StatelyDB::UUID, T.untyped))).returns(KeyPath) }
|
161
|
+
sig { params(namespace: String, identifier: T.nilable(T.any(String, StatelyDB::UUID, T.untyped))).returns(StatelyDB::KeyPath) }
|
162
162
|
def with(namespace, identifier = nil); end
|
163
163
|
|
164
164
|
sig { returns(String) }
|
@@ -179,7 +179,7 @@ module StatelyDB
|
|
179
179
|
# ```ruby
|
180
180
|
# keypath = KeyPath.with("genres", "rock").with("artists", "the-beatles")
|
181
181
|
# ```
|
182
|
-
sig { params(namespace: String, identifier: T.nilable(T.any(String, StatelyDB::UUID, T.untyped))).returns(KeyPath) }
|
182
|
+
sig { params(namespace: String, identifier: T.nilable(T.any(String, StatelyDB::UUID, T.untyped))).returns(StatelyDB::KeyPath) }
|
183
183
|
def self.with(namespace, identifier = nil); end
|
184
184
|
|
185
185
|
# If the value is a binary string, encode it as a url-safe base64 string with padding removed.
|
@@ -210,7 +210,7 @@ module StatelyDB
|
|
210
210
|
params(
|
211
211
|
store_id: Integer,
|
212
212
|
schema: Module,
|
213
|
-
token_provider: T.nilable(Common::Auth::TokenProvider),
|
213
|
+
token_provider: T.nilable(StatelyDB::Common::Auth::TokenProvider),
|
214
214
|
endpoint: T.nilable(String),
|
215
215
|
region: T.nilable(String),
|
216
216
|
no_auth: T::Boolean
|
@@ -321,7 +321,7 @@ module StatelyDB
|
|
321
321
|
sig do
|
322
322
|
params(
|
323
323
|
limit: Integer,
|
324
|
-
item_types: T::Array[T.any(Class, String)],
|
324
|
+
item_types: T::Array[T.any(T::Class[T.anything], String)],
|
325
325
|
total_segments: T.nilable(Integer),
|
326
326
|
segment_index: T.nilable(Integer)
|
327
327
|
).returns(T.any(T::Array[StatelyDB::Item], StatelyDB::Token))
|
@@ -450,7 +450,7 @@ module StatelyDB
|
|
450
450
|
# _@param_ `resp` — the response to process
|
451
451
|
#
|
452
452
|
# _@return_ — the result of the sync operation
|
453
|
-
sig { params(resp:
|
453
|
+
sig { params(resp: Stately::Db::GetResponse).returns(StatelyDB::SyncResult) }
|
454
454
|
def process_sync_response(resp); end
|
455
455
|
end
|
456
456
|
|
@@ -530,7 +530,7 @@ module StatelyDB
|
|
530
530
|
# GRPC interceptor to authenticate against Stately and append bearer tokens to outgoing requests
|
531
531
|
class Interceptor < GRPC::ClientInterceptor
|
532
532
|
# _@param_ `token_provider` — The token provider to use for authentication
|
533
|
-
sig { params(token_provider: TokenProvider).void }
|
533
|
+
sig { params(token_provider: StatelyDB::Common::Auth::TokenProvider).void }
|
534
534
|
def initialize(token_provider: AuthTokenProvider.new); end
|
535
535
|
|
536
536
|
# gRPC client unary interceptor
|
@@ -654,7 +654,7 @@ module StatelyDB
|
|
654
654
|
# Get the current access token
|
655
655
|
#
|
656
656
|
# _@return_ — The fetched TokenResult
|
657
|
-
sig { returns(TokenResult) }
|
657
|
+
sig { returns(StatelyDB::Common::Auth::TokenResult) }
|
658
658
|
def fetch; end
|
659
659
|
|
660
660
|
# Close the token provider and kill any background operations
|
@@ -664,15 +664,6 @@ module StatelyDB
|
|
664
664
|
|
665
665
|
# StatelyAccessTokenFetcher is a TokenFetcher that fetches tokens from the StatelyDB API
|
666
666
|
class StatelyAccessTokenFetcher < StatelyDB::Common::Auth::TokenFetcher
|
667
|
-
NON_RETRYABLE_ERRORS = T.let([
|
668
|
-
GRPC::Core::StatusCodes::UNAUTHENTICATED,
|
669
|
-
GRPC::Core::StatusCodes::PERMISSION_DENIED,
|
670
|
-
GRPC::Core::StatusCodes::NOT_FOUND,
|
671
|
-
GRPC::Core::StatusCodes::UNIMPLEMENTED,
|
672
|
-
GRPC::Core::StatusCodes::INVALID_ARGUMENT
|
673
|
-
].freeze, T.untyped)
|
674
|
-
RETRY_ATTEMPTS = T.let(10, T.untyped)
|
675
|
-
|
676
667
|
# _@param_ `endpoint` — The endpoint of the OAuth server
|
677
668
|
#
|
678
669
|
# _@param_ `access_key` — The StatelyDB access key credential
|
@@ -684,7 +675,7 @@ module StatelyDB
|
|
684
675
|
# Fetch a new token from the StatelyDB API
|
685
676
|
#
|
686
677
|
# _@return_ — The fetched TokenResult
|
687
|
-
sig { returns(TokenResult) }
|
678
|
+
sig { returns(StatelyDB::Common::Auth::TokenResult) }
|
688
679
|
def fetch; end
|
689
680
|
|
690
681
|
# Close the token provider and kill any background operations
|
@@ -862,8 +853,8 @@ module StatelyDB
|
|
862
853
|
#
|
863
854
|
# _@param_ `store_id` — the StatelyDB Store to transact against
|
864
855
|
#
|
865
|
-
# _@param_ `schema` — the
|
866
|
-
sig { params(stub: ::Stately::Db::DatabaseService::Stub, store_id: Integer, schema:
|
856
|
+
# _@param_ `schema` — the generated Schema module to use for mapping StatelyDB Items.
|
857
|
+
sig { params(stub: ::Stately::Db::DatabaseService::Stub, store_id: Integer, schema: Module).void }
|
867
858
|
def initialize(stub:, store_id:, schema:); end
|
868
859
|
|
869
860
|
# Send a request and wait for a response
|
@@ -1066,7 +1057,7 @@ module StatelyDB
|
|
1066
1057
|
# _@param_ `req` — the request
|
1067
1058
|
#
|
1068
1059
|
# _@return_ — the response type
|
1069
|
-
sig { params(req: ::Stately::Db::TransactionRequest).returns(Class) }
|
1060
|
+
sig { params(req: ::Stately::Db::TransactionRequest).returns(T::Class[T.anything]) }
|
1070
1061
|
def infer_response_type_from_request(req); end
|
1071
1062
|
|
1072
1063
|
# We are using a oneof inside the TransactionResponse to determine the type of response. The ruby
|
@@ -1075,7 +1066,7 @@ module StatelyDB
|
|
1075
1066
|
# _@param_ `resp` — the response
|
1076
1067
|
#
|
1077
1068
|
# _@return_ — the response type
|
1078
|
-
sig { params(resp: ::Stately::Db::TransactionResponse).returns(Class) }
|
1069
|
+
sig { params(resp: ::Stately::Db::TransactionResponse).returns(T::Class[T.anything]) }
|
1079
1070
|
def infer_response_type_from_response(resp); end
|
1080
1071
|
|
1081
1072
|
# Result represents the results of a transaction
|
@@ -1105,55 +1096,7 @@ end
|
|
1105
1096
|
|
1106
1097
|
module Stately
|
1107
1098
|
module Db
|
1108
|
-
GetRequest = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.GetRequest").msgclass, T.untyped)
|
1109
|
-
GetItem = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.GetItem").msgclass, T.untyped)
|
1110
|
-
GetResponse = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.GetResponse").msgclass, T.untyped)
|
1111
|
-
PutRequest = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.PutRequest").msgclass, T.untyped)
|
1112
|
-
PutItem = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.PutItem").msgclass, T.untyped)
|
1113
|
-
PutResponse = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.PutResponse").msgclass, T.untyped)
|
1114
|
-
Item = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.Item").msgclass, T.untyped)
|
1115
|
-
BeginListRequest = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.BeginListRequest").msgclass, T.untyped)
|
1116
|
-
ListResponse = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.ListResponse").msgclass, T.untyped)
|
1117
|
-
ListPartialResult = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.ListPartialResult").msgclass, T.untyped)
|
1118
|
-
ListFinished = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.ListFinished").msgclass, T.untyped)
|
1119
|
-
SortDirection = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.SortDirection").enummodule, T.untyped)
|
1120
|
-
FilterCondition = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.FilterCondition").msgclass, T.untyped)
|
1121
|
-
BeginScanRequest = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.BeginScanRequest").msgclass, T.untyped)
|
1122
|
-
SegmentationParams = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.SegmentationParams").msgclass, T.untyped)
|
1123
|
-
DeleteRequest = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.DeleteRequest").msgclass, T.untyped)
|
1124
|
-
DeleteItem = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.DeleteItem").msgclass, T.untyped)
|
1125
|
-
DeleteResult = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.DeleteResult").msgclass, T.untyped)
|
1126
|
-
DeleteResponse = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.DeleteResponse").msgclass, T.untyped)
|
1127
|
-
SyncListRequest = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.SyncListRequest").msgclass, T.untyped)
|
1128
|
-
SyncListResponse = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.SyncListResponse").msgclass, T.untyped)
|
1129
|
-
SyncListReset = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.SyncListReset").msgclass, T.untyped)
|
1130
|
-
SyncListPartialResponse = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.SyncListPartialResponse").msgclass, T.untyped)
|
1131
|
-
DeletedItem = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.DeletedItem").msgclass, T.untyped)
|
1132
|
-
ListToken = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.ListToken").msgclass, T.untyped)
|
1133
|
-
TransactionRequest = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.TransactionRequest").msgclass, T.untyped)
|
1134
|
-
TransactionResponse = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.TransactionResponse").msgclass, T.untyped)
|
1135
|
-
TransactionBegin = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.TransactionBegin").msgclass, T.untyped)
|
1136
|
-
TransactionGet = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.TransactionGet").msgclass, T.untyped)
|
1137
|
-
TransactionBeginList = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.TransactionBeginList").msgclass, T.untyped)
|
1138
|
-
TransactionContinueList = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.TransactionContinueList").msgclass, T.untyped)
|
1139
|
-
TransactionPut = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.TransactionPut").msgclass, T.untyped)
|
1140
|
-
TransactionDelete = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.TransactionDelete").msgclass, T.untyped)
|
1141
|
-
TransactionGetResponse = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.TransactionGetResponse").msgclass, T.untyped)
|
1142
|
-
GeneratedID = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.GeneratedID").msgclass, T.untyped)
|
1143
|
-
TransactionPutAck = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.TransactionPutAck").msgclass, T.untyped)
|
1144
|
-
TransactionListResponse = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.TransactionListResponse").msgclass, T.untyped)
|
1145
|
-
TransactionFinished = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.TransactionFinished").msgclass, T.untyped)
|
1146
|
-
ContinueListRequest = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.ContinueListRequest").msgclass, T.untyped)
|
1147
|
-
ContinueListDirection = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.ContinueListDirection").enummodule, T.untyped)
|
1148
|
-
ContinueScanRequest = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.ContinueScanRequest").msgclass, T.untyped)
|
1149
|
-
SortableProperty = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.SortableProperty").enummodule, T.untyped)
|
1150
|
-
ScanRootPathsRequest = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.ScanRootPathsRequest").msgclass, T.untyped)
|
1151
|
-
ScanRootPathsResponse = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.ScanRootPathsResponse").msgclass, T.untyped)
|
1152
|
-
ScanRootPathResult = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.db.ScanRootPathResult").msgclass, T.untyped)
|
1153
|
-
|
1154
1099
|
module DatabaseService
|
1155
|
-
Stub = T.let(Service.rpc_stub_class, T.untyped)
|
1156
|
-
|
1157
1100
|
# DatabaseService is the service for creating, reading, updating and deleting data
|
1158
1101
|
# in a StatelyDB Store. Creating and modifying Stores is done by
|
1159
1102
|
# stately.dbmanagement.ManagementService.
|
@@ -1164,12 +1107,7 @@ module Stately
|
|
1164
1107
|
end
|
1165
1108
|
|
1166
1109
|
module Auth
|
1167
|
-
GetAuthTokenRequest = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.auth.GetAuthTokenRequest").msgclass, T.untyped)
|
1168
|
-
GetAuthTokenResponse = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.auth.GetAuthTokenResponse").msgclass, T.untyped)
|
1169
|
-
|
1170
1110
|
module AuthService
|
1171
|
-
Stub = T.let(Service.rpc_stub_class, T.untyped)
|
1172
|
-
|
1173
1111
|
# AuthService is the service for vending access tokens used to connect to
|
1174
1112
|
# StatelyDB. This API is meant to be used from SDKs. Access Keys are created
|
1175
1113
|
# and managed from the stately.dbmanagement.UserService.
|
@@ -1180,17 +1118,8 @@ module Stately
|
|
1180
1118
|
end
|
1181
1119
|
|
1182
1120
|
module Errors
|
1183
|
-
StatelyErrorDetails = T.let(::Google::Protobuf::DescriptorPool.generated_pool.lookup("stately.errors.StatelyErrorDetails").msgclass, T.untyped)
|
1184
1121
|
end
|
1185
1122
|
end
|
1186
1123
|
|
1187
1124
|
module StatelyCode
|
1188
|
-
CACHED_SCHEMA_TOO_OLD = T.let("CachedSchemaTooOld", T.untyped)
|
1189
|
-
CONCURRENT_MODIFICATION = T.let("ConcurrentModification", T.untyped)
|
1190
|
-
CONDITIONAL_CHECK_FAILED = T.let("ConditionalCheckFailed", T.untyped)
|
1191
|
-
ITEM_REUSED_WITH_DIFFERENT_KEY_PATH = T.let("ItemReusedWithDifferentKeyPath", T.untyped)
|
1192
|
-
NON_RECOVERABLE_TRANSACTION = T.let("NonRecoverableTransaction", T.untyped)
|
1193
|
-
STORE_IN_USE = T.let("StoreInUse", T.untyped)
|
1194
|
-
STORE_REQUEST_LIMIT_EXCEEDED = T.let("StoreRequestLimitExceeded", T.untyped)
|
1195
|
-
STORE_THROUGHPUT_EXCEEDED = T.let("StoreThroughputExceeded", T.untyped)
|
1196
1125
|
end
|
data/sig/statelydb.rbs
CHANGED
@@ -130,7 +130,7 @@ module StatelyDB
|
|
130
130
|
# _@param_ `namespace`
|
131
131
|
#
|
132
132
|
# _@param_ `identifier`
|
133
|
-
def with: (String namespace, ?(String | StatelyDB::UUID | _ToS)? identifier) -> KeyPath
|
133
|
+
def with: (String namespace, ?(String | StatelyDB::UUID | _ToS)? identifier) -> StatelyDB::KeyPath
|
134
134
|
|
135
135
|
def to_str: () -> String
|
136
136
|
|
@@ -147,7 +147,7 @@ module StatelyDB
|
|
147
147
|
# ```ruby
|
148
148
|
# keypath = KeyPath.with("genres", "rock").with("artists", "the-beatles")
|
149
149
|
# ```
|
150
|
-
def self.with: (String namespace, ?(String | StatelyDB::UUID | _ToS)? identifier) -> KeyPath
|
150
|
+
def self.with: (String namespace, ?(String | StatelyDB::UUID | _ToS)? identifier) -> StatelyDB::KeyPath
|
151
151
|
|
152
152
|
# If the value is a binary string, encode it as a url-safe base64 string with padding removed.
|
153
153
|
#
|
@@ -175,7 +175,7 @@ module StatelyDB
|
|
175
175
|
def initialize: (
|
176
176
|
store_id: Integer,
|
177
177
|
schema: Module,
|
178
|
-
?token_provider: Common::Auth::TokenProvider?,
|
178
|
+
?token_provider: StatelyDB::Common::Auth::TokenProvider?,
|
179
179
|
?endpoint: String?,
|
180
180
|
?region: String?,
|
181
181
|
?no_auth: bool
|
@@ -464,7 +464,7 @@ module StatelyDB
|
|
464
464
|
# GRPC interceptor to authenticate against Stately and append bearer tokens to outgoing requests
|
465
465
|
class Interceptor < GRPC::ClientInterceptor
|
466
466
|
# _@param_ `token_provider` — The token provider to use for authentication
|
467
|
-
def initialize: (?token_provider: TokenProvider) -> void
|
467
|
+
def initialize: (?token_provider: StatelyDB::Common::Auth::TokenProvider) -> void
|
468
468
|
|
469
469
|
# gRPC client unary interceptor
|
470
470
|
#
|
@@ -571,7 +571,7 @@ module StatelyDB
|
|
571
571
|
# Get the current access token
|
572
572
|
#
|
573
573
|
# _@return_ — The fetched TokenResult
|
574
|
-
def fetch: () -> TokenResult
|
574
|
+
def fetch: () -> StatelyDB::Common::Auth::TokenResult
|
575
575
|
|
576
576
|
# Close the token provider and kill any background operations
|
577
577
|
def close: () -> void
|
@@ -592,7 +592,7 @@ module StatelyDB
|
|
592
592
|
# Fetch a new token from the StatelyDB API
|
593
593
|
#
|
594
594
|
# _@return_ — The fetched TokenResult
|
595
|
-
def fetch: () -> TokenResult
|
595
|
+
def fetch: () -> StatelyDB::Common::Auth::TokenResult
|
596
596
|
|
597
597
|
# Close the token provider and kill any background operations
|
598
598
|
def close: () -> void
|
@@ -747,8 +747,8 @@ module StatelyDB
|
|
747
747
|
#
|
748
748
|
# _@param_ `store_id` — the StatelyDB Store to transact against
|
749
749
|
#
|
750
|
-
# _@param_ `schema` — the
|
751
|
-
def initialize: (stub: ::Stately::Db::DatabaseService::Stub, store_id: Integer, schema:
|
750
|
+
# _@param_ `schema` — the generated Schema module to use for mapping StatelyDB Items.
|
751
|
+
def initialize: (stub: ::Stately::Db::DatabaseService::Stub, store_id: Integer, schema: Module) -> void
|
752
752
|
|
753
753
|
# Send a request and wait for a response
|
754
754
|
#
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: statelydb
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.23.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Stately Cloud, Inc.
|
@@ -107,6 +107,25 @@ files:
|
|
107
107
|
- lib/transaction/queue.rb
|
108
108
|
- lib/transaction/transaction.rb
|
109
109
|
- lib/uuid.rb
|
110
|
+
- rbi/auth/get_auth_token_pb.rbi
|
111
|
+
- rbi/auth/service_pb.rbi
|
112
|
+
- rbi/auth/service_services_pb.rbi
|
113
|
+
- rbi/db/continue_list_pb.rbi
|
114
|
+
- rbi/db/continue_scan_pb.rbi
|
115
|
+
- rbi/db/delete_pb.rbi
|
116
|
+
- rbi/db/get_pb.rbi
|
117
|
+
- rbi/db/item_pb.rbi
|
118
|
+
- rbi/db/item_property_pb.rbi
|
119
|
+
- rbi/db/list_pb.rbi
|
120
|
+
- rbi/db/list_token_pb.rbi
|
121
|
+
- rbi/db/put_pb.rbi
|
122
|
+
- rbi/db/scan_pb.rbi
|
123
|
+
- rbi/db/scan_root_paths_pb.rbi
|
124
|
+
- rbi/db/service_pb.rbi
|
125
|
+
- rbi/db/service_services_pb.rbi
|
126
|
+
- rbi/db/sync_list_pb.rbi
|
127
|
+
- rbi/db/transaction_pb.rbi
|
128
|
+
- rbi/errors/error_details_pb.rbi
|
110
129
|
- rbi/statelydb.rbi
|
111
130
|
- sig/statelydb.rbs
|
112
131
|
homepage: https://docs.stately.cloud/clients/ruby/
|