gcloud 0.6.3 → 0.7.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (175) hide show
  1. checksums.yaml +8 -8
  2. data/AUTHENTICATION.md +13 -9
  3. data/CHANGELOG.md +8 -3
  4. data/OVERVIEW.md +46 -8
  5. data/lib/gcloud.rb +123 -117
  6. data/lib/gcloud/backoff.rb +43 -15
  7. data/lib/gcloud/bigquery.rb +211 -195
  8. data/lib/gcloud/bigquery/connection.rb +9 -9
  9. data/lib/gcloud/bigquery/copy_job.rb +15 -16
  10. data/lib/gcloud/bigquery/credentials.rb +3 -3
  11. data/lib/gcloud/bigquery/data.rb +12 -11
  12. data/lib/gcloud/bigquery/dataset.rb +162 -216
  13. data/lib/gcloud/bigquery/dataset/access.rb +59 -43
  14. data/lib/gcloud/bigquery/dataset/list.rb +3 -3
  15. data/lib/gcloud/bigquery/errors.rb +9 -5
  16. data/lib/gcloud/bigquery/extract_job.rb +18 -18
  17. data/lib/gcloud/bigquery/insert_response.rb +7 -4
  18. data/lib/gcloud/bigquery/job.rb +48 -44
  19. data/lib/gcloud/bigquery/job/list.rb +3 -3
  20. data/lib/gcloud/bigquery/load_job.rb +24 -25
  21. data/lib/gcloud/bigquery/project.rb +145 -204
  22. data/lib/gcloud/bigquery/query_data.rb +10 -9
  23. data/lib/gcloud/bigquery/query_job.rb +23 -32
  24. data/lib/gcloud/bigquery/table.rb +238 -280
  25. data/lib/gcloud/bigquery/table/list.rb +3 -3
  26. data/lib/gcloud/bigquery/table/schema.rb +79 -87
  27. data/lib/gcloud/bigquery/view.rb +69 -82
  28. data/lib/gcloud/credentials.rb +3 -9
  29. data/lib/gcloud/datastore.rb +194 -170
  30. data/lib/gcloud/datastore/connection.rb +12 -8
  31. data/lib/gcloud/datastore/credentials.rb +6 -4
  32. data/lib/gcloud/datastore/dataset.rb +74 -141
  33. data/lib/gcloud/datastore/dataset/lookup_results.rb +6 -4
  34. data/lib/gcloud/datastore/dataset/query_results.rb +6 -4
  35. data/lib/gcloud/datastore/entity.rb +81 -76
  36. data/lib/gcloud/datastore/errors.rb +10 -8
  37. data/lib/gcloud/datastore/key.rb +41 -77
  38. data/lib/gcloud/datastore/properties.rb +3 -3
  39. data/lib/gcloud/datastore/proto.rb +7 -4
  40. data/lib/gcloud/datastore/query.rb +26 -3
  41. data/lib/gcloud/datastore/transaction.rb +12 -8
  42. data/lib/gcloud/dns.rb +180 -152
  43. data/lib/gcloud/dns/change.rb +16 -16
  44. data/lib/gcloud/dns/change/list.rb +3 -3
  45. data/lib/gcloud/dns/connection.rb +9 -10
  46. data/lib/gcloud/dns/credentials.rb +3 -3
  47. data/lib/gcloud/dns/errors.rb +9 -5
  48. data/lib/gcloud/dns/importer.rb +17 -23
  49. data/lib/gcloud/dns/project.rb +42 -64
  50. data/lib/gcloud/dns/record.rb +58 -46
  51. data/lib/gcloud/dns/record/list.rb +6 -7
  52. data/lib/gcloud/dns/zone.rb +198 -289
  53. data/lib/gcloud/dns/zone/list.rb +3 -3
  54. data/lib/gcloud/dns/zone/transaction.rb +56 -72
  55. data/lib/gcloud/errors.rb +174 -3
  56. data/lib/gcloud/gce.rb +3 -4
  57. data/lib/gcloud/grpc_utils.rb +76 -0
  58. data/lib/gcloud/logging.rb +308 -0
  59. data/lib/gcloud/logging/credentials.rb +29 -0
  60. data/lib/gcloud/logging/entry.rb +303 -0
  61. data/lib/gcloud/logging/entry/http_request.rb +141 -0
  62. data/lib/gcloud/logging/entry/list.rb +111 -0
  63. data/lib/gcloud/logging/entry/operation.rb +90 -0
  64. data/lib/gcloud/logging/logger.rb +307 -0
  65. data/lib/gcloud/logging/metric.rb +175 -0
  66. data/lib/gcloud/logging/metric/list.rb +98 -0
  67. data/lib/gcloud/logging/project.rb +650 -0
  68. data/lib/gcloud/logging/resource.rb +95 -0
  69. data/lib/gcloud/logging/resource_descriptor.rb +140 -0
  70. data/lib/gcloud/logging/resource_descriptor/list.rb +78 -0
  71. data/lib/gcloud/logging/service.rb +258 -0
  72. data/lib/gcloud/logging/sink.rb +233 -0
  73. data/lib/gcloud/logging/sink/list.rb +97 -0
  74. data/lib/gcloud/pubsub.rb +241 -199
  75. data/lib/gcloud/pubsub/credentials.rb +3 -3
  76. data/lib/gcloud/pubsub/message.rb +26 -20
  77. data/lib/gcloud/pubsub/project.rb +166 -233
  78. data/lib/gcloud/pubsub/received_message.rb +28 -38
  79. data/lib/gcloud/pubsub/service.rb +323 -0
  80. data/lib/gcloud/pubsub/subscription.rb +172 -242
  81. data/lib/gcloud/pubsub/subscription/list.rb +11 -9
  82. data/lib/gcloud/pubsub/topic.rb +152 -271
  83. data/lib/gcloud/pubsub/topic/batch.rb +66 -0
  84. data/lib/gcloud/pubsub/topic/list.rb +9 -7
  85. data/lib/gcloud/resource_manager.rb +158 -138
  86. data/lib/gcloud/resource_manager/connection.rb +6 -5
  87. data/lib/gcloud/resource_manager/credentials.rb +3 -3
  88. data/lib/gcloud/resource_manager/errors.rb +9 -5
  89. data/lib/gcloud/resource_manager/manager.rb +54 -86
  90. data/lib/gcloud/resource_manager/project.rb +69 -88
  91. data/lib/gcloud/resource_manager/project/list.rb +4 -5
  92. data/lib/gcloud/resource_manager/project/updater.rb +12 -14
  93. data/lib/gcloud/search.rb +158 -135
  94. data/lib/gcloud/search/api_client.rb +7 -7
  95. data/lib/gcloud/search/connection.rb +8 -8
  96. data/lib/gcloud/search/credentials.rb +3 -3
  97. data/lib/gcloud/search/document.rb +64 -87
  98. data/lib/gcloud/search/document/list.rb +5 -5
  99. data/lib/gcloud/search/errors.rb +9 -5
  100. data/lib/gcloud/search/field_value.rb +32 -38
  101. data/lib/gcloud/search/field_values.rb +50 -80
  102. data/lib/gcloud/search/fields.rb +44 -65
  103. data/lib/gcloud/search/index.rb +163 -204
  104. data/lib/gcloud/search/index/list.rb +5 -5
  105. data/lib/gcloud/search/project.rb +31 -47
  106. data/lib/gcloud/search/result.rb +27 -31
  107. data/lib/gcloud/search/result/list.rb +6 -6
  108. data/lib/gcloud/storage.rb +224 -190
  109. data/lib/gcloud/storage/bucket.rb +202 -227
  110. data/lib/gcloud/storage/bucket/acl.rb +83 -170
  111. data/lib/gcloud/storage/bucket/cors.rb +31 -34
  112. data/lib/gcloud/storage/bucket/list.rb +3 -3
  113. data/lib/gcloud/storage/connection.rb +11 -7
  114. data/lib/gcloud/storage/credentials.rb +3 -3
  115. data/lib/gcloud/storage/errors.rb +11 -8
  116. data/lib/gcloud/storage/file.rb +129 -171
  117. data/lib/gcloud/storage/file/acl.rb +51 -99
  118. data/lib/gcloud/storage/file/list.rb +3 -3
  119. data/lib/gcloud/storage/file/verifier.rb +3 -2
  120. data/lib/gcloud/storage/project.rb +111 -132
  121. data/lib/gcloud/upload.rb +4 -7
  122. data/lib/gcloud/version.rb +2 -4
  123. data/lib/google/api/annotations.rb +14 -0
  124. data/lib/google/api/http.rb +30 -0
  125. data/lib/google/api/label.rb +24 -0
  126. data/lib/google/api/monitored_resource.rb +25 -0
  127. data/lib/google/datastore/v1beta3/datastore.rb +115 -0
  128. data/lib/google/datastore/v1beta3/datastore_services.rb +33 -0
  129. data/lib/google/datastore/v1beta3/entity.rb +63 -0
  130. data/lib/google/datastore/v1beta3/query.rb +128 -0
  131. data/lib/google/devtools/cloudtrace/v1/trace.rb +78 -0
  132. data/lib/google/devtools/cloudtrace/v1/trace_services.rb +32 -0
  133. data/lib/google/example/library/v1/library.rb +91 -0
  134. data/lib/google/example/library/v1/library_services.rb +40 -0
  135. data/lib/google/iam/v1/iam_policy.rb +33 -0
  136. data/lib/google/iam/v1/iam_policy_services.rb +30 -0
  137. data/lib/google/iam/v1/policy.rb +25 -0
  138. data/lib/google/logging/type/http_request.rb +28 -0
  139. data/lib/google/logging/type/log_severity.rb +27 -0
  140. data/lib/google/logging/v2/log_entry.rb +44 -0
  141. data/lib/google/logging/v2/logging.rb +56 -0
  142. data/lib/google/logging/v2/logging_config.rb +59 -0
  143. data/lib/google/logging/v2/logging_config_services.rb +32 -0
  144. data/lib/google/logging/v2/logging_metrics.rb +51 -0
  145. data/lib/google/logging/v2/logging_metrics_services.rb +32 -0
  146. data/lib/google/logging/v2/logging_services.rb +31 -0
  147. data/lib/google/longrunning/operations.rb +50 -0
  148. data/lib/google/longrunning/operations_services.rb +29 -0
  149. data/lib/google/protobuf/any.rb +17 -0
  150. data/lib/google/protobuf/api.rb +31 -0
  151. data/lib/google/protobuf/descriptor.rb +0 -0
  152. data/lib/google/protobuf/duration.rb +17 -0
  153. data/lib/google/protobuf/empty.rb +15 -0
  154. data/lib/google/protobuf/field_mask.rb +16 -0
  155. data/lib/google/protobuf/source_context.rb +16 -0
  156. data/lib/google/protobuf/struct.rb +35 -0
  157. data/lib/google/protobuf/timestamp.rb +17 -0
  158. data/lib/google/protobuf/type.rb +79 -0
  159. data/lib/google/protobuf/wrappers.rb +48 -0
  160. data/lib/google/pubsub/v1/pubsub.rb +129 -0
  161. data/lib/google/pubsub/v1/pubsub_services.rb +56 -0
  162. data/lib/google/pubsub/v1beta2/pubsub.rb +126 -0
  163. data/lib/google/pubsub/v1beta2/pubsub_services.rb +56 -0
  164. data/lib/google/rpc/code.rb +32 -0
  165. data/lib/google/rpc/error_details.rb +61 -0
  166. data/lib/google/rpc/status.rb +19 -0
  167. data/lib/google/type/color.rb +20 -0
  168. data/lib/google/type/date.rb +18 -0
  169. data/lib/google/type/dayofweek.rb +23 -0
  170. data/lib/google/type/latlng.rb +17 -0
  171. data/lib/google/type/money.rb +18 -0
  172. data/lib/google/type/timeofday.rb +19 -0
  173. metadata +101 -4
  174. data/lib/gcloud/pubsub/connection.rb +0 -295
  175. data/lib/gcloud/pubsub/errors.rb +0 -93
