New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@google-cloud/livestream

Package Overview
Dependencies
Maintainers
4
Versions
20
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@google-cloud/livestream - npm Package Compare versions

Comparing version

to
0.3.0

48

build/src/v1/livestream_service_client.js

@@ -47,3 +47,3 @@ "use strict";

* The options accepted by the constructor are described in detail
* in [this document](https://github.com/googleapis/gax-nodejs/blob/master/client-libraries.md#creating-the-client-instance).
* in [this document](https://github.com/googleapis/gax-nodejs/blob/main/client-libraries.md#creating-the-client-instance).
* The common options are:

@@ -71,7 +71,6 @@ * @param {object} [options.credentials] - Credentials object.

* Follows the structure of {@link gapicConfig}.
* @param {boolean} [options.fallback] - Use HTTP fallback mode.
* In fallback mode, a special browser-compatible transport implementation is used
* instead of gRPC transport. In browser context (if the `window` object is defined)
* the fallback mode is enabled automatically; set `options.fallback` to `false`
* if you need to override this behavior.
* @param {boolean | "rest"} [options.fallback] - Use HTTP fallback mode.
* Pass "rest" to use HTTP/1.1 REST API instead of gRPC.
* For more information, please check the
* {@link https://github.com/googleapis/gax-nodejs/blob/main/client-libraries.md#http11-rest-api-mode documentation}.
*/

@@ -156,7 +155,38 @@ constructor(opts) {

// rather than holding a request open.
this.operationsClient = this._gaxModule
.lro({
const lroOptions = {
auth: this.auth,
grpc: 'grpc' in this._gaxGrpc ? this._gaxGrpc.grpc : undefined,
})
};
if (opts.fallback === 'rest') {
lroOptions.protoJson = protoFilesRoot;
lroOptions.httpRules = [
{
selector: 'google.cloud.location.Locations.GetLocation',
get: '/v1/{name=projects/*/locations/*}',
},
{
selector: 'google.cloud.location.Locations.ListLocations',
get: '/v1/{name=projects/*}/locations',
},
{
selector: 'google.longrunning.Operations.CancelOperation',
post: '/v1/{name=projects/*/locations/*/operations/*}:cancel',
body: '*',
},
{
selector: 'google.longrunning.Operations.DeleteOperation',
delete: '/v1/{name=projects/*/locations/*/operations/*}',
},
{
selector: 'google.longrunning.Operations.GetOperation',
get: '/v1/{name=projects/*/locations/*/operations/*}',
},
{
selector: 'google.longrunning.Operations.ListOperations',
get: '/v1/{name=projects/*/locations/*}/operations',
},
];
}
this.operationsClient = this._gaxModule
.lro(lroOptions)
.operationsClient(opts);

@@ -163,0 +193,0 @@ const createChannelResponse = protoFilesRoot.lookup('.google.cloud.video.livestream.v1.Channel');

# Changelog
## [0.3.0](https://github.com/googleapis/nodejs-video-live-stream/compare/v0.2.0...v0.3.0) (2022-06-29)
### Features
* support regapic LRO ([#45](https://github.com/googleapis/nodejs-video-live-stream/issues/45)) ([fc3c1b4](https://github.com/googleapis/nodejs-video-live-stream/commit/fc3c1b426407d6ff8b825483c0ab892e25a28d09))
## [0.2.0](https://github.com/googleapis/nodejs-video-live-stream/compare/v0.1.0...v0.2.0) (2022-06-03)

@@ -4,0 +11,0 @@

6

package.json
{
"name": "@google-cloud/livestream",
"version": "0.2.0",
"version": "0.3.0",
"description": "livestream client for Node.js",

@@ -51,4 +51,4 @@ "repository": "googleapis/nodejs-video-live-stream",

"jsdoc": "^3.6.7",
"jsdoc-fresh": "^1.0.2",
"jsdoc-region-tag": "^1.0.6",
"jsdoc-fresh": "^2.0.0",
"jsdoc-region-tag": "^2.0.0",
"linkinator": "^3.0.3",

@@ -55,0 +55,0 @@ "mocha": "^9.2.2",

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet