google-cloud-logging-v2 0.5.4 → 0.5.5
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/google/cloud/logging/v2/config_service/client.rb +484 -69
- data/lib/google/cloud/logging/v2/logging_service/client.rb +121 -6
- data/lib/google/cloud/logging/v2/metrics_service/client.rb +106 -15
- data/lib/google/cloud/logging/v2/version.rb +1 -1
- data/lib/google/logging/v2/log_entry_pb.rb +2 -2
- data/lib/google/logging/v2/logging_config_pb.rb +2 -2
- data/lib/google/logging/v2/logging_config_services_pb.rb +1 -1
- data/lib/google/logging/v2/logging_metrics_pb.rb +2 -2
- data/lib/google/logging/v2/logging_metrics_services_pb.rb +1 -1
- data/lib/google/logging/v2/logging_pb.rb +2 -2
- data/lib/google/logging/v2/logging_services_pb.rb +1 -1
- metadata +2 -2
@@ -232,6 +232,27 @@ module Google
|
|
232
232
|
#
|
233
233
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
234
234
|
#
|
235
|
+
# @example Basic example
|
236
|
+
# require "google/cloud/logging/v2"
|
237
|
+
#
|
238
|
+
# # Create a client object. The client can be reused for multiple calls.
|
239
|
+
# client = Google::Cloud::Logging::V2::ConfigService::Client.new
|
240
|
+
#
|
241
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
242
|
+
# request = Google::Cloud::Logging::V2::ListBucketsRequest.new
|
243
|
+
#
|
244
|
+
# # Call the list_buckets method.
|
245
|
+
# result = client.list_buckets request
|
246
|
+
#
|
247
|
+
# # The returned object is of type Gapic::PagedEnumerable. You can
|
248
|
+
# # iterate over all elements by calling #each, and the enumerable
|
249
|
+
# # will lazily make API calls to fetch subsequent pages. Other
|
250
|
+
# # methods are also available for managing paging directly.
|
251
|
+
# result.each do |response|
|
252
|
+
# # Each element is of type ::Google::Cloud::Logging::V2::LogBucket.
|
253
|
+
# p response
|
254
|
+
# end
|
255
|
+
#
|
235
256
|
def list_buckets request, options = nil
|
236
257
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
237
258
|
|
@@ -249,9 +270,11 @@ module Google
|
|
249
270
|
gapic_version: ::Google::Cloud::Logging::V2::VERSION
|
250
271
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
251
272
|
|
252
|
-
header_params = {
|
253
|
-
|
254
|
-
|
273
|
+
header_params = {}
|
274
|
+
if request.parent
|
275
|
+
header_params["parent"] = request.parent
|
276
|
+
end
|
277
|
+
|
255
278
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
256
279
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
257
280
|
|
@@ -309,6 +332,21 @@ module Google
|
|
309
332
|
#
|
310
333
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
311
334
|
#
|
335
|
+
# @example Basic example
|
336
|
+
# require "google/cloud/logging/v2"
|
337
|
+
#
|
338
|
+
# # Create a client object. The client can be reused for multiple calls.
|
339
|
+
# client = Google::Cloud::Logging::V2::ConfigService::Client.new
|
340
|
+
#
|
341
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
342
|
+
# request = Google::Cloud::Logging::V2::GetBucketRequest.new
|
343
|
+
#
|
344
|
+
# # Call the get_bucket method.
|
345
|
+
# result = client.get_bucket request
|
346
|
+
#
|
347
|
+
# # The returned object is of type Google::Cloud::Logging::V2::LogBucket.
|
348
|
+
# p result
|
349
|
+
#
|
312
350
|
def get_bucket request, options = nil
|
313
351
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
314
352
|
|
@@ -326,9 +364,11 @@ module Google
|
|
326
364
|
gapic_version: ::Google::Cloud::Logging::V2::VERSION
|
327
365
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
328
366
|
|
329
|
-
header_params = {
|
330
|
-
|
331
|
-
|
367
|
+
header_params = {}
|
368
|
+
if request.name
|
369
|
+
header_params["name"] = request.name
|
370
|
+
end
|
371
|
+
|
332
372
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
333
373
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
334
374
|
|
@@ -390,6 +430,21 @@ module Google
|
|
390
430
|
#
|
391
431
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
392
432
|
#
|
433
|
+
# @example Basic example
|
434
|
+
# require "google/cloud/logging/v2"
|
435
|
+
#
|
436
|
+
# # Create a client object. The client can be reused for multiple calls.
|
437
|
+
# client = Google::Cloud::Logging::V2::ConfigService::Client.new
|
438
|
+
#
|
439
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
440
|
+
# request = Google::Cloud::Logging::V2::CreateBucketRequest.new
|
441
|
+
#
|
442
|
+
# # Call the create_bucket method.
|
443
|
+
# result = client.create_bucket request
|
444
|
+
#
|
445
|
+
# # The returned object is of type Google::Cloud::Logging::V2::LogBucket.
|
446
|
+
# p result
|
447
|
+
#
|
393
448
|
def create_bucket request, options = nil
|
394
449
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
395
450
|
|
@@ -407,9 +462,11 @@ module Google
|
|
407
462
|
gapic_version: ::Google::Cloud::Logging::V2::VERSION
|
408
463
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
409
464
|
|
410
|
-
header_params = {
|
411
|
-
|
412
|
-
|
465
|
+
header_params = {}
|
466
|
+
if request.parent
|
467
|
+
header_params["parent"] = request.parent
|
468
|
+
end
|
469
|
+
|
413
470
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
414
471
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
415
472
|
|
@@ -488,6 +545,21 @@ module Google
|
|
488
545
|
#
|
489
546
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
490
547
|
#
|
548
|
+
# @example Basic example
|
549
|
+
# require "google/cloud/logging/v2"
|
550
|
+
#
|
551
|
+
# # Create a client object. The client can be reused for multiple calls.
|
552
|
+
# client = Google::Cloud::Logging::V2::ConfigService::Client.new
|
553
|
+
#
|
554
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
555
|
+
# request = Google::Cloud::Logging::V2::UpdateBucketRequest.new
|
556
|
+
#
|
557
|
+
# # Call the update_bucket method.
|
558
|
+
# result = client.update_bucket request
|
559
|
+
#
|
560
|
+
# # The returned object is of type Google::Cloud::Logging::V2::LogBucket.
|
561
|
+
# p result
|
562
|
+
#
|
491
563
|
def update_bucket request, options = nil
|
492
564
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
493
565
|
|
@@ -505,9 +577,11 @@ module Google
|
|
505
577
|
gapic_version: ::Google::Cloud::Logging::V2::VERSION
|
506
578
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
507
579
|
|
508
|
-
header_params = {
|
509
|
-
|
510
|
-
|
580
|
+
header_params = {}
|
581
|
+
if request.name
|
582
|
+
header_params["name"] = request.name
|
583
|
+
end
|
584
|
+
|
511
585
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
512
586
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
513
587
|
|
@@ -567,6 +641,21 @@ module Google
|
|
567
641
|
#
|
568
642
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
569
643
|
#
|
644
|
+
# @example Basic example
|
645
|
+
# require "google/cloud/logging/v2"
|
646
|
+
#
|
647
|
+
# # Create a client object. The client can be reused for multiple calls.
|
648
|
+
# client = Google::Cloud::Logging::V2::ConfigService::Client.new
|
649
|
+
#
|
650
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
651
|
+
# request = Google::Cloud::Logging::V2::DeleteBucketRequest.new
|
652
|
+
#
|
653
|
+
# # Call the delete_bucket method.
|
654
|
+
# result = client.delete_bucket request
|
655
|
+
#
|
656
|
+
# # The returned object is of type Google::Protobuf::Empty.
|
657
|
+
# p result
|
658
|
+
#
|
570
659
|
def delete_bucket request, options = nil
|
571
660
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
572
661
|
|
@@ -584,9 +673,11 @@ module Google
|
|
584
673
|
gapic_version: ::Google::Cloud::Logging::V2::VERSION
|
585
674
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
586
675
|
|
587
|
-
header_params = {
|
588
|
-
|
589
|
-
|
676
|
+
header_params = {}
|
677
|
+
if request.name
|
678
|
+
header_params["name"] = request.name
|
679
|
+
end
|
680
|
+
|
590
681
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
591
682
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
592
683
|
|
@@ -644,6 +735,21 @@ module Google
|
|
644
735
|
#
|
645
736
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
646
737
|
#
|
738
|
+
# @example Basic example
|
739
|
+
# require "google/cloud/logging/v2"
|
740
|
+
#
|
741
|
+
# # Create a client object. The client can be reused for multiple calls.
|
742
|
+
# client = Google::Cloud::Logging::V2::ConfigService::Client.new
|
743
|
+
#
|
744
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
745
|
+
# request = Google::Cloud::Logging::V2::UndeleteBucketRequest.new
|
746
|
+
#
|
747
|
+
# # Call the undelete_bucket method.
|
748
|
+
# result = client.undelete_bucket request
|
749
|
+
#
|
750
|
+
# # The returned object is of type Google::Protobuf::Empty.
|
751
|
+
# p result
|
752
|
+
#
|
647
753
|
def undelete_bucket request, options = nil
|
648
754
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
649
755
|
|
@@ -661,9 +767,11 @@ module Google
|
|
661
767
|
gapic_version: ::Google::Cloud::Logging::V2::VERSION
|
662
768
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
663
769
|
|
664
|
-
header_params = {
|
665
|
-
|
666
|
-
|
770
|
+
header_params = {}
|
771
|
+
if request.name
|
772
|
+
header_params["name"] = request.name
|
773
|
+
end
|
774
|
+
|
667
775
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
668
776
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
669
777
|
|
@@ -723,6 +831,27 @@ module Google
|
|
723
831
|
#
|
724
832
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
725
833
|
#
|
834
|
+
# @example Basic example
|
835
|
+
# require "google/cloud/logging/v2"
|
836
|
+
#
|
837
|
+
# # Create a client object. The client can be reused for multiple calls.
|
838
|
+
# client = Google::Cloud::Logging::V2::ConfigService::Client.new
|
839
|
+
#
|
840
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
841
|
+
# request = Google::Cloud::Logging::V2::ListViewsRequest.new
|
842
|
+
#
|
843
|
+
# # Call the list_views method.
|
844
|
+
# result = client.list_views request
|
845
|
+
#
|
846
|
+
# # The returned object is of type Gapic::PagedEnumerable. You can
|
847
|
+
# # iterate over all elements by calling #each, and the enumerable
|
848
|
+
# # will lazily make API calls to fetch subsequent pages. Other
|
849
|
+
# # methods are also available for managing paging directly.
|
850
|
+
# result.each do |response|
|
851
|
+
# # Each element is of type ::Google::Cloud::Logging::V2::LogView.
|
852
|
+
# p response
|
853
|
+
# end
|
854
|
+
#
|
726
855
|
def list_views request, options = nil
|
727
856
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
728
857
|
|
@@ -740,9 +869,11 @@ module Google
|
|
740
869
|
gapic_version: ::Google::Cloud::Logging::V2::VERSION
|
741
870
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
742
871
|
|
743
|
-
header_params = {
|
744
|
-
|
745
|
-
|
872
|
+
header_params = {}
|
873
|
+
if request.parent
|
874
|
+
header_params["parent"] = request.parent
|
875
|
+
end
|
876
|
+
|
746
877
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
747
878
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
748
879
|
|
@@ -797,6 +928,21 @@ module Google
|
|
797
928
|
#
|
798
929
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
799
930
|
#
|
931
|
+
# @example Basic example
|
932
|
+
# require "google/cloud/logging/v2"
|
933
|
+
#
|
934
|
+
# # Create a client object. The client can be reused for multiple calls.
|
935
|
+
# client = Google::Cloud::Logging::V2::ConfigService::Client.new
|
936
|
+
#
|
937
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
938
|
+
# request = Google::Cloud::Logging::V2::GetViewRequest.new
|
939
|
+
#
|
940
|
+
# # Call the get_view method.
|
941
|
+
# result = client.get_view request
|
942
|
+
#
|
943
|
+
# # The returned object is of type Google::Cloud::Logging::V2::LogView.
|
944
|
+
# p result
|
945
|
+
#
|
800
946
|
def get_view request, options = nil
|
801
947
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
802
948
|
|
@@ -814,9 +960,11 @@ module Google
|
|
814
960
|
gapic_version: ::Google::Cloud::Logging::V2::VERSION
|
815
961
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
816
962
|
|
817
|
-
header_params = {
|
818
|
-
|
819
|
-
|
963
|
+
header_params = {}
|
964
|
+
if request.name
|
965
|
+
header_params["name"] = request.name
|
966
|
+
end
|
967
|
+
|
820
968
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
821
969
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
822
970
|
|
@@ -875,6 +1023,21 @@ module Google
|
|
875
1023
|
#
|
876
1024
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
877
1025
|
#
|
1026
|
+
# @example Basic example
|
1027
|
+
# require "google/cloud/logging/v2"
|
1028
|
+
#
|
1029
|
+
# # Create a client object. The client can be reused for multiple calls.
|
1030
|
+
# client = Google::Cloud::Logging::V2::ConfigService::Client.new
|
1031
|
+
#
|
1032
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
1033
|
+
# request = Google::Cloud::Logging::V2::CreateViewRequest.new
|
1034
|
+
#
|
1035
|
+
# # Call the create_view method.
|
1036
|
+
# result = client.create_view request
|
1037
|
+
#
|
1038
|
+
# # The returned object is of type Google::Cloud::Logging::V2::LogView.
|
1039
|
+
# p result
|
1040
|
+
#
|
878
1041
|
def create_view request, options = nil
|
879
1042
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
880
1043
|
|
@@ -892,9 +1055,11 @@ module Google
|
|
892
1055
|
gapic_version: ::Google::Cloud::Logging::V2::VERSION
|
893
1056
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
894
1057
|
|
895
|
-
header_params = {
|
896
|
-
|
897
|
-
|
1058
|
+
header_params = {}
|
1059
|
+
if request.parent
|
1060
|
+
header_params["parent"] = request.parent
|
1061
|
+
end
|
1062
|
+
|
898
1063
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
899
1064
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
900
1065
|
|
@@ -960,6 +1125,21 @@ module Google
|
|
960
1125
|
#
|
961
1126
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
962
1127
|
#
|
1128
|
+
# @example Basic example
|
1129
|
+
# require "google/cloud/logging/v2"
|
1130
|
+
#
|
1131
|
+
# # Create a client object. The client can be reused for multiple calls.
|
1132
|
+
# client = Google::Cloud::Logging::V2::ConfigService::Client.new
|
1133
|
+
#
|
1134
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
1135
|
+
# request = Google::Cloud::Logging::V2::UpdateViewRequest.new
|
1136
|
+
#
|
1137
|
+
# # Call the update_view method.
|
1138
|
+
# result = client.update_view request
|
1139
|
+
#
|
1140
|
+
# # The returned object is of type Google::Cloud::Logging::V2::LogView.
|
1141
|
+
# p result
|
1142
|
+
#
|
963
1143
|
def update_view request, options = nil
|
964
1144
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
965
1145
|
|
@@ -977,9 +1157,11 @@ module Google
|
|
977
1157
|
gapic_version: ::Google::Cloud::Logging::V2::VERSION
|
978
1158
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
979
1159
|
|
980
|
-
header_params = {
|
981
|
-
|
982
|
-
|
1160
|
+
header_params = {}
|
1161
|
+
if request.name
|
1162
|
+
header_params["name"] = request.name
|
1163
|
+
end
|
1164
|
+
|
983
1165
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
984
1166
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
985
1167
|
|
@@ -1033,6 +1215,21 @@ module Google
|
|
1033
1215
|
#
|
1034
1216
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
1035
1217
|
#
|
1218
|
+
# @example Basic example
|
1219
|
+
# require "google/cloud/logging/v2"
|
1220
|
+
#
|
1221
|
+
# # Create a client object. The client can be reused for multiple calls.
|
1222
|
+
# client = Google::Cloud::Logging::V2::ConfigService::Client.new
|
1223
|
+
#
|
1224
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
1225
|
+
# request = Google::Cloud::Logging::V2::DeleteViewRequest.new
|
1226
|
+
#
|
1227
|
+
# # Call the delete_view method.
|
1228
|
+
# result = client.delete_view request
|
1229
|
+
#
|
1230
|
+
# # The returned object is of type Google::Protobuf::Empty.
|
1231
|
+
# p result
|
1232
|
+
#
|
1036
1233
|
def delete_view request, options = nil
|
1037
1234
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
1038
1235
|
|
@@ -1050,9 +1247,11 @@ module Google
|
|
1050
1247
|
gapic_version: ::Google::Cloud::Logging::V2::VERSION
|
1051
1248
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1052
1249
|
|
1053
|
-
header_params = {
|
1054
|
-
|
1055
|
-
|
1250
|
+
header_params = {}
|
1251
|
+
if request.name
|
1252
|
+
header_params["name"] = request.name
|
1253
|
+
end
|
1254
|
+
|
1056
1255
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
1057
1256
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
1058
1257
|
|
@@ -1115,6 +1314,27 @@ module Google
|
|
1115
1314
|
#
|
1116
1315
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
1117
1316
|
#
|
1317
|
+
# @example Basic example
|
1318
|
+
# require "google/cloud/logging/v2"
|
1319
|
+
#
|
1320
|
+
# # Create a client object. The client can be reused for multiple calls.
|
1321
|
+
# client = Google::Cloud::Logging::V2::ConfigService::Client.new
|
1322
|
+
#
|
1323
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
1324
|
+
# request = Google::Cloud::Logging::V2::ListSinksRequest.new
|
1325
|
+
#
|
1326
|
+
# # Call the list_sinks method.
|
1327
|
+
# result = client.list_sinks request
|
1328
|
+
#
|
1329
|
+
# # The returned object is of type Gapic::PagedEnumerable. You can
|
1330
|
+
# # iterate over all elements by calling #each, and the enumerable
|
1331
|
+
# # will lazily make API calls to fetch subsequent pages. Other
|
1332
|
+
# # methods are also available for managing paging directly.
|
1333
|
+
# result.each do |response|
|
1334
|
+
# # Each element is of type ::Google::Cloud::Logging::V2::LogSink.
|
1335
|
+
# p response
|
1336
|
+
# end
|
1337
|
+
#
|
1118
1338
|
def list_sinks request, options = nil
|
1119
1339
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
1120
1340
|
|
@@ -1132,9 +1352,11 @@ module Google
|
|
1132
1352
|
gapic_version: ::Google::Cloud::Logging::V2::VERSION
|
1133
1353
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1134
1354
|
|
1135
|
-
header_params = {
|
1136
|
-
|
1137
|
-
|
1355
|
+
header_params = {}
|
1356
|
+
if request.parent
|
1357
|
+
header_params["parent"] = request.parent
|
1358
|
+
end
|
1359
|
+
|
1138
1360
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
1139
1361
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
1140
1362
|
|
@@ -1191,6 +1413,21 @@ module Google
|
|
1191
1413
|
#
|
1192
1414
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
1193
1415
|
#
|
1416
|
+
# @example Basic example
|
1417
|
+
# require "google/cloud/logging/v2"
|
1418
|
+
#
|
1419
|
+
# # Create a client object. The client can be reused for multiple calls.
|
1420
|
+
# client = Google::Cloud::Logging::V2::ConfigService::Client.new
|
1421
|
+
#
|
1422
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
1423
|
+
# request = Google::Cloud::Logging::V2::GetSinkRequest.new
|
1424
|
+
#
|
1425
|
+
# # Call the get_sink method.
|
1426
|
+
# result = client.get_sink request
|
1427
|
+
#
|
1428
|
+
# # The returned object is of type Google::Cloud::Logging::V2::LogSink.
|
1429
|
+
# p result
|
1430
|
+
#
|
1194
1431
|
def get_sink request, options = nil
|
1195
1432
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
1196
1433
|
|
@@ -1208,9 +1445,11 @@ module Google
|
|
1208
1445
|
gapic_version: ::Google::Cloud::Logging::V2::VERSION
|
1209
1446
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1210
1447
|
|
1211
|
-
header_params = {
|
1212
|
-
|
1213
|
-
|
1448
|
+
header_params = {}
|
1449
|
+
if request.sink_name
|
1450
|
+
header_params["sink_name"] = request.sink_name
|
1451
|
+
end
|
1452
|
+
|
1214
1453
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
1215
1454
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
1216
1455
|
|
@@ -1284,6 +1523,21 @@ module Google
|
|
1284
1523
|
#
|
1285
1524
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
1286
1525
|
#
|
1526
|
+
# @example Basic example
|
1527
|
+
# require "google/cloud/logging/v2"
|
1528
|
+
#
|
1529
|
+
# # Create a client object. The client can be reused for multiple calls.
|
1530
|
+
# client = Google::Cloud::Logging::V2::ConfigService::Client.new
|
1531
|
+
#
|
1532
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
1533
|
+
# request = Google::Cloud::Logging::V2::CreateSinkRequest.new
|
1534
|
+
#
|
1535
|
+
# # Call the create_sink method.
|
1536
|
+
# result = client.create_sink request
|
1537
|
+
#
|
1538
|
+
# # The returned object is of type Google::Cloud::Logging::V2::LogSink.
|
1539
|
+
# p result
|
1540
|
+
#
|
1287
1541
|
def create_sink request, options = nil
|
1288
1542
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
1289
1543
|
|
@@ -1301,9 +1555,11 @@ module Google
|
|
1301
1555
|
gapic_version: ::Google::Cloud::Logging::V2::VERSION
|
1302
1556
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1303
1557
|
|
1304
|
-
header_params = {
|
1305
|
-
|
1306
|
-
|
1558
|
+
header_params = {}
|
1559
|
+
if request.parent
|
1560
|
+
header_params["parent"] = request.parent
|
1561
|
+
end
|
1562
|
+
|
1307
1563
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
1308
1564
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
1309
1565
|
|
@@ -1394,6 +1650,21 @@ module Google
|
|
1394
1650
|
#
|
1395
1651
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
1396
1652
|
#
|
1653
|
+
# @example Basic example
|
1654
|
+
# require "google/cloud/logging/v2"
|
1655
|
+
#
|
1656
|
+
# # Create a client object. The client can be reused for multiple calls.
|
1657
|
+
# client = Google::Cloud::Logging::V2::ConfigService::Client.new
|
1658
|
+
#
|
1659
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
1660
|
+
# request = Google::Cloud::Logging::V2::UpdateSinkRequest.new
|
1661
|
+
#
|
1662
|
+
# # Call the update_sink method.
|
1663
|
+
# result = client.update_sink request
|
1664
|
+
#
|
1665
|
+
# # The returned object is of type Google::Cloud::Logging::V2::LogSink.
|
1666
|
+
# p result
|
1667
|
+
#
|
1397
1668
|
def update_sink request, options = nil
|
1398
1669
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
1399
1670
|
|
@@ -1411,9 +1682,11 @@ module Google
|
|
1411
1682
|
gapic_version: ::Google::Cloud::Logging::V2::VERSION
|
1412
1683
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1413
1684
|
|
1414
|
-
header_params = {
|
1415
|
-
|
1416
|
-
|
1685
|
+
header_params = {}
|
1686
|
+
if request.sink_name
|
1687
|
+
header_params["sink_name"] = request.sink_name
|
1688
|
+
end
|
1689
|
+
|
1417
1690
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
1418
1691
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
1419
1692
|
|
@@ -1471,6 +1744,21 @@ module Google
|
|
1471
1744
|
#
|
1472
1745
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
1473
1746
|
#
|
1747
|
+
# @example Basic example
|
1748
|
+
# require "google/cloud/logging/v2"
|
1749
|
+
#
|
1750
|
+
# # Create a client object. The client can be reused for multiple calls.
|
1751
|
+
# client = Google::Cloud::Logging::V2::ConfigService::Client.new
|
1752
|
+
#
|
1753
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
1754
|
+
# request = Google::Cloud::Logging::V2::DeleteSinkRequest.new
|
1755
|
+
#
|
1756
|
+
# # Call the delete_sink method.
|
1757
|
+
# result = client.delete_sink request
|
1758
|
+
#
|
1759
|
+
# # The returned object is of type Google::Protobuf::Empty.
|
1760
|
+
# p result
|
1761
|
+
#
|
1474
1762
|
def delete_sink request, options = nil
|
1475
1763
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
1476
1764
|
|
@@ -1488,9 +1776,11 @@ module Google
|
|
1488
1776
|
gapic_version: ::Google::Cloud::Logging::V2::VERSION
|
1489
1777
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1490
1778
|
|
1491
|
-
header_params = {
|
1492
|
-
|
1493
|
-
|
1779
|
+
header_params = {}
|
1780
|
+
if request.sink_name
|
1781
|
+
header_params["sink_name"] = request.sink_name
|
1782
|
+
end
|
1783
|
+
|
1494
1784
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
1495
1785
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
1496
1786
|
|
@@ -1553,6 +1843,27 @@ module Google
|
|
1553
1843
|
#
|
1554
1844
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
1555
1845
|
#
|
1846
|
+
# @example Basic example
|
1847
|
+
# require "google/cloud/logging/v2"
|
1848
|
+
#
|
1849
|
+
# # Create a client object. The client can be reused for multiple calls.
|
1850
|
+
# client = Google::Cloud::Logging::V2::ConfigService::Client.new
|
1851
|
+
#
|
1852
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
1853
|
+
# request = Google::Cloud::Logging::V2::ListExclusionsRequest.new
|
1854
|
+
#
|
1855
|
+
# # Call the list_exclusions method.
|
1856
|
+
# result = client.list_exclusions request
|
1857
|
+
#
|
1858
|
+
# # The returned object is of type Gapic::PagedEnumerable. You can
|
1859
|
+
# # iterate over all elements by calling #each, and the enumerable
|
1860
|
+
# # will lazily make API calls to fetch subsequent pages. Other
|
1861
|
+
# # methods are also available for managing paging directly.
|
1862
|
+
# result.each do |response|
|
1863
|
+
# # Each element is of type ::Google::Cloud::Logging::V2::LogExclusion.
|
1864
|
+
# p response
|
1865
|
+
# end
|
1866
|
+
#
|
1556
1867
|
def list_exclusions request, options = nil
|
1557
1868
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
1558
1869
|
|
@@ -1570,9 +1881,11 @@ module Google
|
|
1570
1881
|
gapic_version: ::Google::Cloud::Logging::V2::VERSION
|
1571
1882
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1572
1883
|
|
1573
|
-
header_params = {
|
1574
|
-
|
1575
|
-
|
1884
|
+
header_params = {}
|
1885
|
+
if request.parent
|
1886
|
+
header_params["parent"] = request.parent
|
1887
|
+
end
|
1888
|
+
|
1576
1889
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
1577
1890
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
1578
1891
|
|
@@ -1629,6 +1942,21 @@ module Google
|
|
1629
1942
|
#
|
1630
1943
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
1631
1944
|
#
|
1945
|
+
# @example Basic example
|
1946
|
+
# require "google/cloud/logging/v2"
|
1947
|
+
#
|
1948
|
+
# # Create a client object. The client can be reused for multiple calls.
|
1949
|
+
# client = Google::Cloud::Logging::V2::ConfigService::Client.new
|
1950
|
+
#
|
1951
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
1952
|
+
# request = Google::Cloud::Logging::V2::GetExclusionRequest.new
|
1953
|
+
#
|
1954
|
+
# # Call the get_exclusion method.
|
1955
|
+
# result = client.get_exclusion request
|
1956
|
+
#
|
1957
|
+
# # The returned object is of type Google::Cloud::Logging::V2::LogExclusion.
|
1958
|
+
# p result
|
1959
|
+
#
|
1632
1960
|
def get_exclusion request, options = nil
|
1633
1961
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
1634
1962
|
|
@@ -1646,9 +1974,11 @@ module Google
|
|
1646
1974
|
gapic_version: ::Google::Cloud::Logging::V2::VERSION
|
1647
1975
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1648
1976
|
|
1649
|
-
header_params = {
|
1650
|
-
|
1651
|
-
|
1977
|
+
header_params = {}
|
1978
|
+
if request.name
|
1979
|
+
header_params["name"] = request.name
|
1980
|
+
end
|
1981
|
+
|
1652
1982
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
1653
1983
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
1654
1984
|
|
@@ -1709,6 +2039,21 @@ module Google
|
|
1709
2039
|
#
|
1710
2040
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
1711
2041
|
#
|
2042
|
+
# @example Basic example
|
2043
|
+
# require "google/cloud/logging/v2"
|
2044
|
+
#
|
2045
|
+
# # Create a client object. The client can be reused for multiple calls.
|
2046
|
+
# client = Google::Cloud::Logging::V2::ConfigService::Client.new
|
2047
|
+
#
|
2048
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
2049
|
+
# request = Google::Cloud::Logging::V2::CreateExclusionRequest.new
|
2050
|
+
#
|
2051
|
+
# # Call the create_exclusion method.
|
2052
|
+
# result = client.create_exclusion request
|
2053
|
+
#
|
2054
|
+
# # The returned object is of type Google::Cloud::Logging::V2::LogExclusion.
|
2055
|
+
# p result
|
2056
|
+
#
|
1712
2057
|
def create_exclusion request, options = nil
|
1713
2058
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
1714
2059
|
|
@@ -1726,9 +2071,11 @@ module Google
|
|
1726
2071
|
gapic_version: ::Google::Cloud::Logging::V2::VERSION
|
1727
2072
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1728
2073
|
|
1729
|
-
header_params = {
|
1730
|
-
|
1731
|
-
|
2074
|
+
header_params = {}
|
2075
|
+
if request.parent
|
2076
|
+
header_params["parent"] = request.parent
|
2077
|
+
end
|
2078
|
+
|
1732
2079
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
1733
2080
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
1734
2081
|
|
@@ -1795,6 +2142,21 @@ module Google
|
|
1795
2142
|
#
|
1796
2143
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
1797
2144
|
#
|
2145
|
+
# @example Basic example
|
2146
|
+
# require "google/cloud/logging/v2"
|
2147
|
+
#
|
2148
|
+
# # Create a client object. The client can be reused for multiple calls.
|
2149
|
+
# client = Google::Cloud::Logging::V2::ConfigService::Client.new
|
2150
|
+
#
|
2151
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
2152
|
+
# request = Google::Cloud::Logging::V2::UpdateExclusionRequest.new
|
2153
|
+
#
|
2154
|
+
# # Call the update_exclusion method.
|
2155
|
+
# result = client.update_exclusion request
|
2156
|
+
#
|
2157
|
+
# # The returned object is of type Google::Cloud::Logging::V2::LogExclusion.
|
2158
|
+
# p result
|
2159
|
+
#
|
1798
2160
|
def update_exclusion request, options = nil
|
1799
2161
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
1800
2162
|
|
@@ -1812,9 +2174,11 @@ module Google
|
|
1812
2174
|
gapic_version: ::Google::Cloud::Logging::V2::VERSION
|
1813
2175
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1814
2176
|
|
1815
|
-
header_params = {
|
1816
|
-
|
1817
|
-
|
2177
|
+
header_params = {}
|
2178
|
+
if request.name
|
2179
|
+
header_params["name"] = request.name
|
2180
|
+
end
|
2181
|
+
|
1818
2182
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
1819
2183
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
1820
2184
|
|
@@ -1870,6 +2234,21 @@ module Google
|
|
1870
2234
|
#
|
1871
2235
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
1872
2236
|
#
|
2237
|
+
# @example Basic example
|
2238
|
+
# require "google/cloud/logging/v2"
|
2239
|
+
#
|
2240
|
+
# # Create a client object. The client can be reused for multiple calls.
|
2241
|
+
# client = Google::Cloud::Logging::V2::ConfigService::Client.new
|
2242
|
+
#
|
2243
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
2244
|
+
# request = Google::Cloud::Logging::V2::DeleteExclusionRequest.new
|
2245
|
+
#
|
2246
|
+
# # Call the delete_exclusion method.
|
2247
|
+
# result = client.delete_exclusion request
|
2248
|
+
#
|
2249
|
+
# # The returned object is of type Google::Protobuf::Empty.
|
2250
|
+
# p result
|
2251
|
+
#
|
1873
2252
|
def delete_exclusion request, options = nil
|
1874
2253
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
1875
2254
|
|
@@ -1887,9 +2266,11 @@ module Google
|
|
1887
2266
|
gapic_version: ::Google::Cloud::Logging::V2::VERSION
|
1888
2267
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1889
2268
|
|
1890
|
-
header_params = {
|
1891
|
-
|
1892
|
-
|
2269
|
+
header_params = {}
|
2270
|
+
if request.name
|
2271
|
+
header_params["name"] = request.name
|
2272
|
+
end
|
2273
|
+
|
1893
2274
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
1894
2275
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
1895
2276
|
|
@@ -1957,6 +2338,21 @@ module Google
|
|
1957
2338
|
#
|
1958
2339
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
1959
2340
|
#
|
2341
|
+
# @example Basic example
|
2342
|
+
# require "google/cloud/logging/v2"
|
2343
|
+
#
|
2344
|
+
# # Create a client object. The client can be reused for multiple calls.
|
2345
|
+
# client = Google::Cloud::Logging::V2::ConfigService::Client.new
|
2346
|
+
#
|
2347
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
2348
|
+
# request = Google::Cloud::Logging::V2::GetCmekSettingsRequest.new
|
2349
|
+
#
|
2350
|
+
# # Call the get_cmek_settings method.
|
2351
|
+
# result = client.get_cmek_settings request
|
2352
|
+
#
|
2353
|
+
# # The returned object is of type Google::Cloud::Logging::V2::CmekSettings.
|
2354
|
+
# p result
|
2355
|
+
#
|
1960
2356
|
def get_cmek_settings request, options = nil
|
1961
2357
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
1962
2358
|
|
@@ -1974,9 +2370,11 @@ module Google
|
|
1974
2370
|
gapic_version: ::Google::Cloud::Logging::V2::VERSION
|
1975
2371
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1976
2372
|
|
1977
|
-
header_params = {
|
1978
|
-
|
1979
|
-
|
2373
|
+
header_params = {}
|
2374
|
+
if request.name
|
2375
|
+
header_params["name"] = request.name
|
2376
|
+
end
|
2377
|
+
|
1980
2378
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
1981
2379
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
1982
2380
|
|
@@ -2064,6 +2462,21 @@ module Google
|
|
2064
2462
|
#
|
2065
2463
|
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
2066
2464
|
#
|
2465
|
+
# @example Basic example
|
2466
|
+
# require "google/cloud/logging/v2"
|
2467
|
+
#
|
2468
|
+
# # Create a client object. The client can be reused for multiple calls.
|
2469
|
+
# client = Google::Cloud::Logging::V2::ConfigService::Client.new
|
2470
|
+
#
|
2471
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
2472
|
+
# request = Google::Cloud::Logging::V2::UpdateCmekSettingsRequest.new
|
2473
|
+
#
|
2474
|
+
# # Call the update_cmek_settings method.
|
2475
|
+
# result = client.update_cmek_settings request
|
2476
|
+
#
|
2477
|
+
# # The returned object is of type Google::Cloud::Logging::V2::CmekSettings.
|
2478
|
+
# p result
|
2479
|
+
#
|
2067
2480
|
def update_cmek_settings request, options = nil
|
2068
2481
|
raise ::ArgumentError, "request must be provided" if request.nil?
|
2069
2482
|
|
@@ -2081,9 +2494,11 @@ module Google
|
|
2081
2494
|
gapic_version: ::Google::Cloud::Logging::V2::VERSION
|
2082
2495
|
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
2083
2496
|
|
2084
|
-
header_params = {
|
2085
|
-
|
2086
|
-
|
2497
|
+
header_params = {}
|
2498
|
+
if request.name
|
2499
|
+
header_params["name"] = request.name
|
2500
|
+
end
|
2501
|
+
|
2087
2502
|
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
2088
2503
|
metadata[:"x-goog-request-params"] ||= request_params_header
|
2089
2504
|
|