data/lib/gcloud/upload.rb CHANGED
@@ -1,4 +1,3 @@
1
- #--
2
1
  # Copyright 2014 Google Inc. All rights reserved.
3
2
  #
4
3
  # Licensed under the Apache License, Version 2.0 (the "License");
@@ -13,21 +12,22 @@
13
12
  # See the License for the specific language governing permissions and
14
13
  # limitations under the License.
15
14
 
15
+
16
16
  require "gcloud"
17
17
 
18
- #--
19
- # Google Cloud Upload
20
18
  module Gcloud
21
19
  ##
22
- # = Upload Settings
20
+ # # Upload Settings
23
21
  #
24
22
  # Upload allows users to configure how files are uploaded to the Google Cloud
25
23
  # Service APIs.
26
24
  #
25
+ # @example
27
26
  # require "gcloud/upload"
28
27
  #
29
28
  # # Set the default threshold to 10 MiB.
30
29
  # Gcloud::Upload.resumable_threshold = 10_000_000
30
+ #
31
31
  module Upload
32
32
  ##
33
33
  # Retrieve resumable threshold.
@@ -42,10 +42,7 @@ module Gcloud
42
42
  ##
43
43
  # Sets a new resumable threshold value.
44
44
  def self.resumable_threshold= new_resumable_threshold
45
- # rubocop:disable Style/ClassVars
46
- # Disabled rubocop because this is the best option.
47
45
  @@resumable_threshold = new_resumable_threshold.to_i
48
- # rubocop:enable Style/ClassVars
49
46
  end
50
47
 
51
48
  # Set the default threshold to 5 MiB.
@@ -1,4 +1,3 @@
1
- #--
2
1
  # Copyright 2015 Google Inc. All rights reserved.
3
2
  #
4
3
  # Licensed under the Apache License, Version 2.0 (the "License");
@@ -13,8 +12,7 @@
13
12
  # See the License for the specific language governing permissions and
14
13
  # limitations under the License.
15
14
 
16
- #--
17
- # Google Cloud Version
15
+
18
16
  module Gcloud
19
- VERSION = "0.6.3"
17
+ VERSION = "0.7.0"
20
18
  end
@@ -0,0 +1,14 @@
1
+ # Generated by the protocol buffer compiler. DO NOT EDIT!
2
+ # source: google/api/annotations.proto
3
+
4
+ require 'google/protobuf'
5
+
6
+ require 'google/api/http'
7
+ require 'google/protobuf/descriptor'
8
+ Google::Protobuf::DescriptorPool.generated_pool.build do
9
+ end
10
+
11
+ module Google
12
+ module Api
13
+ end
14
+ end
@@ -0,0 +1,30 @@
1
+ # Generated by the protocol buffer compiler. DO NOT EDIT!
2
+ # source: google/api/http.proto
3
+
4
+ require 'google/protobuf'
5
+
6
+ Google::Protobuf::DescriptorPool.generated_pool.build do
7
+ add_message "google.api.HttpRule" do
8
+ optional :body, :string, 7
9
+ repeated :additional_bindings, :message, 11, "google.api.HttpRule"
10
+ oneof :pattern do
11
+ optional :get, :string, 2
12
+ optional :put, :string, 3
13
+ optional :post, :string, 4
14
+ optional :delete, :string, 5
15
+ optional :patch, :string, 6
16
+ optional :custom, :message, 8, "google.api.CustomHttpPattern"
17
+ end
18
+ end
19
+ add_message "google.api.CustomHttpPattern" do
20
+ optional :kind, :string, 1
21
+ optional :path, :string, 2
22
+ end
23
+ end
24
+
25
+ module Google
26
+ module Api
27
+ HttpRule = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.api.HttpRule").msgclass
28
+ CustomHttpPattern = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.api.CustomHttpPattern").msgclass
29
+ end
30
+ end
@@ -0,0 +1,24 @@
1
+ # Generated by the protocol buffer compiler. DO NOT EDIT!
2
+ # source: google/api/label.proto
3
+
4
+ require 'google/protobuf'
5
+
6
+ Google::Protobuf::DescriptorPool.generated_pool.build do
7
+ add_message "google.api.LabelDescriptor" do
8
+ optional :key, :string, 1
9
+ optional :value_type, :enum, 2, "google.api.LabelDescriptor.ValueType"
10
+ optional :description, :string, 3
11
+ end
12
+ add_enum "google.api.LabelDescriptor.ValueType" do
13
+ value :STRING, 0
14
+ value :BOOL, 1
15
+ value :INT64, 2
16
+ end
17
+ end
18
+
19
+ module Google
20
+ module Api
21
+ LabelDescriptor = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.api.LabelDescriptor").msgclass
22
+ LabelDescriptor::ValueType = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.api.LabelDescriptor.ValueType").enummodule
23
+ end
24
+ end
@@ -0,0 +1,25 @@
1
+ # Generated by the protocol buffer compiler. DO NOT EDIT!
2
+ # source: google/api/monitored_resource.proto
3
+
4
+ require 'google/protobuf'
5
+
6
+ require 'google/api/label'
7
+ Google::Protobuf::DescriptorPool.generated_pool.build do
8
+ add_message "google.api.MonitoredResourceDescriptor" do
9
+ optional :type, :string, 1
10
+ optional :display_name, :string, 2
11
+ optional :description, :string, 3
12
+ repeated :labels, :message, 4, "google.api.LabelDescriptor"
13
+ end
14
+ add_message "google.api.MonitoredResource" do
15
+ optional :type, :string, 1
16
+ map :labels, :string, :string, 2
17
+ end
18
+ end
19
+
20
+ module Google
21
+ module Api
22
+ MonitoredResourceDescriptor = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.api.MonitoredResourceDescriptor").msgclass
23
+ MonitoredResource = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.api.MonitoredResource").msgclass
24
+ end
25
+ end
@@ -0,0 +1,115 @@
1
+ # Generated by the protocol buffer compiler. DO NOT EDIT!
2
+ # source: google/datastore/v1beta3/datastore.proto
3
+
4
+ require 'google/protobuf'
5
+
6
+ require 'google/api/annotations'
7
+ require 'google/datastore/v1beta3/entity'
8
+ require 'google/datastore/v1beta3/query'
9
+ Google::Protobuf::DescriptorPool.generated_pool.build do
10
+ add_message "google.datastore.v1beta3.LookupRequest" do
11
+ optional :project_id, :string, 8
12
+ optional :read_options, :message, 1, "google.datastore.v1beta3.ReadOptions"
13
+ repeated :keys, :message, 3, "google.datastore.v1beta3.Key"
14
+ end
15
+ add_message "google.datastore.v1beta3.LookupResponse" do
16
+ repeated :found, :message, 1, "google.datastore.v1beta3.EntityResult"
17
+ repeated :missing, :message, 2, "google.datastore.v1beta3.EntityResult"
18
+ repeated :deferred, :message, 3, "google.datastore.v1beta3.Key"
19
+ end
20
+ add_message "google.datastore.v1beta3.RunQueryRequest" do
21
+ optional :project_id, :string, 8
22
+ optional :partition_id, :message, 2, "google.datastore.v1beta3.PartitionId"
23
+ optional :read_options, :message, 1, "google.datastore.v1beta3.ReadOptions"
24
+ oneof :query_type do
25
+ optional :query, :message, 3, "google.datastore.v1beta3.Query"
26
+ optional :gql_query, :message, 7, "google.datastore.v1beta3.GqlQuery"
27
+ end
28
+ end
29
+ add_message "google.datastore.v1beta3.RunQueryResponse" do
30
+ optional :batch, :message, 1, "google.datastore.v1beta3.QueryResultBatch"
31
+ optional :query, :message, 2, "google.datastore.v1beta3.Query"
32
+ end
33
+ add_message "google.datastore.v1beta3.BeginTransactionRequest" do
34
+ optional :project_id, :string, 8
35
+ end
36
+ add_message "google.datastore.v1beta3.BeginTransactionResponse" do
37
+ optional :transaction, :bytes, 1
38
+ end
39
+ add_message "google.datastore.v1beta3.RollbackRequest" do
40
+ optional :project_id, :string, 8
41
+ optional :transaction, :bytes, 1
42
+ end
43
+ add_message "google.datastore.v1beta3.RollbackResponse" do
44
+ end
45
+ add_message "google.datastore.v1beta3.CommitRequest" do
46
+ optional :project_id, :string, 8
47
+ optional :mode, :enum, 5, "google.datastore.v1beta3.CommitRequest.Mode"
48
+ repeated :mutations, :message, 6, "google.datastore.v1beta3.Mutation"
49
+ oneof :transaction_selector do
50
+ optional :transaction, :bytes, 1
51
+ end
52
+ end
53
+ add_enum "google.datastore.v1beta3.CommitRequest.Mode" do
54
+ value :MODE_UNSPECIFIED, 0
55
+ value :TRANSACTIONAL, 1
56
+ value :NON_TRANSACTIONAL, 2
57
+ end
58
+ add_message "google.datastore.v1beta3.CommitResponse" do
59
+ repeated :mutation_results, :message, 3, "google.datastore.v1beta3.MutationResult"
60
+ optional :index_updates, :int32, 4
61
+ end
62
+ add_message "google.datastore.v1beta3.AllocateIdsRequest" do
63
+ optional :project_id, :string, 8
64
+ repeated :keys, :message, 1, "google.datastore.v1beta3.Key"
65
+ end
66
+ add_message "google.datastore.v1beta3.AllocateIdsResponse" do
67
+ repeated :keys, :message, 1, "google.datastore.v1beta3.Key"
68
+ end
69
+ add_message "google.datastore.v1beta3.Mutation" do
70
+ oneof :operation do
71
+ optional :insert, :message, 4, "google.datastore.v1beta3.Entity"
72
+ optional :update, :message, 5, "google.datastore.v1beta3.Entity"
73
+ optional :upsert, :message, 6, "google.datastore.v1beta3.Entity"
74
+ optional :delete, :message, 7, "google.datastore.v1beta3.Key"
75
+ end
76
+ end
77
+ add_message "google.datastore.v1beta3.MutationResult" do
78
+ optional :key, :message, 3, "google.datastore.v1beta3.Key"
79
+ end
80
+ add_message "google.datastore.v1beta3.ReadOptions" do
81
+ oneof :consistency_type do
82
+ optional :read_consistency, :enum, 1, "google.datastore.v1beta3.ReadOptions.ReadConsistency"
83
+ optional :transaction, :bytes, 2
84
+ end
85
+ end
86
+ add_enum "google.datastore.v1beta3.ReadOptions.ReadConsistency" do
87
+ value :READ_CONSISTENCY_UNSPECIFIED, 0
88
+ value :STRONG, 1
89
+ value :EVENTUAL, 2
90
+ end
91
+ end
92
+
93
+ module Google
94
+ module Datastore
95
+ module V1beta3
96
+ LookupRequest = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.LookupRequest").msgclass
97
+ LookupResponse = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.LookupResponse").msgclass
98
+ RunQueryRequest = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.RunQueryRequest").msgclass
99
+ RunQueryResponse = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.RunQueryResponse").msgclass
100
+ BeginTransactionRequest = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.BeginTransactionRequest").msgclass
101
+ BeginTransactionResponse = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.BeginTransactionResponse").msgclass
102
+ RollbackRequest = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.RollbackRequest").msgclass
103
+ RollbackResponse = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.RollbackResponse").msgclass
104
+ CommitRequest = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.CommitRequest").msgclass
105
+ CommitRequest::Mode = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.CommitRequest.Mode").enummodule
106
+ CommitResponse = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.CommitResponse").msgclass
107
+ AllocateIdsRequest = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.AllocateIdsRequest").msgclass
108
+ AllocateIdsResponse = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.AllocateIdsResponse").msgclass
109
+ Mutation = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.Mutation").msgclass
110
+ MutationResult = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.MutationResult").msgclass
111
+ ReadOptions = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.ReadOptions").msgclass
112
+ ReadOptions::ReadConsistency = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.ReadOptions.ReadConsistency").enummodule
113
+ end
114
+ end
115
+ end
@@ -0,0 +1,33 @@
1
+ # Generated by the protocol buffer compiler. DO NOT EDIT!
2
+ # Source: google/datastore/v1beta3/datastore.proto for package 'google.datastore.v1beta3'
3
+
4
+ require 'grpc'
5
+ require 'google/datastore/v1beta3/datastore'
6
+
7
+ module Google
8
+ module Datastore
9
+ module V1beta3
10
+ module Datastore
11
+
12
+ # TODO: add proto service documentation here
13
+ class Service
14
+
15
+ include GRPC::GenericService
16
+
17
+ self.marshal_class_method = :encode
18
+ self.unmarshal_class_method = :decode
19
+ self.service_name = 'google.datastore.v1beta3.Datastore'
20
+
21
+ rpc :Lookup, LookupRequest, LookupResponse
22
+ rpc :RunQuery, RunQueryRequest, RunQueryResponse
23
+ rpc :BeginTransaction, BeginTransactionRequest, BeginTransactionResponse
24
+ rpc :Commit, CommitRequest, CommitResponse
25
+ rpc :Rollback, RollbackRequest, RollbackResponse
26
+ rpc :AllocateIds, AllocateIdsRequest, AllocateIdsResponse
27
+ end
28
+
29
+ Stub = Service.rpc_stub_class
30
+ end
31
+ end
32
+ end
33
+ end
@@ -0,0 +1,63 @@
1
+ # Generated by the protocol buffer compiler. DO NOT EDIT!
2
+ # source: google/datastore/v1beta3/entity.proto
3
+
4
+ require 'google/protobuf'
5
+
6
+ require 'google/api/annotations'
7
+ require 'google/protobuf/struct'
8
+ require 'google/protobuf/timestamp'
9
+ require 'google/type/latlng'
10
+ Google::Protobuf::DescriptorPool.generated_pool.build do
11
+ add_message "google.datastore.v1beta3.PartitionId" do
12
+ optional :project_id, :string, 2
13
+ optional :namespace_id, :string, 4
14
+ end
15
+ add_message "google.datastore.v1beta3.Key" do
16
+ optional :partition_id, :message, 1, "google.datastore.v1beta3.PartitionId"
17
+ repeated :path, :message, 2, "google.datastore.v1beta3.Key.PathElement"
18
+ end
19
+ add_message "google.datastore.v1beta3.Key.PathElement" do
20
+ optional :kind, :string, 1
21
+ oneof :id_type do
22
+ optional :id, :int64, 2
23
+ optional :name, :string, 3
24
+ end
25
+ end
26
+ add_message "google.datastore.v1beta3.ArrayValue" do
27
+ repeated :values, :message, 1, "google.datastore.v1beta3.Value"
28
+ end
29
+ add_message "google.datastore.v1beta3.Value" do
30
+ optional :meaning, :int32, 14
31
+ optional :exclude_from_indexes, :bool, 19
32
+ oneof :value_type do
33
+ optional :null_value, :enum, 11, "google.protobuf.NullValue"
34
+ optional :boolean_value, :bool, 1
35
+ optional :integer_value, :int64, 2
36
+ optional :double_value, :double, 3
37
+ optional :timestamp_value, :message, 10, "google.protobuf.Timestamp"
38
+ optional :key_value, :message, 5, "google.datastore.v1beta3.Key"
39
+ optional :string_value, :string, 17
40
+ optional :blob_value, :bytes, 18
41
+ optional :geo_point_value, :message, 8, "google.type.LatLng"
42
+ optional :entity_value, :message, 6, "google.datastore.v1beta3.Entity"
43
+ optional :array_value, :message, 9, "google.datastore.v1beta3.ArrayValue"
44
+ end
45
+ end
46
+ add_message "google.datastore.v1beta3.Entity" do
47
+ optional :key, :message, 1, "google.datastore.v1beta3.Key"
48
+ map :properties, :string, :message, 3, "google.datastore.v1beta3.Value"
49
+ end
50
+ end
51
+
52
+ module Google
53
+ module Datastore
54
+ module V1beta3
55
+ PartitionId = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.PartitionId").msgclass
56
+ Key = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.Key").msgclass
57
+ Key::PathElement = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.Key.PathElement").msgclass
58
+ ArrayValue = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.ArrayValue").msgclass
59
+ Value = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.Value").msgclass
60
+ Entity = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.Entity").msgclass
61
+ end
62
+ end
63
+ end
@@ -0,0 +1,128 @@
1
+ # Generated by the protocol buffer compiler. DO NOT EDIT!
2
+ # source: google/datastore/v1beta3/query.proto
3
+
4
+ require 'google/protobuf'
5
+
6
+ require 'google/api/annotations'
7
+ require 'google/datastore/v1beta3/entity'
8
+ require 'google/protobuf/wrappers'
9
+ Google::Protobuf::DescriptorPool.generated_pool.build do
10
+ add_message "google.datastore.v1beta3.EntityResult" do
11
+ optional :entity, :message, 1, "google.datastore.v1beta3.Entity"
12
+ optional :cursor, :bytes, 3
13
+ end
14
+ add_enum "google.datastore.v1beta3.EntityResult.ResultType" do
15
+ value :RESULT_TYPE_UNSPECIFIED, 0
16
+ value :FULL, 1
17
+ value :PROJECTION, 2
18
+ value :KEY_ONLY, 3
19
+ end
20
+ add_message "google.datastore.v1beta3.Query" do
21
+ repeated :projection, :message, 2, "google.datastore.v1beta3.Projection"
22
+ repeated :kind, :message, 3, "google.datastore.v1beta3.KindExpression"
23
+ optional :filter, :message, 4, "google.datastore.v1beta3.Filter"
24
+ repeated :order, :message, 5, "google.datastore.v1beta3.PropertyOrder"
25
+ repeated :distinct_on, :message, 6, "google.datastore.v1beta3.PropertyReference"
26
+ optional :start_cursor, :bytes, 7
27
+ optional :end_cursor, :bytes, 8
28
+ optional :offset, :int32, 10
29
+ optional :limit, :message, 12, "google.protobuf.Int32Value"
30
+ end
31
+ add_message "google.datastore.v1beta3.KindExpression" do
32
+ optional :name, :string, 1
33
+ end
34
+ add_message "google.datastore.v1beta3.PropertyReference" do
35
+ optional :name, :string, 2
36
+ end
37
+ add_message "google.datastore.v1beta3.Projection" do
38
+ optional :property, :message, 1, "google.datastore.v1beta3.PropertyReference"
39
+ end
40
+ add_message "google.datastore.v1beta3.PropertyOrder" do
41
+ optional :property, :message, 1, "google.datastore.v1beta3.PropertyReference"
42
+ optional :direction, :enum, 2, "google.datastore.v1beta3.PropertyOrder.Direction"
43
+ end
44
+ add_enum "google.datastore.v1beta3.PropertyOrder.Direction" do
45
+ value :DIRECTION_UNSPECIFIED, 0
46
+ value :ASCENDING, 1
47
+ value :DESCENDING, 2
48
+ end
49
+ add_message "google.datastore.v1beta3.Filter" do
50
+ oneof :filter_type do
51
+ optional :composite_filter, :message, 1, "google.datastore.v1beta3.CompositeFilter"
52
+ optional :property_filter, :message, 2, "google.datastore.v1beta3.PropertyFilter"
53
+ end
54
+ end
55
+ add_message "google.datastore.v1beta3.CompositeFilter" do
56
+ optional :op, :enum, 1, "google.datastore.v1beta3.CompositeFilter.Operator"
57
+ repeated :filters, :message, 2, "google.datastore.v1beta3.Filter"
58
+ end
59
+ add_enum "google.datastore.v1beta3.CompositeFilter.Operator" do
60
+ value :OPERATOR_UNSPECIFIED, 0
61
+ value :AND, 1
62
+ end
63
+ add_message "google.datastore.v1beta3.PropertyFilter" do
64
+ optional :property, :message, 1, "google.datastore.v1beta3.PropertyReference"
65
+ optional :op, :enum, 2, "google.datastore.v1beta3.PropertyFilter.Operator"
66
+ optional :value, :message, 3, "google.datastore.v1beta3.Value"
67
+ end
68
+ add_enum "google.datastore.v1beta3.PropertyFilter.Operator" do
69
+ value :OPERATOR_UNSPECIFIED, 0
70
+ value :LESS_THAN, 1
71
+ value :LESS_THAN_OR_EQUAL, 2
72
+ value :GREATER_THAN, 3
73
+ value :GREATER_THAN_OR_EQUAL, 4
74
+ value :EQUAL, 5
75
+ value :HAS_ANCESTOR, 11
76
+ end
77
+ add_message "google.datastore.v1beta3.GqlQuery" do
78
+ optional :query_string, :string, 1
79
+ optional :allow_literals, :bool, 2
80
+ map :named_bindings, :string, :message, 5, "google.datastore.v1beta3.GqlQueryParameter"
81
+ repeated :positional_bindings, :message, 4, "google.datastore.v1beta3.GqlQueryParameter"
82
+ end
83
+ add_message "google.datastore.v1beta3.GqlQueryParameter" do
84
+ oneof :parameter_type do
85
+ optional :value, :message, 2, "google.datastore.v1beta3.Value"
86
+ optional :cursor, :bytes, 3
87
+ end
88
+ end
89
+ add_message "google.datastore.v1beta3.QueryResultBatch" do
90
+ optional :skipped_results, :int32, 6
91
+ optional :skipped_cursor, :bytes, 3
92
+ optional :entity_result_type, :enum, 1, "google.datastore.v1beta3.EntityResult.ResultType"
93
+ repeated :entity_results, :message, 2, "google.datastore.v1beta3.EntityResult"
94
+ optional :end_cursor, :bytes, 4
95
+ optional :more_results, :enum, 5, "google.datastore.v1beta3.QueryResultBatch.MoreResultsType"
96
+ end
97
+ add_enum "google.datastore.v1beta3.QueryResultBatch.MoreResultsType" do
98
+ value :MORE_RESULTS_TYPE_UNSPECIFIED, 0
99
+ value :NOT_FINISHED, 1
100
+ value :MORE_RESULTS_AFTER_LIMIT, 2
101
+ value :MORE_RESULTS_AFTER_CURSOR, 4
102
+ value :NO_MORE_RESULTS, 3
103
+ end
104
+ end
105
+
106
+ module Google
107
+ module Datastore
108
+ module V1beta3
109
+ EntityResult = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.EntityResult").msgclass
110
+ EntityResult::ResultType = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.EntityResult.ResultType").enummodule
111
+ Query = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.Query").msgclass
112
+ KindExpression = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.KindExpression").msgclass
113
+ PropertyReference = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.PropertyReference").msgclass
114
+ Projection = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.Projection").msgclass
115
+ PropertyOrder = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.PropertyOrder").msgclass
116
+ PropertyOrder::Direction = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.PropertyOrder.Direction").enummodule
117
+ Filter = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.Filter").msgclass
118
+ CompositeFilter = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.CompositeFilter").msgclass
119
+ CompositeFilter::Operator = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.CompositeFilter.Operator").enummodule
120
+ PropertyFilter = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.PropertyFilter").msgclass
121
+ PropertyFilter::Operator = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.PropertyFilter.Operator").enummodule
122
+ GqlQuery = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.GqlQuery").msgclass
123
+ GqlQueryParameter = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.GqlQueryParameter").msgclass
124
+ QueryResultBatch = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.QueryResultBatch").msgclass
125
+ QueryResultBatch::MoreResultsType = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.datastore.v1beta3.QueryResultBatch.MoreResultsType").enummodule
126
+ end
127
+ end
128
+ end