@google-cloud/profiler 5.0.0 → 5.0.1

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.
@@ -0,0 +1,465 @@
1
+ "use strict";
2
+ // Copyright 2017 Google LLC
3
+ //
4
+ // Licensed under the Apache License, Version 2.0 (the "License");
5
+ // you may not use this file except in compliance with the License.
6
+ // You may obtain a copy of the License at
7
+ //
8
+ // http://www.apache.org/licenses/LICENSE-2.0
9
+ //
10
+ // Unless required by applicable law or agreed to in writing, software
11
+ // distributed under the License is distributed on an "AS IS" BASIS,
12
+ // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ // See the License for the specific language governing permissions and
14
+ // limitations under the License.
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.Profiler = exports.Retryer = exports.BackoffResponseError = exports.parseBackoffDuration = void 0;
17
+ const common_1 = require("@google-cloud/common");
18
+ const pprof_1 = require("pprof");
19
+ const msToStr = require("pretty-ms");
20
+ const util_1 = require("util");
21
+ const zlib = require("zlib");
22
+ const profile_1 = require("../protos/profile");
23
+ const logger_1 = require("./logger");
24
+ const parse_duration_1 = require("parse-duration");
25
+ // eslint-disable-next-line @typescript-eslint/no-var-requires
26
+ const pjson = require('../../package.json');
27
+ const SCOPE = 'https://www.googleapis.com/auth/monitoring.write';
28
+ const gzip = (0, util_1.promisify)(zlib.gzip);
29
+ var ProfileTypes;
30
+ (function (ProfileTypes) {
31
+ ProfileTypes["Wall"] = "WALL";
32
+ ProfileTypes["Heap"] = "HEAP";
33
+ })(ProfileTypes || (ProfileTypes = {}));
34
+ /**
35
+ * @return true iff http status code indicates an error.
36
+ */
37
+ function isErrorResponseStatusCode(code) {
38
+ return code < 200 || code >= 300;
39
+ }
40
+ /**
41
+ * @return the error's message, if present. Otherwise returns the
42
+ * message of the response body, if that field exists, or the response status
43
+ * message.
44
+ */
45
+ function getResponseErrorMessage(
46
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
47
+ response, err) {
48
+ if (err && err.message) {
49
+ return err.message;
50
+ }
51
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
52
+ const body = response.body;
53
+ if (body && body.message && typeof body.message === 'string') {
54
+ return body.message;
55
+ }
56
+ return response.statusMessage;
57
+ }
58
+ /**
59
+ * @return number indicated by backoff if the response indicates a backoff and
60
+ * that backoff is greater than 0. Otherwise returns undefined.
61
+ */
62
+ function getServerResponseBackoff(body) {
63
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
64
+ const b = body;
65
+ if (b.error && b.error.details && Array.isArray(b.error.details)) {
66
+ for (const item of b.error.details) {
67
+ if (typeof item === 'object' &&
68
+ item.retryDelay &&
69
+ typeof item.retryDelay === 'string') {
70
+ const backoffMillis = (0, parse_duration_1.default)(item.retryDelay);
71
+ if (backoffMillis > 0) {
72
+ return backoffMillis;
73
+ }
74
+ }
75
+ }
76
+ }
77
+ return undefined;
78
+ }
79
+ /**
80
+ * @return if the backoff duration can be parsed, then the backoff duration in
81
+ * ms, otherwise undefined.
82
+ *
83
+ * Public for testing.
84
+ */
85
+ function parseBackoffDuration(backoffMessage) {
86
+ const backoffMessageRegex = /action throttled, backoff for ((?:([0-9]+)h)?(?:([0-9]+)m)?([0-9.]+)s)$/;
87
+ const [, duration] = backoffMessageRegex.exec(backoffMessage) || [
88
+ undefined,
89
+ undefined,
90
+ ];
91
+ if (duration) {
92
+ const backoffMillis = (0, parse_duration_1.default)(duration);
93
+ if (backoffMillis > 0) {
94
+ return backoffMillis;
95
+ }
96
+ }
97
+ return undefined;
98
+ }
99
+ exports.parseBackoffDuration = parseBackoffDuration;
100
+ /**
101
+ * @return true if an deployment is a Deployment and false otherwise.
102
+ */
103
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
104
+ function isDeployment(deployment) {
105
+ return ((deployment.projectId === undefined ||
106
+ typeof deployment.projectId === 'string') &&
107
+ (deployment.target === undefined ||
108
+ typeof deployment.target === 'string') &&
109
+ deployment.labels !== undefined &&
110
+ deployment.labels.language !== undefined &&
111
+ typeof deployment.labels.language === 'string');
112
+ }
113
+ /**
114
+ * @return true if an prof is a RequestProfile and false otherwise.
115
+ */
116
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
117
+ function isRequestProfile(prof) {
118
+ return (prof &&
119
+ typeof prof.name === 'string' &&
120
+ typeof prof.profileType === 'string' &&
121
+ (prof.duration === undefined || typeof prof.duration === 'string') &&
122
+ (prof.labels === undefined ||
123
+ prof.labels.instance === undefined ||
124
+ typeof prof.labels.instance === 'string') &&
125
+ (prof.deployment === undefined || isDeployment(prof.deployment)));
126
+ }
127
+ /**
128
+ * Converts a profile to a compressed, base64 encoded string.
129
+ *
130
+ * Work for converting profile is done on the event loop. In particular,
131
+ * profile encoding is done on the event loop. So, this does block execution
132
+ * of the program, but for a short period of time, since profiles are small.
133
+ *
134
+ * @param p - profile to be converted to string.
135
+ */
136
+ async function profileBytes(p) {
137
+ const buffer = profile_1.perftools.profiles.Profile.encode(p).finish();
138
+ const gzBuf = (await gzip(buffer));
139
+ return gzBuf.toString('base64');
140
+ }
141
+ /**
142
+ * Error constructed from HTTP server response which indicates backoff.
143
+ */
144
+ class BackoffResponseError extends Error {
145
+ constructor(message, backoffMillis) {
146
+ super(message);
147
+ this.backoffMillis = backoffMillis;
148
+ }
149
+ }
150
+ exports.BackoffResponseError = BackoffResponseError;
151
+ /**
152
+ * @return true if error is a BackoffResponseError and false otherwise
153
+ */
154
+ function isBackoffResponseError(err) {
155
+ return typeof err.backoffMillis === 'number';
156
+ }
157
+ /**
158
+ * Class which tracks how long to wait before the next retry and can be
159
+ * used to get this backoff.
160
+ */
161
+ class Retryer {
162
+ constructor(initialBackoffMillis, backoffCapMillis, backoffMultiplier, random = Math.random) {
163
+ this.initialBackoffMillis = initialBackoffMillis;
164
+ this.backoffCapMillis = backoffCapMillis;
165
+ this.backoffMultiplier = backoffMultiplier;
166
+ this.nextBackoffMillis = this.initialBackoffMillis;
167
+ this.random = random;
168
+ }
169
+ getBackoff() {
170
+ const curBackoff = this.random() * this.nextBackoffMillis;
171
+ this.nextBackoffMillis = Math.min(this.backoffMultiplier * this.nextBackoffMillis, this.backoffCapMillis);
172
+ return curBackoff;
173
+ }
174
+ reset() {
175
+ this.nextBackoffMillis = this.initialBackoffMillis;
176
+ }
177
+ }
178
+ exports.Retryer = Retryer;
179
+ /**
180
+ * @return profile iff response indicates success and the returned profile was
181
+ * valid.
182
+ * @throws error when the response indicated failure or the returned profile
183
+ * was not valid.
184
+ */
185
+ function responseToProfileOrError(err, body,
186
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
187
+ response) {
188
+ // response.statusCode is guaranteed to exist on client requests.
189
+ if (response && isErrorResponseStatusCode(response.statusCode)) {
190
+ const message = getResponseErrorMessage(response, err);
191
+ if (body) {
192
+ const delayMillis = getServerResponseBackoff(body);
193
+ if (delayMillis) {
194
+ throw new BackoffResponseError(message, delayMillis);
195
+ }
196
+ }
197
+ throw new Error(message);
198
+ }
199
+ if (err) {
200
+ throw err;
201
+ }
202
+ if (isRequestProfile(body)) {
203
+ return body;
204
+ }
205
+ throw new Error(`Profile not valid: ${JSON.stringify(body)}.`);
206
+ }
207
+ /**
208
+ * Polls profiler server for instructions on behalf of a task and
209
+ * collects and uploads profiles as requested.
210
+ *
211
+ * If heap profiling is enabled, the heap profiler must be enabled before heap
212
+ * profiles can be collected.
213
+ */
214
+ class Profiler extends common_1.ServiceObject {
215
+ constructor(config) {
216
+ config = config || {};
217
+ const baseApiUrl = `https://${config.apiEndpoint}/v2`;
218
+ const serviceConfig = {
219
+ apiEndpoint: config.apiEndpoint,
220
+ baseUrl: baseApiUrl,
221
+ scopes: [SCOPE],
222
+ packageJson: pjson,
223
+ };
224
+ super({
225
+ parent: new common_1.Service(serviceConfig, config),
226
+ baseUrl: '/',
227
+ });
228
+ this.config = config;
229
+ this.baseApiUrl = baseApiUrl;
230
+ this.logger = (0, logger_1.createLogger)(this.config.logLevel);
231
+ const labels = {
232
+ language: 'nodejs',
233
+ };
234
+ if (this.config.zone) {
235
+ labels.zone = this.config.zone;
236
+ }
237
+ if (this.config.serviceContext.version) {
238
+ labels.version = this.config.serviceContext.version;
239
+ }
240
+ this.deployment = {
241
+ projectId: this.config.projectId,
242
+ target: this.config.serviceContext.service,
243
+ labels,
244
+ };
245
+ this.profileLabels = {};
246
+ if (this.config.instance) {
247
+ this.profileLabels.instance = this.config.instance;
248
+ }
249
+ this.profileTypes = [];
250
+ if (!this.config.disableTime) {
251
+ this.profileTypes.push(ProfileTypes.Wall);
252
+ }
253
+ if (!this.config.disableHeap) {
254
+ this.profileTypes.push(ProfileTypes.Heap);
255
+ }
256
+ this.retryer = new Retryer(this.config.initialBackoffMillis, this.config.backoffCapMillis, this.config.backoffMultiplier);
257
+ }
258
+ /**
259
+ * Starts an endless loop to poll profiler server for instructions, and
260
+ * collects and uploads profiles as requested.
261
+ * If there is a problem when collecting a profile or uploading a profile to
262
+ * profiler server, this problem will be logged at the error level and
263
+ * otherwise ignored.
264
+ * If there is a problem polling profiler server for instructions
265
+ * on the type of profile to be collected, this problem will be logged at the
266
+ * error level and getting profile type will be retried.
267
+ */
268
+ async start() {
269
+ if (!this.config.disableSourceMaps) {
270
+ try {
271
+ this.sourceMapper = await pprof_1.SourceMapper.create(this.config.sourceMapSearchPath);
272
+ }
273
+ catch (err) {
274
+ this.logger.error(`Failed to initialize SourceMapper. Source map support has been disabled: ${err}`);
275
+ this.config.disableSourceMaps = true;
276
+ }
277
+ }
278
+ this.logger.debug(`Cloud Profiler Node.js agent version: ${pjson.version}`);
279
+ this.runLoop();
280
+ }
281
+ /**
282
+ * Endlessly polls the profiler server for instructions, and collects and
283
+ * uploads profiles as requested.
284
+ */
285
+ async runLoop() {
286
+ const delayMillis = await this.collectProfile();
287
+ setTimeout(this.runLoop.bind(this), delayMillis).unref();
288
+ }
289
+ /**
290
+ * Waits for profiler server to tell it to collect a profile, then collects
291
+ * a profile and uploads it.
292
+ *
293
+ * @return time, in ms, to wait before asking profiler server again about
294
+ * collecting another profile.
295
+ */
296
+ async collectProfile() {
297
+ let prof;
298
+ try {
299
+ prof = await this.createProfile();
300
+ }
301
+ catch (err) {
302
+ if (isBackoffResponseError(err)) {
303
+ this.logger.debug(`Must wait ${msToStr(err.backoffMillis)} to create profile: ${err}`);
304
+ return Math.min(err.backoffMillis, this.config.serverBackoffCapMillis);
305
+ }
306
+ const backoff = this.retryer.getBackoff();
307
+ this.logger.warn(`Failed to create profile, waiting ${msToStr(backoff)} to try again: ${err}`);
308
+ return backoff;
309
+ }
310
+ this.retryer.reset();
311
+ await this.profileAndUpload(prof);
312
+ return 0;
313
+ }
314
+ /**
315
+ * Talks to profiler server, which hangs until server indicates
316
+ * job should be profiled and then indicates what type of profile should
317
+ * be collected.
318
+ *
319
+ * If any problem is encountered, an error will be thrown.
320
+ *
321
+ * @return a RequestProfile specifying which type of profile should be
322
+ * collected and other information needed to collect and upload a profile of
323
+ * the specified type.
324
+ *
325
+ * TODO (issue #28): right now, this call could hang for up to an hour when
326
+ * this method is the only thing on the event loop, keeping the program open
327
+ * even when all work is done. Should expose the ability to cancel the http
328
+ * request made here, and then determine when to cancel this request.
329
+ *
330
+ * Public to allow for testing.
331
+ */
332
+ async createProfile() {
333
+ const reqBody = {
334
+ deployment: this.deployment,
335
+ profileType: this.profileTypes,
336
+ };
337
+ const options = {
338
+ method: 'POST',
339
+ uri: '/profiles',
340
+ body: reqBody,
341
+ json: true,
342
+ maxRetries: 0,
343
+ // Default timeout for for a request is 1 minute, but request to create
344
+ // profile is designed to hang until it is time to collect a profile
345
+ // (up to one hour).
346
+ timeout: (0, parse_duration_1.default)('1h'),
347
+ };
348
+ this.logger.debug('Attempting to create profile.');
349
+ return new Promise((resolve, reject) => {
350
+ this.request(options, (err, body,
351
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
352
+ response) => {
353
+ try {
354
+ const prof = responseToProfileOrError(err, body, response);
355
+ this.logger.debug(`Successfully created profile ${prof.profileType}.`);
356
+ resolve(prof);
357
+ }
358
+ catch (err) {
359
+ reject(err);
360
+ }
361
+ });
362
+ });
363
+ }
364
+ /**
365
+ * Collects a profile of the type specified by the profileType field of prof.
366
+ * If any problem is encountered, like a problem collecting or uploading the
367
+ * profile, a message will be logged, and the error will otherwise be ignored.
368
+ *
369
+ * Public to allow for testing.
370
+ */
371
+ async profileAndUpload(prof) {
372
+ try {
373
+ prof = await this.profile(prof);
374
+ this.logger.debug(`Successfully collected profile ${prof.profileType}.`);
375
+ prof.labels = this.profileLabels;
376
+ }
377
+ catch (err) {
378
+ this.logger.debug(`Failed to collect profile: ${err}`);
379
+ return;
380
+ }
381
+ const options = {
382
+ method: 'PATCH',
383
+ uri: this.baseApiUrl + '/' + prof.name,
384
+ body: prof,
385
+ json: true,
386
+ maxRetries: 0,
387
+ };
388
+ try {
389
+ const [, res] = await this.request(options);
390
+ if (isErrorResponseStatusCode(res.statusCode)) {
391
+ let message = res.statusCode;
392
+ if (res.statusMessage) {
393
+ message = res.statusMessage;
394
+ }
395
+ this.logger.debug(`Could not upload profile: ${message}.`);
396
+ return;
397
+ }
398
+ this.logger.debug(`Successfully uploaded profile ${prof.profileType}.`);
399
+ }
400
+ catch (err) {
401
+ this.logger.debug(`Failed to upload profile: ${err}`);
402
+ }
403
+ }
404
+ /**
405
+ * Collects a profile of the type specified by profileType field of prof.
406
+ * If any problem is encountered, for example the profileType is not
407
+ * recognized or profiling is disabled for the specified profileType, an
408
+ * error will be thrown.
409
+ *
410
+ * Public to allow for testing.
411
+ */
412
+ async profile(prof) {
413
+ switch (prof.profileType) {
414
+ case ProfileTypes.Wall:
415
+ return this.writeTimeProfile(prof);
416
+ case ProfileTypes.Heap:
417
+ return this.writeHeapProfile(prof);
418
+ default:
419
+ throw new Error(`Unexpected profile type ${prof.profileType}.`);
420
+ }
421
+ }
422
+ /**
423
+ * Collects a time profile, converts profile to compressed, base64 encoded
424
+ * string, and puts this string in profileBytes field of prof.
425
+ *
426
+ * Public to allow for testing.
427
+ */
428
+ async writeTimeProfile(prof) {
429
+ if (this.config.disableTime) {
430
+ throw Error('Cannot collect time profile, time profiler not enabled.');
431
+ }
432
+ if (prof.duration === undefined) {
433
+ throw Error('Cannot collect time profile, duration is undefined.');
434
+ }
435
+ const durationMillis = (0, parse_duration_1.default)(prof.duration);
436
+ if (!durationMillis) {
437
+ throw Error(`Cannot collect time profile, duration "${prof.duration}" cannot` +
438
+ ' be parsed.');
439
+ }
440
+ const options = {
441
+ durationMillis,
442
+ intervalMicros: this.config.timeIntervalMicros,
443
+ sourceMapper: this.sourceMapper,
444
+ };
445
+ const p = await pprof_1.time.profile(options);
446
+ prof.profileBytes = await profileBytes(p);
447
+ return prof;
448
+ }
449
+ /**
450
+ * Collects a heap profile, converts profile to compressed, base64 encoded
451
+ * string, and adds profileBytes field to prof with this string.
452
+ *
453
+ * Public to allow for testing.
454
+ */
455
+ async writeHeapProfile(prof) {
456
+ if (this.config.disableHeap) {
457
+ throw Error('Cannot collect heap profile, heap profiler not enabled.');
458
+ }
459
+ const p = pprof_1.heap.profile(this.config.ignoreHeapSamplesPath, this.sourceMapper);
460
+ prof.profileBytes = await profileBytes(p);
461
+ return prof;
462
+ }
463
+ }
464
+ exports.Profiler = Profiler;
465
+ //# sourceMappingURL=profiler.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"profiler.js","sourceRoot":"","sources":["../../src/profiler.ts"],"names":[],"mappings":";AAAA,4BAA4B;AAC5B,EAAE;AACF,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,kDAAkD;AAClD,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;;;AAEjC,iDAM8B;AAC9B,iCAA+E;AAC/E,qCAAqC;AACrC,+BAA+B;AAC/B,6BAA6B;AAG7B,+CAA4C;AAE5C,qCAAsC;AAEtC,mDAA2C;AAC3C,8DAA8D;AAC9D,MAAM,KAAK,GAAG,OAAO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AC;SACH;QACD,MAAM,OAAO,GAAG;YACd,cAAc;YACd,cAAc,EAAE,IAAI,CAAC,MAAM,CAAC,kBAAkB;YAC9C,YAAY,EAAE,IAAI,CAAC,YAAY;SAChC,CAAC;QAEF,MAAM,CAAC,GAAG,MAAM,YAAY,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC;QAC9C,IAAI,CAAC,YAAY,GAAG,MAAM,YAAY,CAAC,CAAC,CAAC,CAAC;QAC1C,OAAO,IAAI,CAAC;IACd,CAAC;IAED;;;;;OAKG;IACH,KAAK,CAAC,gBAAgB,CAAC,IAAoB;QACzC,IAAI,IAAI,CAAC,MAAM,CAAC,WAAW,EAAE;YAC3B,MAAM,KAAK,CAAC,yDAAyD,CAAC,CAAC;SACxE;QACD,MAAM,CAAC,GAAG,YAAY,CAAC,OAAO,CAC5B,IAAI,CAAC,MAAM,CAAC,qBAAqB,EACjC,IAAI,CAAC,YAAY,CAClB,CAAC;QACF,IAAI,CAAC,YAAY,GAAG,MAAM,YAAY,CAAC,CAAC,CAAC,CAAC;QAC1C,OAAO,IAAI,CAAC;IACd,CAAC;CACF;AA/SD,4BA+SC"}
@@ -0,0 +1,25 @@
1
+ export interface TimeProfile {
2
+ /** Time in nanoseconds at which profile was stopped. */
3
+ endTime: number;
4
+ topDownRoot: TimeProfileNode;
5
+ /** Time in nanoseconds at which profile was started. */
6
+ startTime: number;
7
+ }
8
+ export interface ProfileNode {
9
+ name?: string;
10
+ scriptName: string;
11
+ scriptId?: number;
12
+ lineNumber?: number;
13
+ columnNumber?: number;
14
+ children: ProfileNode[];
15
+ }
16
+ export interface TimeProfileNode extends ProfileNode {
17
+ hitCount: number;
18
+ }
19
+ export interface AllocationProfileNode extends ProfileNode {
20
+ allocations: Allocation[];
21
+ }
22
+ export interface Allocation {
23
+ sizeBytes: number;
24
+ count: number;
25
+ }
@@ -0,0 +1,16 @@
1
+ "use strict";
2
+ // Copyright 2017 Google LLC
3
+ //
4
+ // Licensed under the Apache License, Version 2.0 (the "License");
5
+ // you may not use this file except in compliance with the License.
6
+ // You may obtain a copy of the License at
7
+ //
8
+ // http://www.apache.org/licenses/LICENSE-2.0
9
+ //
10
+ // Unless required by applicable law or agreed to in writing, software
11
+ // distributed under the License is distributed on an "AS IS" BASIS,
12
+ // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ // See the License for the specific language governing permissions and
14
+ // limitations under the License.
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ //# sourceMappingURL=v8-types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"v8-types.js","sourceRoot":"","sources":["../../src/v8-types.ts"],"names":[],"mappings":";AAAA,4BAA4B;AAC5B,EAAE;AACF,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,kDAAkD;AAClD,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@google-cloud/profiler",
3
- "version": "5.0.0",
3
+ "version": "5.0.1",
4
4
  "description": "Adds support for Cloud Profiler to Node.js applications",
