Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
var protoFilesRoot = new gax.GoogleProtoFilesRoot();
protoFilesRoot = protobuf.loadSync(
path.join(
__dirname,
'..',
'..',
'protos',
'google/logging/v2/logging.proto'
),
protoFilesRoot
);
// Some methods on this API support automatically batching
// requests; denote this.
this._descriptors.batching = {
writeLogEntries: new gax.BundleDescriptor(
'entries',
['logName', 'resource', 'labels'],
null,
gax.createByteLengthFunction(
protoFilesRoot.lookup('google.logging.v2.LogEntry')
)
),
};
// Put together the default options sent with requests.
var defaults = gaxGrpc.constructSettings(
'google.logging.v2.LoggingServiceV2',
gapicConfig,
opts.clientConfig,
{'x-goog-api-client': clientHeader.join(' ')}
);