Skip to content

Commit fa3dfb2

Browse files
feat: Added H.265 (HEVC) codec support (googleapis#31529)
* feat: Added H.265 (HEVC) codec support feat: Added UHD (4k) resolution support feat: Added Auto Transcription support feat: Added StartDistribution/StopDistribution methods and Distribution/DistributionStream messages used for distributing live streams to external RTMP/SRT endpoints feat: Added PreviewInput method used for the low latency input monitoring feat: Added UpdateEncryptions event to perform key rotation without restarting a channel docs: Update requirements of resource ID fields to be more clear PiperOrigin-RevId: 808091810 Source-Link: googleapis/googleapis@c4e80cd Source-Link: https://github.com/googleapis/googleapis-gen/commit/6f37911e32d6eadcfc31256e688a048f7d7172cc Copy-Tag: eyJwIjoiZ29vZ2xlLWNsb3VkLXZpZGVvLWxpdmVfc3RyZWFtLXYxLy5Pd2xCb3QueWFtbCIsImgiOiI2ZjM3OTExZTMyZDZlYWRjZmMzMTI1NmU2ODhhMDQ4ZjdkNzE3MmNjIn0= * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md --------- Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
1 parent 3b7a2a8 commit fa3dfb2

18 files changed

Lines changed: 2111 additions & 61 deletions

File tree

google-cloud-video-live_stream-v1/.owlbot-manifest.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,8 +74,11 @@
7474
"snippets/livestream_service/list_dvr_sessions.rb",
7575
"snippets/livestream_service/list_events.rb",
7676
"snippets/livestream_service/list_inputs.rb",
77+
"snippets/livestream_service/preview_input.rb",
7778
"snippets/livestream_service/start_channel.rb",
79+
"snippets/livestream_service/start_distribution.rb",
7880
"snippets/livestream_service/stop_channel.rb",
81+
"snippets/livestream_service/stop_distribution.rb",
7982
"snippets/livestream_service/update_channel.rb",
8083
"snippets/livestream_service/update_dvr_session.rb",
8184
"snippets/livestream_service/update_input.rb",

google-cloud-video-live_stream-v1/gapic_metadata.json

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,16 @@
4545
"stop_channel"
4646
]
4747
},
48+
"StartDistribution": {
49+
"methods": [
50+
"start_distribution"
51+
]
52+
},
53+
"StopDistribution": {
54+
"methods": [
55+
"stop_distribution"
56+
]
57+
},
4858
"CreateInput": {
4959
"methods": [
5060
"create_input"
@@ -70,6 +80,11 @@
7080
"update_input"
7181
]
7282
},
83+
"PreviewInput": {
84+
"methods": [
85+
"preview_input"
86+
]
87+
},
7388
"CreateEvent": {
7489
"methods": [
7590
"create_event"

google-cloud-video-live_stream-v1/lib/google/cloud/video/live_stream/v1/livestream_service/client.rb

Lines changed: 396 additions & 14 deletions
Large diffs are not rendered by default.

google-cloud-video-live_stream-v1/lib/google/cloud/video/live_stream/v1/livestream_service/rest/client.rb

Lines changed: 375 additions & 14 deletions
Large diffs are not rendered by default.

google-cloud-video-live_stream-v1/lib/google/cloud/video/live_stream/v1/livestream_service/rest/service_stub.rb

Lines changed: 186 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -354,6 +354,86 @@ def stop_channel request_pb, options = nil
354354
end
355355
end
356356

357+
##
358+
# Baseline implementation for the start_distribution REST call
359+
#
360+
# @param request_pb [::Google::Cloud::Video::LiveStream::V1::StartDistributionRequest]
361+
# A request object representing the call parameters. Required.
362+
# @param options [::Gapic::CallOptions]
363+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
364+
#
365+
# @yield [result, operation] Access the result along with the TransportOperation object
366+
# @yieldparam result [::Google::Longrunning::Operation]
367+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
368+
#
369+
# @return [::Google::Longrunning::Operation]
370+
# A result object deserialized from the server's reply
371+
def start_distribution request_pb, options = nil
372+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
373+
374+
verb, uri, query_string_params, body = ServiceStub.transcode_start_distribution_request request_pb
375+
query_string_params = if query_string_params.any?
376+
query_string_params.to_h { |p| p.split "=", 2 }
377+
else
378+
{}
379+
end
380+
381+
response = @client_stub.make_http_request(
382+
verb,
383+
uri: uri,
384+
body: body || "",
385+
params: query_string_params,
386+
method_name: "start_distribution",
387+
options: options
388+
)
389+
operation = ::Gapic::Rest::TransportOperation.new response
390+
result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true
391+
catch :response do
392+
yield result, operation if block_given?
393+
result
394+
end
395+
end
396+
397+
##
398+
# Baseline implementation for the stop_distribution REST call
399+
#
400+
# @param request_pb [::Google::Cloud::Video::LiveStream::V1::StopDistributionRequest]
401+
# A request object representing the call parameters. Required.
402+
# @param options [::Gapic::CallOptions]
403+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
404+
#
405+
# @yield [result, operation] Access the result along with the TransportOperation object
406+
# @yieldparam result [::Google::Longrunning::Operation]
407+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
408+
#
409+
# @return [::Google::Longrunning::Operation]
410+
# A result object deserialized from the server's reply
411+
def stop_distribution request_pb, options = nil
412+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
413+
414+
verb, uri, query_string_params, body = ServiceStub.transcode_stop_distribution_request request_pb
415+
query_string_params = if query_string_params.any?
416+
query_string_params.to_h { |p| p.split "=", 2 }
417+
else
418+
{}
419+
end
420+
421+
response = @client_stub.make_http_request(
422+
verb,
423+
uri: uri,
424+
body: body || "",
425+
params: query_string_params,
426+
method_name: "stop_distribution",
427+
options: options
428+
)
429+
operation = ::Gapic::Rest::TransportOperation.new response
430+
result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true
431+
catch :response do
432+
yield result, operation if block_given?
433+
result
434+
end
435+
end
436+
357437
##
358438
# Baseline implementation for the create_input REST call
359439
#
@@ -554,6 +634,46 @@ def update_input request_pb, options = nil
554634
end
555635
end
556636

637+
##
638+
# Baseline implementation for the preview_input REST call
639+
#
640+
# @param request_pb [::Google::Cloud::Video::LiveStream::V1::PreviewInputRequest]
641+
# A request object representing the call parameters. Required.
642+
# @param options [::Gapic::CallOptions]
643+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
644+
#
645+
# @yield [result, operation] Access the result along with the TransportOperation object
646+
# @yieldparam result [::Google::Cloud::Video::LiveStream::V1::PreviewInputResponse]
647+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
648+
#
649+
# @return [::Google::Cloud::Video::LiveStream::V1::PreviewInputResponse]
650+
# A result object deserialized from the server's reply
651+
def preview_input request_pb, options = nil
652+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
653+
654+
verb, uri, query_string_params, body = ServiceStub.transcode_preview_input_request request_pb
655+
query_string_params = if query_string_params.any?
656+
query_string_params.to_h { |p| p.split "=", 2 }
657+
else
658+
{}
659+
end
660+
661+
response = @client_stub.make_http_request(
662+
verb,
663+
uri: uri,
664+
body: body || "",
665+
params: query_string_params,
666+
method_name: "preview_input",
667+
options: options
668+
)
669+
operation = ::Gapic::Rest::TransportOperation.new response
670+
result = ::Google::Cloud::Video::LiveStream::V1::PreviewInputResponse.decode_json response.body, ignore_unknown_fields: true
671+
catch :response do
672+
yield result, operation if block_given?
673+
result
674+
end
675+
end
676+
557677
##
558678
# Baseline implementation for the create_event REST call
559679
#
@@ -1465,6 +1585,50 @@ def self.transcode_stop_channel_request request_pb
14651585
transcoder.transcode request_pb
14661586
end
14671587

1588+
##
1589+
# @private
1590+
#
1591+
# GRPC transcoding helper method for the start_distribution REST call
1592+
#
1593+
# @param request_pb [::Google::Cloud::Video::LiveStream::V1::StartDistributionRequest]
1594+
# A request object representing the call parameters. Required.
1595+
# @return [Array(String, [String, nil], Hash{String => String})]
1596+
# Uri, Body, Query string parameters
1597+
def self.transcode_start_distribution_request request_pb
1598+
transcoder = Gapic::Rest::GrpcTranscoder.new
1599+
.with_bindings(
1600+
uri_method: :post,
1601+
uri_template: "/v1/{name}:startdistribution",
1602+
body: "*",
1603+
matches: [
1604+
["name", %r{^projects/[^/]+/locations/[^/]+/channels/[^/]+/?$}, false]
1605+
]
1606+
)
1607+
transcoder.transcode request_pb
1608+
end
1609+
1610+
##
1611+
# @private
1612+
#
1613+
# GRPC transcoding helper method for the stop_distribution REST call
1614+
#
1615+
# @param request_pb [::Google::Cloud::Video::LiveStream::V1::StopDistributionRequest]
1616+
# A request object representing the call parameters. Required.
1617+
# @return [Array(String, [String, nil], Hash{String => String})]
1618+
# Uri, Body, Query string parameters
1619+
def self.transcode_stop_distribution_request request_pb
1620+
transcoder = Gapic::Rest::GrpcTranscoder.new
1621+
.with_bindings(
1622+
uri_method: :post,
1623+
uri_template: "/v1/{name}:stopdistribution",
1624+
body: "*",
1625+
matches: [
1626+
["name", %r{^projects/[^/]+/locations/[^/]+/channels/[^/]+/?$}, false]
1627+
]
1628+
)
1629+
transcoder.transcode request_pb
1630+
end
1631+
14681632
##
14691633
# @private
14701634
#
@@ -1572,6 +1736,28 @@ def self.transcode_update_input_request request_pb
15721736
transcoder.transcode request_pb
15731737
end
15741738

1739+
##
1740+
# @private
1741+
#
1742+
# GRPC transcoding helper method for the preview_input REST call
1743+
#
1744+
# @param request_pb [::Google::Cloud::Video::LiveStream::V1::PreviewInputRequest]
1745+
# A request object representing the call parameters. Required.
1746+
# @return [Array(String, [String, nil], Hash{String => String})]
1747+
# Uri, Body, Query string parameters
1748+
def self.transcode_preview_input_request request_pb
1749+
transcoder = Gapic::Rest::GrpcTranscoder.new
1750+
.with_bindings(
1751+
uri_method: :post,
1752+
uri_template: "/v1/{name}:preview",
1753+
body: "*",
1754+
matches: [
1755+
["name", %r{^projects/[^/]+/locations/[^/]+/inputs/[^/]+/?$}, false]
1756+
]
1757+
)
1758+
transcoder.transcode request_pb
1759+
end
1760+
15751761
##
15761762
# @private
15771763
#

0 commit comments

Comments
 (0)