5
5
  "repository": "googleapis/cloud-profiler-nodejs",
6
6
  "main": "build/src/index.js",
@@ -70,7 +70,6 @@
70
70
  "files": [
71
71
  "build/src",
72
72
  "build/third_party/cloud-debug-nodejs",
73
- "bindings",
74
73
  "build/protos"
75
74
  ],
76
75
  "nyc": {
@@ -1,86 +0,0 @@
1
- {
2
- "name": "@google-cloud/profiler",
3
- "version": "5.0.0",
4
- "description": "Adds support for Cloud Profiler to Node.js applications",
5
- "repository": "googleapis/cloud-profiler-nodejs",
6
- "main": "build/src/index.js",
7
- "types": "build/src/index.d.ts",
8
- "scripts": {
9
- "test": "c8 mocha build/test/test-*.js",
10
- "system-test": "c8 --no-clean mocha build/system-test/test-*.js --timeout=60000",
11
- "samples-test": "echo 'no sample tests'",
12
- "clean": "gts clean",
13
- "compile": "tsc -p . && cp -R protos build",
14
- "fix": "gts fix",
15
- "lint": "gts check",
16
- "docs": "jsdoc -c .jsdoc.js",
17
- "prelint": "cd samples; npm link ../; npm install",
18
- "prepare": "npm run compile",
19
- "pretest": "npm run compile",
20
- "proto": "mkdir -p protos && pbjs -t static-module -w commonjs -o protos/profiler.js third_party/googleapis/google/devtools/cloudprofiler/v2/profiler.proto && pbts -o protos/profiler.d.ts protos/profiler.js",
21
- "license-check": "jsgl --local .",
22
- "docs-test": "linkinator docs",
23
- "predocs-test": "npm run docs",
24
- "precompile": "gts clean"
25
- },
26
- "author": {
27
- "name": "Google Inc."
28
- },
29
- "license": "Apache-2.0",
30
- "dependencies": {
31
- "@google-cloud/common": "^4.0.0",
32
- "@google-cloud/logging-min": "^10.0.0",
33
- "@types/console-log-level": "^1.4.0",
34
- "@types/semver": "^7.0.0",
35
- "console-log-level": "^1.4.0",
36
- "delay": "^5.0.0",
37
- "extend": "^3.0.2",
38
- "gcp-metadata": "^4.0.0",
39
- "parse-duration": "^1.0.0",
40
- "pprof": "3.2.0",
41
- "pretty-ms": "^7.0.0",
42
- "protobufjs": "~6.11.0",
43
- "semver": "^7.0.0",
44
- "teeny-request": "^8.0.0"
45
- },
46
- "devDependencies": {
47
- "@types/extend": "^3.0.0",
48
- "@types/long": "^4.0.0",
49
- "@types/mocha": "^9.0.0",
50
- "@types/nock": "^10.0.0",
51
- "@types/node": "^16.0.0",
52
- "@types/pretty-ms": "^4.0.0",
53
- "@types/sinon": "^10.0.0",
54
- "@types/tmp": "0.2.3",
55
- "c8": "^7.0.0",
56
- "codecov": "^3.0.0",
57
- "gts": "^3.1.0",
58
- "js-green-licenses": "^3.0.0",
59
- "jsdoc": "^3.6.2",
60
- "jsdoc-fresh": "^2.0.0",
61
- "jsdoc-region-tag": "^2.0.0",
62
- "linkinator": "^2.0.0",
63
- "mocha": "^9.2.2",
64
- "nock": "^13.0.0",
65
- "sinon": "^14.0.0",
66
- "source-map": "^0.7.0",
67
- "tmp": "0.2.1",
68
- "typescript": "^4.7.2"
69
- },
70
- "files": [
71
- "build/src",
72
- "build/third_party/cloud-debug-nodejs",
73
- "bindings",
74
- "build/protos"
75
- ],
76
- "nyc": {
77
- "exclude": [
78
- "protos",
79
- "build/test",
80
- "build/system-test"
81
- ]
82
- },
83
- "engines": {
84
- "node": ">=12.0.0"
85
- }
86
- }