@google-cloud/profiler 6.0.2 → 6.0.4
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.
- package/README.md +9 -292
- package/build/src/config.js +3 -3
- package/build/src/config.js.map +1 -1
- package/build/src/index.js +5 -4
- package/build/src/index.js.map +1 -1
- package/build/src/logger.js +2 -2
- package/build/src/logger.js.map +1 -1
- package/build/src/profiler.d.ts +0 -7
- package/build/src/profiler.js +9 -25
- package/build/src/profiler.js.map +1 -1
- package/package.json +18 -10
- package/CHANGELOG.md +0 -341
package/README.md
CHANGED
|
@@ -2,10 +2,10 @@
|
|
|
2
2
|
[//]: # "To regenerate it, use `python -m synthtool`."
|
|
3
3
|
<img src="https://avatars2.githubusercontent.com/u/2810941?v=3&s=96" alt="Google Cloud Platform logo" title="Google Cloud Platform" align="right" height="96" width="96"/>
|
|
4
4
|
|
|
5
|
-
# [Cloud Profiler: Node.js Client](https://github.com/googleapis/cloud-profiler
|
|
5
|
+
# [Cloud Profiler: Node.js Client](https://github.com/googleapis/google-cloud-node/tree/main/handwritten/cloud-profiler)
|
|
6
6
|
|
|
7
7
|
[](https://cloud.google.com/terms/launch-stages)
|
|
8
|
-
[](https://www.npmjs.
|
|
8
|
+
[](https://www.npmjs.com/package/@google-cloud/profiler)
|
|
9
9
|
|
|
10
10
|
|
|
11
11
|
|
|
@@ -14,11 +14,11 @@ Adds support for Cloud Profiler to Node.js applications
|
|
|
14
14
|
|
|
15
15
|
|
|
16
16
|
A comprehensive list of changes in each version may be found in
|
|
17
|
-
[the CHANGELOG](https://github.com/googleapis/cloud-
|
|
17
|
+
[the CHANGELOG](https://github.com/googleapis/google-cloud-node/tree/main/handwritten/cloud-profiler/CHANGELOG.md).
|
|
18
18
|
|
|
19
19
|
* [Cloud Profiler Node.js Client API Reference][client-docs]
|
|
20
20
|
* [Cloud Profiler Documentation][product-docs]
|
|
21
|
-
* [github.com/googleapis/cloud-profiler
|
|
21
|
+
* [github.com/googleapis/google-cloud-node/handwritten/cloud-profiler](https://github.com/googleapis/google-cloud-node/tree/main/handwritten/cloud-profiler)
|
|
22
22
|
|
|
23
23
|
Read more about the client libraries for Cloud APIs, including the older
|
|
24
24
|
Google APIs Client Libraries, in [Client Libraries Explained][explained].
|
|
@@ -32,7 +32,7 @@ Google APIs Client Libraries, in [Client Libraries Explained][explained].
|
|
|
32
32
|
* [Before you begin](#before-you-begin)
|
|
33
33
|
* [Installing the client library](#installing-the-client-library)
|
|
34
34
|
|
|
35
|
-
|
|
35
|
+
|
|
36
36
|
* [Versioning](#versioning)
|
|
37
37
|
* [Contributing](#contributing)
|
|
38
38
|
* [License](#license)
|
|
@@ -43,7 +43,7 @@ Google APIs Client Libraries, in [Client Libraries Explained][explained].
|
|
|
43
43
|
|
|
44
44
|
1. [Select or create a Cloud Platform project][projects].
|
|
45
45
|
1. [Enable the Cloud Profiler API][enable_api].
|
|
46
|
-
1. [Set up authentication
|
|
46
|
+
1. [Set up authentication][auth] so you can access the
|
|
47
47
|
API from your local workstation.
|
|
48
48
|
|
|
49
49
|
### Installing the client library
|
|
@@ -53,289 +53,6 @@ npm install @google-cloud/profiler
|
|
|
53
53
|
```
|
|
54
54
|
|
|
55
55
|
|
|
56
|
-
### Prerequisites
|
|
57
|
-
|
|
58
|
-
1. Your application will need to be using Node.js version between 14 and 20.
|
|
59
|
-
|
|
60
|
-
1. `@google-cloud/profiler` depends on the
|
|
61
|
-
[`pprof`](https://www.npmjs.com/package/pprof) module, a module with a native
|
|
62
|
-
component that is used to collect profiles with v8's CPU and Heap profilers.
|
|
63
|
-
You may need to install additional dependencies to build the `pprof` module.
|
|
64
|
-
* For Linux: `pprof` has prebuilt binaries available for Linux and Alpine
|
|
65
|
-
Linux for Node 14 and 16. No additional dependencies are required.
|
|
66
|
-
* For other environments: when using `@google-cloud/profiler` on environments
|
|
67
|
-
that `pprof` does not have prebuilt binaries for, the module
|
|
68
|
-
[`node-gyp`](https://www.npmjs.com/package/node-gyp) will be used to
|
|
69
|
-
build binaries. See `node-gyp`'s
|
|
70
|
-
[documentation](https://github.com/nodejs/node-gyp#installation)
|
|
71
|
-
for information on dependencies required to build binaries with `node-gyp`.
|
|
72
|
-
|
|
73
|
-
1. You will need a project in the [Google Developers Console][cloud-console].
|
|
74
|
-
Your application can run anywhere, but the profiler data is associated with a
|
|
75
|
-
particular project.
|
|
76
|
-
|
|
77
|
-
1. You will need to enable the Cloud Profiler API for your project.
|
|
78
|
-
|
|
79
|
-
### Basic Set-up
|
|
80
|
-
|
|
81
|
-
1. Install `@google-cloud/profiler` with [`npm`](https://www.npmjs.com) or add
|
|
82
|
-
to your [`package.json`](https://docs.npmjs.com/files/package.json#dependencies).
|
|
83
|
-
|
|
84
|
-
```sh
|
|
85
|
-
# Install through npm while saving to the local 'package.json'
|
|
86
|
-
npm install --save @google-cloud/profiler
|
|
87
|
-
```
|
|
88
|
-
|
|
89
|
-
2. Include and start the profiler at the beginning of your application:
|
|
90
|
-
|
|
91
|
-
```js
|
|
92
|
-
require('@google-cloud/profiler').start().catch((err) => {
|
|
93
|
-
console.log(`Failed to start profiler: ${err}`);
|
|
94
|
-
});
|
|
95
|
-
```
|
|
96
|
-
|
|
97
|
-
Some environments require a configuration to be passed to the `start()`
|
|
98
|
-
function. For more details on this, see instructions for running
|
|
99
|
-
[outside of Google Cloud Platform](#running-elsewhere), on
|
|
100
|
-
[App Engine flexible environment](#running-on-app-engine-flexible-environment),
|
|
101
|
-
on [Google Compute Engine](#running-on-google-compute-engine),
|
|
102
|
-
and on [Google Container Engine](#running-on-google-container-engine).
|
|
103
|
-
|
|
104
|
-
3. If you are running your application locally, or on a machine where you are
|
|
105
|
-
using the [Google Cloud SDK][gcloud-sdk], make sure to log in with the
|
|
106
|
-
application default credentials:
|
|
107
|
-
|
|
108
|
-
```sh
|
|
109
|
-
gcloud beta auth application-default login
|
|
110
|
-
```
|
|
111
|
-
|
|
112
|
-
Alternatively, you can set `GOOGLE_APPLICATION_CREDENTIALS`. For more
|
|
113
|
-
details on this, see [Running elsewhere](#running-elsewhere)
|
|
114
|
-
|
|
115
|
-
### Configuration
|
|
116
|
-
|
|
117
|
-
See [the default configuration](https://github.com/googleapis/cloud-profiler-nodejs/blob/master/src/config.ts) for a list of possible
|
|
118
|
-
configuration options. These options can be passed to the agent through the
|
|
119
|
-
object argument to the start command shown below:
|
|
120
|
-
|
|
121
|
-
```js
|
|
122
|
-
await require('@google-cloud/profiler').start({disableTime: true});
|
|
123
|
-
```
|
|
124
|
-
|
|
125
|
-
Alternatively, you can provide the configuration through a config file. This
|
|
126
|
-
can be useful if you want to load our module using `--require` on the command
|
|
127
|
-
line (which requires and starts the agent) instead of editing your main script.
|
|
128
|
-
The `GCLOUD_PROFILER_CONFIG` environment variable should point to your
|
|
129
|
-
configuration file.
|
|
130
|
-
|
|
131
|
-
```bash
|
|
132
|
-
export GCLOUD_PROFILER_CONFIG=./path/to/your/profiler/configuration.js
|
|
133
|
-
```
|
|
134
|
-
|
|
135
|
-
#### Changing log level
|
|
136
|
-
|
|
137
|
-
The profiler writes log statements to the console log for diagnostic purposes.
|
|
138
|
-
By default, the log level is set to warn. You can adjust this by setting
|
|
139
|
-
`logLevel` in the config. Setting `logLevel` to 0 will disable logging,
|
|
140
|
-
1 sets log level to error, 2 sets it to warn (default), 3 sets it to info,
|
|
141
|
-
and 4 sets it to debug.
|
|
142
|
-
|
|
143
|
-
So, for example, to start the profiler with the log level at debug, you would
|
|
144
|
-
do this:
|
|
145
|
-
|
|
146
|
-
```js
|
|
147
|
-
await require('@google-cloud/profiler').start({logLevel: 4});
|
|
148
|
-
```
|
|
149
|
-
|
|
150
|
-
#### Disabling heap or time profile collection
|
|
151
|
-
|
|
152
|
-
By default, the profiler collects both heap profiles, which show memory
|
|
153
|
-
allocations, and time profiles, which capture how much wall-clock time is spent
|
|
154
|
-
in different locations of the code. Using the configuration, it is possible to
|
|
155
|
-
disable the collection of either type of profile.
|
|
156
|
-
|
|
157
|
-
To disable time profile collection, set `disableTime` to true:
|
|
158
|
-
|
|
159
|
-
```js
|
|
160
|
-
await require('@google-cloud/profiler').start({disableTime: true});
|
|
161
|
-
```
|
|
162
|
-
|
|
163
|
-
To disable heap profile collection, set `disableHeap` to true:
|
|
164
|
-
|
|
165
|
-
```js
|
|
166
|
-
await require('@google-cloud/profiler').start({disableHeap: true});
|
|
167
|
-
```
|
|
168
|
-
|
|
169
|
-
### Running on Google Cloud Platform
|
|
170
|
-
|
|
171
|
-
There are three different services that can host Node.js applications within
|
|
172
|
-
Google Cloud Platform: Google App Engine flexible environment, Google Compute
|
|
173
|
-
Engine, and Google Container Engine. After installing `@google-cloud/profiler`
|
|
174
|
-
in your project and ensuring that the environment you are using uses a
|
|
175
|
-
supported version of Node.js, follow the service-specific instructions to
|
|
176
|
-
enable the profiler.
|
|
177
|
-
|
|
178
|
-
#### Running on App Engine flexible environment
|
|
179
|
-
|
|
180
|
-
To enable the profiling agent for a Node.js program running in the App Engine
|
|
181
|
-
flexible environment, import the agent at the top of your application’s main
|
|
182
|
-
script or entry point by including the following code snippet:
|
|
183
|
-
|
|
184
|
-
```js
|
|
185
|
-
require('@google-cloud/profiler').start();
|
|
186
|
-
```
|
|
187
|
-
|
|
188
|
-
You can specify which version of Node.js you're using by adding a snippet like
|
|
189
|
-
the following to your `package.json`:
|
|
190
|
-
|
|
191
|
-
```json
|
|
192
|
-
"engines": {
|
|
193
|
-
"node": ">=14.0.0"
|
|
194
|
-
}
|
|
195
|
-
```
|
|
196
|
-
The above snippet will ensure that you're using 14.0.0 or greater.
|
|
197
|
-
|
|
198
|
-
Deploy your application to App Engine Flexible environment as usual.
|
|
199
|
-
|
|
200
|
-
#### Running on Google Compute Engine
|
|
201
|
-
|
|
202
|
-
To enable the profiling agent for a Node.js program running in the Google
|
|
203
|
-
Compute Engine environment, import the agent at the top of your application’s
|
|
204
|
-
main script or entry point by including the following code snippet:
|
|
205
|
-
|
|
206
|
-
```js
|
|
207
|
-
require('@google-cloud/profiler').start({
|
|
208
|
-
serviceContext: {
|
|
209
|
-
service: 'your-service',
|
|
210
|
-
version: '1.0.0'
|
|
211
|
-
}
|
|
212
|
-
});
|
|
213
|
-
```
|
|
214
|
-
|
|
215
|
-
#### Running on Google Container Engine
|
|
216
|
-
|
|
217
|
-
To enable the profiling agent for a Node.js program running in the Google
|
|
218
|
-
Container Engine environment, import the agent at the top of your application’s
|
|
219
|
-
main script or entry point by including the following code snippet:
|
|
220
|
-
|
|
221
|
-
```js
|
|
222
|
-
require('@google-cloud/profiler').start({
|
|
223
|
-
serviceContext: {
|
|
224
|
-
service: 'your-service',
|
|
225
|
-
version: '1.0.0'
|
|
226
|
-
}
|
|
227
|
-
});
|
|
228
|
-
```
|
|
229
|
-
|
|
230
|
-
#### Running on Istio
|
|
231
|
-
|
|
232
|
-
On Istio, the GCP Metadata server may not be available for a few seconds after
|
|
233
|
-
your application has started. When this occurs, the profiling agent may fail
|
|
234
|
-
to start because it cannot initialize required fields. One can retry when
|
|
235
|
-
starting the profiler with the following snippet.
|
|
236
|
-
|
|
237
|
-
```js
|
|
238
|
-
const profiler = require('@google-cloud/profiler');
|
|
239
|
-
async function startProfiler() {
|
|
240
|
-
for (let i = 0; i < 3; i++) {
|
|
241
|
-
try {
|
|
242
|
-
await profiler.start({
|
|
243
|
-
serviceContext: {
|
|
244
|
-
service: 'your-service',
|
|
245
|
-
version: '1.0.0',
|
|
246
|
-
},
|
|
247
|
-
});
|
|
248
|
-
} catch(e) {
|
|
249
|
-
console.log(`Failed to start profiler: ${e}`);
|
|
250
|
-
}
|
|
251
|
-
|
|
252
|
-
// Wait for 1 second before trying again.
|
|
253
|
-
await new Promise(r => setTimeout(r, 1000));
|
|
254
|
-
}
|
|
255
|
-
}
|
|
256
|
-
startProfiler();
|
|
257
|
-
|
|
258
|
-
```
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
### Running elsewhere
|
|
262
|
-
|
|
263
|
-
You can still use `@google-cloud/profiler` if your application is running
|
|
264
|
-
outside of Google Cloud Platform, for example, running locally, on-premise, or
|
|
265
|
-
on another cloud provider.
|
|
266
|
-
|
|
267
|
-
1. You will need to specify your project id and the service you want the
|
|
268
|
-
collected profiles to be associated with, and (optionally) the version of
|
|
269
|
-
the service when starting the profiler:
|
|
270
|
-
|
|
271
|
-
```js
|
|
272
|
-
await require('@google-cloud/profiler').start({
|
|
273
|
-
projectId: 'project-id',
|
|
274
|
-
serviceContext: {
|
|
275
|
-
service: 'your-service',
|
|
276
|
-
version: '1.0.0'
|
|
277
|
-
}
|
|
278
|
-
});
|
|
279
|
-
```
|
|
280
|
-
2. You will need to provide credential for your application.
|
|
281
|
-
|
|
282
|
-
* If you are running your application on a development machine or test
|
|
283
|
-
environment where you are using the [`gcloud` command line tools][gcloud-sdk],
|
|
284
|
-
and are logged using `gcloud beta auth application-default login`, you
|
|
285
|
-
already have sufficient credentials, and a service account key is not
|
|
286
|
-
required.
|
|
287
|
-
|
|
288
|
-
* You can provide credentials via
|
|
289
|
-
[Application Default Credentials][app-default-credentials]. This is the
|
|
290
|
-
recommended method.
|
|
291
|
-
1. [Create a new JSON service account key][service-account].
|
|
292
|
-
2. Copy the key somewhere your application can access it. Be sure not
|
|
293
|
-
to expose the key publicly.
|
|
294
|
-
3. Set the environment variable `GOOGLE_APPLICATION_CREDENTIALS` to
|
|
295
|
-
the full path to the key. The profiler will automatically look for
|
|
296
|
-
this environment variable.
|
|
297
|
-
|
|
298
|
-
* You may set the `keyFilename` or `credentials` configuration field to the
|
|
299
|
-
full path or contents to the key file, respectively. Setting either of these
|
|
300
|
-
fields will override either setting `GOOGLE_APPLICATION_CREDENTIALS` or
|
|
301
|
-
logging in using `gcloud`.
|
|
302
|
-
|
|
303
|
-
This is how you would set `keyFilename`:
|
|
304
|
-
```js
|
|
305
|
-
await require('@google-cloud/profiler').start({
|
|
306
|
-
projectId: 'project-id',
|
|
307
|
-
serviceContext: {
|
|
308
|
-
service: 'your-service',
|
|
309
|
-
version: '1.0.0'
|
|
310
|
-
},
|
|
311
|
-
keyFilename: '/path/to/keyfile'
|
|
312
|
-
});
|
|
313
|
-
```
|
|
314
|
-
|
|
315
|
-
This is how you would set `credentials`:
|
|
316
|
-
```js
|
|
317
|
-
await require('@google-cloud/profiler').start({
|
|
318
|
-
projectId: 'project-id',
|
|
319
|
-
serviceContext: {
|
|
320
|
-
service: 'your-service',
|
|
321
|
-
version: '1.0.0'
|
|
322
|
-
},
|
|
323
|
-
credentials: {
|
|
324
|
-
client_email: 'email',
|
|
325
|
-
private_key: 'private_key'
|
|
326
|
-
}
|
|
327
|
-
});
|
|
328
|
-
```
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
## Samples
|
|
332
|
-
|
|
333
|
-
Samples are in the [`samples/`](https://github.com/googleapis/cloud-profiler-nodejs/tree/main/samples) directory. Each sample's `README.md` has instructions for running its sample.
|
|
334
|
-
|
|
335
|
-
| Sample | Source Code | Try it |
|
|
336
|
-
| --------------------------- | --------------------------------- | ------ |
|
|
337
|
-
| App | [source code](https://github.com/googleapis/cloud-profiler-nodejs/blob/main/samples/app.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/cloud-profiler-nodejs&page=editor&open_in_editor=samples/app.js,samples/README.md) |
|
|
338
|
-
| Snippets | [source code](https://github.com/googleapis/cloud-profiler-nodejs/blob/main/samples/snippets.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/cloud-profiler-nodejs&page=editor&open_in_editor=samples/snippets.js,samples/README.md) |
|
|
339
56
|
|
|
340
57
|
|
|
341
58
|
|
|
@@ -385,7 +102,7 @@ More Information: [Google Cloud Platform Launch Stages][launch_stages]
|
|
|
385
102
|
|
|
386
103
|
## Contributing
|
|
387
104
|
|
|
388
|
-
Contributions welcome! See the [Contributing Guide](https://github.com/googleapis/cloud-
|
|
105
|
+
Contributions welcome! See the [Contributing Guide](https://github.com/googleapis/google-cloud-node/blob/main/CONTRIBUTING.md).
|
|
389
106
|
|
|
390
107
|
Please note that this `README.md`, the `samples/README.md`,
|
|
391
108
|
and a variety of configuration files in this repository (including `.nycrc` and `tsconfig.json`)
|
|
@@ -397,7 +114,7 @@ to its templates in
|
|
|
397
114
|
|
|
398
115
|
Apache Version 2.0
|
|
399
116
|
|
|
400
|
-
See [LICENSE](https://github.com/googleapis/cloud-
|
|
117
|
+
See [LICENSE](https://github.com/googleapis/google-cloud-node/blob/main/LICENSE)
|
|
401
118
|
|
|
402
119
|
[client-docs]: https://cloud.google.com/nodejs/docs/reference/profiler/latest
|
|
403
120
|
[product-docs]: https://cloud.google.com/profiler/docs
|
|
@@ -405,4 +122,4 @@ See [LICENSE](https://github.com/googleapis/cloud-profiler-nodejs/blob/main/LICE
|
|
|
405
122
|
[projects]: https://console.cloud.google.com/project
|
|
406
123
|
[billing]: https://support.google.com/cloud/answer/6293499#enable-billing
|
|
407
124
|
[enable_api]: https://console.cloud.google.com/flows/enableapi?apiid=cloudprofiler.googleapis.com
|
|
408
|
-
[auth]: https://cloud.google.com/docs/authentication/
|
|
125
|
+
[auth]: https://cloud.google.com/docs/authentication/external/set-up-adc-local
|
package/build/src/config.js
CHANGED
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
// limitations under the License.
|
|
15
15
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
16
|
exports.defaultConfig = void 0;
|
|
17
|
-
const
|
|
17
|
+
const ms = require("ms");
|
|
18
18
|
// Default values for configuration for a profiler.
|
|
19
19
|
exports.defaultConfig = {
|
|
20
20
|
logLevel: 2,
|
|
@@ -25,8 +25,8 @@ exports.defaultConfig = {
|
|
|
25
25
|
heapIntervalBytes: 512 * 1024,
|
|
26
26
|
heapMaxStackDepth: 64,
|
|
27
27
|
ignoreHeapSamplesPath: '@google-cloud/profiler',
|
|
28
|
-
initialBackoffMillis: 60 * 1000,
|
|
29
|
-
backoffCapMillis: (
|
|
28
|
+
initialBackoffMillis: 60 * 1000,
|
|
29
|
+
backoffCapMillis: ms('1h'),
|
|
30
30
|
backoffMultiplier: 1.3,
|
|
31
31
|
apiEndpoint: 'cloudprofiler.googleapis.com',
|
|
32
32
|
// This is the largest duration for setTimeout which does not cause it to
|
package/build/src/config.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"config.js","sourceRoot":"","sources":["../../src/config.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;;;AAGjC,
|
|
1
|
+
{"version":3,"file":"config.js","sourceRoot":"","sources":["../../src/config.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;;;AAGjC,yBAAyB;AAiKzB,mDAAmD;AACtC,QAAA,aAAa,GAAG;IAC3B,QAAQ,EAAE,CAAC;IACX,cAAc,EAAE,EAAE;IAClB,WAAW,EAAE,KAAK;IAClB,WAAW,EAAE,KAAK;IAClB,kBAAkB,EAAE,IAAI;IACxB,iBAAiB,EAAE,GAAG,GAAG,IAAI;IAC7B,iBAAiB,EAAE,EAAE;IACrB,qBAAqB,EAAE,wBAAwB;IAC/C,oBAAoB,EAAE,EAAE,GAAG,IAAI;IAC/B,gBAAgB,EAAE,EAAE,CAAC,IAAI,CAAE;IAC3B,iBAAiB,EAAE,GAAG;IACtB,WAAW,EAAE,8BAA8B;IAE3C,yEAAyE;IACzE,mBAAmB;IACnB,kGAAkG;IAClG,sBAAsB,EAAE,UAAU;IAElC,0BAA0B,EAAE,IAAI;IAChC,oBAAoB,EAAE,KAAK;IAC3B,uBAAuB,EAAE,IAAI;IAC7B,mBAAmB,EAAE,CAAC,OAAO,CAAC,GAAG,EAAE,CAAC;IACpC,iBAAiB,EAAE,KAAK;CACzB,CAAC"}
|
package/build/src/index.js
CHANGED
|
@@ -13,10 +13,7 @@
|
|
|
13
13
|
// See the License for the specific language governing permissions and
|
|
14
14
|
// limitations under the License.
|
|
15
15
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
-
exports.nodeVersionOkay =
|
|
17
|
-
exports.createProfiler = createProfiler;
|
|
18
|
-
exports.start = start;
|
|
19
|
-
exports.startLocal = startLocal;
|
|
16
|
+
exports.startLocal = exports.start = exports.createProfiler = exports.nodeVersionOkay = void 0;
|
|
20
17
|
const delay_1 = require("delay");
|
|
21
18
|
const extend = require("extend");
|
|
22
19
|
const fs = require("fs");
|
|
@@ -136,6 +133,7 @@ function nodeVersionOkay(version) {
|
|
|
136
133
|
version = semver.coerce(version) || version;
|
|
137
134
|
return semver.satisfies(version, pjson.engines.node);
|
|
138
135
|
}
|
|
136
|
+
exports.nodeVersionOkay = nodeVersionOkay;
|
|
139
137
|
/**
|
|
140
138
|
* Initializes the config, and starts heap profiler if the heap profiler is
|
|
141
139
|
* needed. Returns a profiler if creation is successful. Otherwise, returns
|
|
@@ -165,6 +163,7 @@ async function createProfiler(config = {}) {
|
|
|
165
163
|
}
|
|
166
164
|
return new profiler_1.Profiler(profilerConfig);
|
|
167
165
|
}
|
|
166
|
+
exports.createProfiler = createProfiler;
|
|
168
167
|
/**
|
|
169
168
|
* Starts the profiling agent and returns a promise.
|
|
170
169
|
* If any error is encountered when configuring the profiler the promise will
|
|
@@ -183,6 +182,7 @@ async function start(config = {}) {
|
|
|
183
182
|
const profiler = await createProfiler(config);
|
|
184
183
|
profiler.start();
|
|
185
184
|
}
|
|
185
|
+
exports.start = start;
|
|
186
186
|
/**
|
|
187
187
|
* For debugging purposes. Collects profiles and discards the collected
|
|
188
188
|
* profiles.
|
|
@@ -240,6 +240,7 @@ async function startLocal(config = {}) {
|
|
|
240
240
|
}
|
|
241
241
|
}, profiler.config.localProfilingPeriodMillis);
|
|
242
242
|
}
|
|
243
|
+
exports.startLocal = startLocal;
|
|
243
244
|
// If the module was --require'd from the command line, start the agent.
|
|
244
245
|
if (module.parent && module.parent.id === 'internal/preload') {
|
|
245
246
|
start();
|
package/build/src/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.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
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.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,iCAA0B;AAC1B,iCAAiC;AACjC,yBAAyB;AACzB,4CAA4C;AAC5C,iCAA2C;AAC3C,iCAAiC;AAEjC,qCAA4E;AAC5E,qCAAsC;AACtC,yCAAoC;AAEpC,8DAA8D;AAC9D,MAAM,KAAK,GAAG,OAAO,CAAC,oBAAoB,CAAC,CAAC;AAC5C,MAAM,YAAY,GAAG,yCAAyC,CAAC;AAE/D,SAAS,UAAU,CACjB,MAAc;IAEd,OAAO,CACL,MAAM,CAAC,cAAc,KAAK,SAAS;QACnC,OAAO,MAAM,CAAC,cAAc,CAAC,OAAO,KAAK,QAAQ,CAClD,CAAC;AACJ,CAAC;AAED,SAAS,YAAY,CAAC,MAAc;IAClC,OAAO,OAAO,MAAM,CAAC,SAAS,KAAK,Q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MAAM;aACpB,CAAC,CAAC;YACH,gBAAgB,EAAE,CAAC;SACpB;QACD,MAAM,IAAA,eAAK,EAAC,QAAQ,CAAC,MAAM,CAAC,0BAA0B,GAAG,CAAC,CAAC,CAAC;QAC5D,IAAI,CAAC,MAAM,CAAC,WAAW,EAAE;YACvB,MAAM,QAAQ,CAAC,OAAO,CAAC;gBACrB,IAAI,EAAE,cAAc,GAAG,IAAI,IAAI,EAAE;gBACjC,WAAW,EAAE,MAAM;gBACnB,QAAQ,EAAE,QAAQ,CAAC,MAAM,CAAC,uBAAuB,CAAC,QAAQ,EAAE,GAAG,IAAI;aACpE,CAAC,CAAC;YACH,gBAAgB,EAAE,CAAC;SACpB;IACH,CAAC,EAAE,QAAQ,CAAC,MAAM,CAAC,0BAA0B,CAAC,CAAC;AACjD,CAAC;AAzDD,gCAyDC;AAED,wEAAwE;AACxE,IAAI,MAAM,CAAC,MAAM,IAAI,MAAM,CAAC,MAAM,CAAC,EAAE,KAAK,kBAAkB,EAAE;IAC5D,KAAK,EAAE,CAAC;CACT"}
|
package/build/src/logger.js
CHANGED
|
@@ -13,8 +13,7 @@
|
|
|
13
13
|
// See the License for the specific language governing permissions and
|
|
14
14
|
// limitations under the License.
|
|
15
15
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
-
exports.Logger = void 0;
|
|
17
|
-
exports.createLogger = createLogger;
|
|
16
|
+
exports.createLogger = exports.Logger = void 0;
|
|
18
17
|
/* eslint-disable @typescript-eslint/no-explicit-any */
|
|
19
18
|
const config_1 = require("./config");
|
|
20
19
|
const logging_min_1 = require("@google-cloud/logging-min");
|
|
@@ -78,4 +77,5 @@ function createLogger(level) {
|
|
|
78
77
|
}
|
|
79
78
|
return new Logger(level);
|
|
80
79
|
}
|
|
80
|
+
exports.createLogger = createLogger;
|
|
81
81
|
//# sourceMappingURL=logger.js.map
|
package/build/src/logger.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"logger.js","sourceRoot":"","sources":["../../src/logger.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;;;
|
|
1
|
+
{"version":3,"file":"logger.js","sourceRoot":"","sources":["../../src/logger.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,uDAAuD;AAEvD,qCAAuC;AACvC,2DAA2D;AAE3D,MAAM,OAAO,GAAG,IAAI,qBAAO,EAAE,CAAC;AAE9B,qDAAqD;AACrD,sDAAsD;AACtD,MAAM,CAAC,SAAS,EAAE,SAAS,CAAC,GAAG,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;AAEtC,8DAA8D;AAC9D,MAAM,KAAK,GAAG,OAAO,CAAC,oBAAoB,CAAC,CAAC;AAE5C,MAAa,MAAM;IAIjB,YAAqB,KAAc;QAAd,UAAK,GAAL,KAAK,CAAS;QACjC,IAAI,KAAK,KAAK,SAAS,EAAE;YACvB,KAAK,GAAG,sBAAa,CAAC,QAAQ,CAAC;SAChC;QACD,IAAI,KAAK,GAAG,SAAS,EAAE;YACrB,KAAK,GAAG,SAAS,CAAC;SACnB;aAAM,IAAI,KAAK,GAAG,SAAS,EAAE;YAC5B,KAAK,GAAG,SAAS,CAAC;SACnB;QACD,IAAI,CAAC,iBAAiB,GAAG,KAAK,CAAC;QAC/B,IAAI,CAAC,GAAG,GAAG,OAAO,CAAC,OAAO,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC;IACzC,CAAC;IAED,KAAK,CAAC,GAAW;QACf,IAA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,OAAO,CAAC,KAAK,CAAC,oCAAoC,GAAG,EAAE,CAAC,CAAC;QAC3D,CAAC,CAAC,CAAC;QACH,OAAO,CAAC,mBAAmB,EAAE,CAAC,KAAK,CAAC,GAAG,CAAC,EAAE;YACxC,OAAO,CAAC,KAAK,CAAC,wCAAwC,GAAG,EAAE,CAAC,CAAC;QAC/D,CAAC,CAAC,CAAC;QAEH,cAAc,GAAG,IAAI,CAAC;KACvB;IAED,OAAO,IAAI,MAAM,CAAC,KAAK,CAAC,CAAC;AAC3B,CAAC;AAbD,oCAaC"}
|
package/build/src/profiler.d.ts
CHANGED
|
@@ -33,13 +33,6 @@ export interface RequestProfile {
|
|
|
33
33
|
instance?: string;
|
|
34
34
|
};
|
|
35
35
|
}
|
|
36
|
-
/**
|
|
37
|
-
* @return if the backoff duration can be parsed, then the backoff duration in
|
|
38
|
-
* ms, otherwise undefined.
|
|
39
|
-
*
|
|
40
|
-
* Public for testing.
|
|
41
|
-
*/
|
|
42
|
-
export declare function parseBackoffDuration(backoffMessage: string): number | undefined;
|
|
43
36
|
/**
|
|
44
37
|
* Error constructed from HTTP server response which indicates backoff.
|
|
45
38
|
*/
|
package/build/src/profiler.js
CHANGED
|
@@ -14,7 +14,6 @@
|
|
|
14
14
|
// limitations under the License.
|
|
15
15
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
16
|
exports.Profiler = exports.Retryer = exports.BackoffResponseError = void 0;
|
|
17
|
-
exports.parseBackoffDuration = parseBackoffDuration;
|
|
18
17
|
const common_1 = require("@google-cloud/common");
|
|
19
18
|
const pprof_1 = require("pprof");
|
|
20
19
|
const profile_1 = require("pprof/proto/profile");
|
|
@@ -22,7 +21,7 @@ const msToStr = require("pretty-ms");
|
|
|
22
21
|
const util_1 = require("util");
|
|
23
22
|
const zlib = require("zlib");
|
|
24
23
|
const logger_1 = require("./logger");
|
|
25
|
-
const
|
|
24
|
+
const ms = require("ms");
|
|
26
25
|
// eslint-disable-next-line @typescript-eslint/no-var-requires
|
|
27
26
|
const pjson = require('../../package.json');
|
|
28
27
|
const SCOPE = 'https://www.googleapis.com/auth/monitoring.write';
|
|
@@ -68,7 +67,12 @@ function getServerResponseBackoff(body) {
|
|
|
68
67
|
if (typeof item === 'object' &&
|
|
69
68
|
item.retryDelay &&
|
|
70
69
|
typeof item.retryDelay === 'string') {
|
|
71
|
-
|
|
70
|
+
// item is a RetryInfo
|
|
71
|
+
// https://github.com/googleapis/googleapis/blob/4ec607bd375cddbec6d28bc1931eab7da221e4bb/google/rpc/error_details.proto#L92
|
|
72
|
+
// and the ProtoJSON encoding of the duration will be a string of seconds with "s"
|
|
73
|
+
// suffix https://protobuf.dev/programming-guides/json
|
|
74
|
+
const retryDelay = item.retryDelay;
|
|
75
|
+
const backoffMillis = ms(retryDelay);
|
|
72
76
|
if (backoffMillis > 0) {
|
|
73
77
|
return backoffMillis;
|
|
74
78
|
}
|
|
@@ -77,26 +81,6 @@ function getServerResponseBackoff(body) {
|
|
|
77
81
|
}
|
|
78
82
|
return undefined;
|
|
79
83
|
}
|
|
80
|
-
/**
|
|
81
|
-
* @return if the backoff duration can be parsed, then the backoff duration in
|
|
82
|
-
* ms, otherwise undefined.
|
|
83
|
-
*
|
|
84
|
-
* Public for testing.
|
|
85
|
-
*/
|
|
86
|
-
function parseBackoffDuration(backoffMessage) {
|
|
87
|
-
const backoffMessageRegex = /action throttled, backoff for ((?:([0-9]+)h)?(?:([0-9]+)m)?([0-9.]+)s)$/;
|
|
88
|
-
const [, duration] = backoffMessageRegex.exec(backoffMessage) || [
|
|
89
|
-
undefined,
|
|
90
|
-
undefined,
|
|
91
|
-
];
|
|
92
|
-
if (duration) {
|
|
93
|
-
const backoffMillis = (0, parse_duration_1.default)(duration);
|
|
94
|
-
if (backoffMillis > 0) {
|
|
95
|
-
return backoffMillis;
|
|
96
|
-
}
|
|
97
|
-
}
|
|
98
|
-
return undefined;
|
|
99
|
-
}
|
|
100
84
|
/**
|
|
101
85
|
* @return true if an deployment is a Deployment and false otherwise.
|
|
102
86
|
*/
|
|
@@ -343,7 +327,7 @@ class Profiler extends common_1.ServiceObject {
|
|
|
343
327
|
// Default timeout for for a request is 1 minute, but request to create
|
|
344
328
|
// profile is designed to hang until it is time to collect a profile
|
|
345
329
|
// (up to one hour).
|
|
346
|
-
timeout: (
|
|
330
|
+
timeout: ms('1h'),
|
|
347
331
|
};
|
|
348
332
|
this.logger.debug('Attempting to create profile.');
|
|
349
333
|
return new Promise((resolve, reject) => {
|
|
@@ -432,7 +416,7 @@ class Profiler extends common_1.ServiceObject {
|
|
|
432
416
|
if (prof.duration === undefined) {
|
|
433
417
|
throw Error('Cannot collect time profile, duration is undefined.');
|
|
434
418
|
}
|
|
435
|
-
const durationMillis = (
|
|
419
|
+
const durationMillis = ms(prof.duration);
|
|
436
420
|
if (!durationMillis) {
|
|
437
421
|
throw Error(`Cannot collect time profile, duration "${prof.duration}" cannot` +
|
|
438
422
|
' be parsed.');
|
|
@@ -1 +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;;;AAqHjC,oDAgBC;AAnID,iDAM8B;AAC9B,iCAA+E;AAC/E,iDAA8C;AAC9C,qCAAqC;AACrC,+BAA+B;AAC/B,6BAA6B;AAI7B,qCAAsC;AAEtC,mDAA2C;AAC3C,8DAA8D;AAC9D,MAAM,KAAK,GAAG,OAAO,CAAC,oBAAoB,CAAC,CAAC;AAC5C,MAAM,KAAK,GAAG,kDAAkD,CAAC;AACjE,MAAM,IAAI,GAAG,IAAA,gBAAS,EAAC,IAAI,CAAC,IAAI,CAAC,CAAC;AAElC,IAAK,YAGJ;AAHD,WAAK,YAAY;IACf,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,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"}
|
package/package.json
CHANGED
|
@@ -1,13 +1,17 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@google-cloud/profiler",
|
|
3
|
-
"version": "6.0.
|
|
3
|
+
"version": "6.0.4",
|
|
4
4
|
"description": "Adds support for Cloud Profiler to Node.js applications",
|
|
5
|
-
"repository":
|
|
5
|
+
"repository": {
|
|
6
|
+
"type": "git",
|
|
7
|
+
"directory": "handwritten/cloud-profiler",
|
|
8
|
+
"url": "https://github.com/googleapis/google-cloud-node.git"
|
|
9
|
+
},
|
|
6
10
|
"main": "build/src/index.js",
|
|
7
11
|
"types": "build/src/index.d.ts",
|
|
8
12
|
"scripts": {
|
|
9
|
-
"test": "
|
|
10
|
-
"system-test": "
|
|
13
|
+
"test": "echo 'skipping tests for time being'",
|
|
14
|
+
"system-test": "echo 'skipping tests for time being'",
|
|
11
15
|
"samples-test": "echo 'no sample tests'",
|
|
12
16
|
"clean": "gts clean",
|
|
13
17
|
"compile": "tsc -p .",
|
|
@@ -18,7 +22,7 @@
|
|
|
18
22
|
"prepare": "npm run compile",
|
|
19
23
|
"pretest": "npm run compile",
|
|
20
24
|
"license-check": "jsgl --local .",
|
|
21
|
-
"docs-test": "
|
|
25
|
+
"docs-test": "echo 'skipping tests for time being'",
|
|
22
26
|
"predocs-test": "npm run docs",
|
|
23
27
|
"precompile": "gts clean"
|
|
24
28
|
},
|
|
@@ -29,13 +33,14 @@
|
|
|
29
33
|
"dependencies": {
|
|
30
34
|
"@google-cloud/common": "^5.0.0",
|
|
31
35
|
"@google-cloud/logging-min": "^11.0.0",
|
|
36
|
+
"@google-cloud/promisify": "~4.0.0",
|
|
32
37
|
"@types/console-log-level": "^1.4.0",
|
|
33
38
|
"@types/semver": "^7.0.0",
|
|
34
39
|
"console-log-level": "^1.4.0",
|
|
35
40
|
"delay": "^5.0.0",
|
|
36
41
|
"extend": "^3.0.2",
|
|
37
42
|
"gcp-metadata": "^6.0.0",
|
|
38
|
-
"
|
|
43
|
+
"ms": "^2.1.3",
|
|
39
44
|
"pprof": "4.0.0",
|
|
40
45
|
"pretty-ms": "^7.0.0",
|
|
41
46
|
"protobufjs": "~7.4.0",
|
|
@@ -46,8 +51,9 @@
|
|
|
46
51
|
"@types/extend": "^3.0.0",
|
|
47
52
|
"@types/long": "^5.0.0",
|
|
48
53
|
"@types/mocha": "^9.0.0",
|
|
54
|
+
"@types/ms": "^2.1.0",
|
|
49
55
|
"@types/nock": "^11.0.0",
|
|
50
|
-
"@types/node": "^20.
|
|
56
|
+
"@types/node": "^20.0.0",
|
|
51
57
|
"@types/pretty-ms": "^5.0.0",
|
|
52
58
|
"@types/sinon": "^17.0.0",
|
|
53
59
|
"@types/tmp": "0.2.6",
|
|
@@ -59,12 +65,13 @@
|
|
|
59
65
|
"jsdoc-fresh": "^3.0.0",
|
|
60
66
|
"jsdoc-region-tag": "^3.0.0",
|
|
61
67
|
"linkinator": "^5.0.0",
|
|
68
|
+
"long": "^5.3.2",
|
|
62
69
|
"mocha": "^9.2.2",
|
|
63
70
|
"nock": "^13.0.0",
|
|
64
71
|
"sinon": "^18.0.0",
|
|
65
72
|
"source-map": "^0.7.0",
|
|
66
|
-
"tmp": "0.2.
|
|
67
|
-
"typescript": "
|
|
73
|
+
"tmp": "0.2.4",
|
|
74
|
+
"typescript": "5.1.6"
|
|
68
75
|
},
|
|
69
76
|
"files": [
|
|
70
77
|
"build/src",
|
|
@@ -78,5 +85,6 @@
|
|
|
78
85
|
},
|
|
79
86
|
"engines": {
|
|
80
87
|
"node": ">=14.0.0"
|
|
81
|
-
}
|
|
88
|
+
},
|
|
89
|
+
"homepage": "https://github.com/googleapis/google-cloud-node/tree/main/handwritten/cloud-profiler"
|
|
82
90
|
}
|
package/CHANGELOG.md
DELETED
|
@@ -1,341 +0,0 @@
|
|
|
1
|
-
# Changelog
|
|
2
|
-
|
|
3
|
-
[npm history][1]
|
|
4
|
-
|
|
5
|
-
[1]: https://www.npmjs.com/package/@google-cloud/profiler?activeTab=versions
|
|
6
|
-
|
|
7
|
-
## [6.0.2](https://github.com/googleapis/cloud-profiler-nodejs/compare/v6.0.1...v6.0.2) (2024-09-11)
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
### Bug Fixes
|
|
11
|
-
|
|
12
|
-
* **deps:** Update dependency @google-cloud/logging-min to v11 ([#939](https://github.com/googleapis/cloud-profiler-nodejs/issues/939)) ([97ec3fb](https://github.com/googleapis/cloud-profiler-nodejs/commit/97ec3fbe9d254dc824b6df9eec6630b3acfd04c6))
|
|
13
|
-
* **deps:** Update dependency protobufjs to ~7.3.0 ([#928](https://github.com/googleapis/cloud-profiler-nodejs/issues/928)) ([89eb3be](https://github.com/googleapis/cloud-profiler-nodejs/commit/89eb3be3c19e8f607d5a7764c8849a0f602f47dc))
|
|
14
|
-
* **deps:** Update dependency protobufjs to ~7.4.0 ([#938](https://github.com/googleapis/cloud-profiler-nodejs/issues/938)) ([60b8264](https://github.com/googleapis/cloud-profiler-nodejs/commit/60b826405724d16c5173a1b9c6a852bd34222f4d))
|
|
15
|
-
|
|
16
|
-
## [6.0.1](https://github.com/googleapis/cloud-profiler-nodejs/compare/v6.0.0...v6.0.1) (2024-02-05)
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
### Bug Fixes
|
|
20
|
-
|
|
21
|
-
* **deps:** Update dependency pprof to v4 ([#917](https://github.com/googleapis/cloud-profiler-nodejs/issues/917)) ([2411b71](https://github.com/googleapis/cloud-profiler-nodejs/commit/2411b7140e30fe89d10004010c3395aa18fbb543))
|
|
22
|
-
* Lazily init logging ([#801](https://github.com/googleapis/cloud-profiler-nodejs/issues/801)) ([04853a9](https://github.com/googleapis/cloud-profiler-nodejs/commit/04853a96896b54694d6480c5263af7145ee129ea))
|
|
23
|
-
|
|
24
|
-
## [6.0.0](https://github.com/googleapis/cloud-profiler-nodejs/compare/v5.0.5...v6.0.0) (2023-08-15)
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
### ⚠ BREAKING CHANGES
|
|
28
|
-
|
|
29
|
-
* upgrade to Node 14 ([#891](https://github.com/googleapis/cloud-profiler-nodejs/issues/891))
|
|
30
|
-
|
|
31
|
-
### Miscellaneous Chores
|
|
32
|
-
|
|
33
|
-
* Upgrade to Node 14 ([#891](https://github.com/googleapis/cloud-profiler-nodejs/issues/891)) ([66b7f4e](https://github.com/googleapis/cloud-profiler-nodejs/commit/66b7f4e4beeaf09e7bb1107368997bfafd2a4679))
|
|
34
|
-
|
|
35
|
-
## [5.0.5](https://github.com/googleapis/cloud-profiler-nodejs/compare/v5.0.4...v5.0.5) (2023-07-24)
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
### Bug Fixes
|
|
39
|
-
|
|
40
|
-
* **deps:** Upgrade pprof to v3.2.1 [security] ([#885](https://github.com/googleapis/cloud-profiler-nodejs/issues/885)) ([c140fe5](https://github.com/googleapis/cloud-profiler-nodejs/commit/c140fe5bca0f07ce775fd0f10b0aae1537962a1b))
|
|
41
|
-
|
|
42
|
-
## [5.0.4](https://github.com/googleapis/cloud-profiler-nodejs/compare/v5.0.3...v5.0.4) (2023-02-09)
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
### Bug Fixes
|
|
46
|
-
|
|
47
|
-
* **deps:** Update dependency protobufjs to ~7.2.0 ([#868](https://github.com/googleapis/cloud-profiler-nodejs/issues/868)) ([e414a04](https://github.com/googleapis/cloud-profiler-nodejs/commit/e414a043e12d9d46b24fecdb761c434a3a225699))
|
|
48
|
-
* Update go installation method ([#862](https://github.com/googleapis/cloud-profiler-nodejs/issues/862)) ([07f69a7](https://github.com/googleapis/cloud-profiler-nodejs/commit/07f69a7ed35ca1c438a63f4d2c7ea71e7f2b9882))
|
|
49
|
-
|
|
50
|
-
## [5.0.3](https://github.com/googleapis/cloud-profiler-nodejs/compare/v5.0.2...v5.0.3) (2022-09-09)
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
### Bug Fixes
|
|
54
|
-
|
|
55
|
-
* **deps:** Update dependency protobufjs to ~7.1.0 ([#854](https://github.com/googleapis/cloud-profiler-nodejs/issues/854)) ([e8e725d](https://github.com/googleapis/cloud-profiler-nodejs/commit/e8e725d74d7e9578ac0fac0fb94774e833ae1979))
|
|
56
|
-
* Remove pip install statements ([#1546](https://github.com/googleapis/cloud-profiler-nodejs/issues/1546)) ([#852](https://github.com/googleapis/cloud-profiler-nodejs/issues/852)) ([85ddb0f](https://github.com/googleapis/cloud-profiler-nodejs/commit/85ddb0f07cb40dab1e6284b80d5a921a596b2b9f))
|
|
57
|
-
|
|
58
|
-
## [5.0.2](https://github.com/googleapis/cloud-profiler-nodejs/compare/v5.0.1...v5.0.2) (2022-07-25)
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
### Bug Fixes
|
|
62
|
-
|
|
63
|
-
* **deps:** update dependency protobufjs to v7 ([#849](https://github.com/googleapis/cloud-profiler-nodejs/issues/849)) ([5536eac](https://github.com/googleapis/cloud-profiler-nodejs/commit/5536eac0ac661d54fab58a236d561b259b2fe04f))
|
|
64
|
-
|
|
65
|
-
## [5.0.1](https://github.com/googleapis/cloud-profiler-nodejs/compare/v5.0.0...v5.0.1) (2022-07-08)
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
### Bug Fixes
|
|
69
|
-
|
|
70
|
-
* fix build so it includes expected files (and modify test to catch this) ([6d9a5ca](https://github.com/googleapis/cloud-profiler-nodejs/commit/6d9a5caa276a7d41f6f3b0e9da8d576e261f3f3f))
|
|
71
|
-
|
|
72
|
-
## [5.0.0](https://github.com/googleapis/cloud-profiler-nodejs/compare/v4.2.0...v5.0.0) (2022-06-20)
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
### ⚠ BREAKING CHANGES
|
|
76
|
-
|
|
77
|
-
* update library to use Node 12 (#835)
|
|
78
|
-
|
|
79
|
-
### Bug Fixes
|
|
80
|
-
|
|
81
|
-
* **deps:** update dependency @google-cloud/common to v4 ([#843](https://github.com/googleapis/cloud-profiler-nodejs/issues/843)) ([1af6b0f](https://github.com/googleapis/cloud-profiler-nodejs/commit/1af6b0f18aec665b042a27ea90158b99d7435d4e))
|
|
82
|
-
* **deps:** update dependency @google-cloud/logging-min to v10 ([#838](https://github.com/googleapis/cloud-profiler-nodejs/issues/838)) ([1120298](https://github.com/googleapis/cloud-profiler-nodejs/commit/11202986b7d4501637e7c30c5e9787789e98ccba))
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
### Build System
|
|
86
|
-
|
|
87
|
-
* update library to use Node 12 ([#835](https://github.com/googleapis/cloud-profiler-nodejs/issues/835)) ([07221ef](https://github.com/googleapis/cloud-profiler-nodejs/commit/07221ef0503c25311834a50b987b70d51393420c))
|
|
88
|
-
|
|
89
|
-
## [4.2.0](https://github.com/googleapis/cloud-profiler-nodejs/compare/v4.1.7...v4.2.0) (2022-05-13)
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
### Bug Fixes
|
|
93
|
-
|
|
94
|
-
* initial module in golint presubmit check ([#818](https://github.com/googleapis/cloud-profiler-nodejs/issues/818)) ([df1f28a](https://github.com/googleapis/cloud-profiler-nodejs/commit/df1f28a6e0e74f9d5ee6751a203fe5610866b584))
|
|
95
|
-
* library should released as 4.2.0 ([#833](https://github.com/googleapis/cloud-profiler-nodejs/issues/833)) ([8d722aa](https://github.com/googleapis/cloud-profiler-nodejs/commit/8d722aa0e5a3f03ea729db0a4d98b2a8c7717bcf))
|
|
96
|
-
* relax service name requirements to allow starting with numbers ([#828](https://github.com/googleapis/cloud-profiler-nodejs/issues/828)) ([fe0f1cc](https://github.com/googleapis/cloud-profiler-nodejs/commit/fe0f1ccd14c2a091f1778142083f49813d724dcf))
|
|
97
|
-
|
|
98
|
-
### [4.1.7](https://www.github.com/googleapis/cloud-profiler-nodejs/compare/v4.1.6...v4.1.7) (2021-12-20)
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
### Bug Fixes
|
|
102
|
-
|
|
103
|
-
* remove certification expiration workaround ([#781](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/781)) ([44af460](https://www.github.com/googleapis/cloud-profiler-nodejs/commit/44af4604f0553ef917e48abf51fa3f52950ed6b7))
|
|
104
|
-
|
|
105
|
-
### [4.1.6](https://www.github.com/googleapis/cloud-profiler-nodejs/compare/v4.1.5...v4.1.6) (2021-12-20)
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
### Bug Fixes
|
|
109
|
-
|
|
110
|
-
* log to console using structured logging ([#780](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/780)) ([6b96e00](https://www.github.com/googleapis/cloud-profiler-nodejs/commit/6b96e007418bd6074c2bf9de64df0742e6a6d4ae))
|
|
111
|
-
|
|
112
|
-
### [4.1.5](https://www.github.com/googleapis/cloud-profiler-nodejs/compare/v4.1.4...v4.1.5) (2021-10-06)
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
### Bug Fixes
|
|
116
|
-
|
|
117
|
-
* workaround certificate expiration issue in integration tests ([#773](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/773)) ([9d4908b](https://www.github.com/googleapis/cloud-profiler-nodejs/commit/9d4908b7161e0aade0915d2d88a43b0a6bfc9791))
|
|
118
|
-
|
|
119
|
-
### [4.1.4](https://www.github.com/googleapis/cloud-profiler-nodejs/compare/v4.1.3...v4.1.4) (2021-09-14)
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
### Bug Fixes
|
|
123
|
-
|
|
124
|
-
* **build:** migrate to using main branch ([#760](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/760)) ([1649406](https://www.github.com/googleapis/cloud-profiler-nodejs/commit/164940698d7f4da0b2b6ea9e3b059e553fcfaa42))
|
|
125
|
-
|
|
126
|
-
### [4.1.3](https://www.github.com/googleapis/cloud-profiler-nodejs/compare/v4.1.2...v4.1.3) (2021-07-20)
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
### Bug Fixes
|
|
130
|
-
|
|
131
|
-
* **deps:** update dependency pprof to v3.2.0 ([#754](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/754)) ([fc48f9a](https://www.github.com/googleapis/cloud-profiler-nodejs/commit/fc48f9aee74a3638d98086e0b404e299ae31b592))
|
|
132
|
-
|
|
133
|
-
### [4.1.2](https://www.github.com/googleapis/cloud-profiler-nodejs/compare/v4.1.1...v4.1.2) (2021-05-05)
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
### Bug Fixes
|
|
137
|
-
|
|
138
|
-
* **deps:** update dependency pprof to v3.1.0 ([#731](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/731)) ([ba96e49](https://www.github.com/googleapis/cloud-profiler-nodejs/commit/ba96e49a2d254d713d55f16bedbf6a5268500801))
|
|
139
|
-
* **deps:** update dependency protobufjs to ~6.11.0 ([#733](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/733)) ([33abbeb](https://www.github.com/googleapis/cloud-profiler-nodejs/commit/33abbebe1e6424658a66cdb728b93875d4edadd3))
|
|
140
|
-
|
|
141
|
-
### [4.1.1](https://www.github.com/googleapis/cloud-profiler-nodejs/compare/v4.1.0...v4.1.1) (2021-03-16)
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
### Bug Fixes
|
|
145
|
-
|
|
146
|
-
* **deps:** update dependency delay to v5 ([#722](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/722)) ([98d43e1](https://www.github.com/googleapis/cloud-profiler-nodejs/commit/98d43e12b2d19f7d8b70618b6d3ec5de6e8d702c))
|
|
147
|
-
* **deps:** update dependency parse-duration to v1 ([#725](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/725)) ([fcd1239](https://www.github.com/googleapis/cloud-profiler-nodejs/commit/fcd12391782ad9363cffae0c3b507512fc8dfbc8))
|
|
148
|
-
|
|
149
|
-
## [4.1.0](https://www.github.com/googleapis/cloud-profiler-nodejs/compare/v4.0.3...v4.1.0) (2020-11-02)
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
### Features
|
|
153
|
-
|
|
154
|
-
* add support for Node 14 ([#709](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/709)) ([3b8f4ad](https://www.github.com/googleapis/cloud-profiler-nodejs/commit/3b8f4adbb069c163864ba4e61e7980e78c057713))
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
### Bug Fixes
|
|
158
|
-
|
|
159
|
-
* Update engines to prevent agent from being used with versions of Node.js where v8 profilers have memory leaks ([#699](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/699)) ([160d1f6](https://www.github.com/googleapis/cloud-profiler-nodejs/commit/160d1f68c657f6ce18b8cea921470d1b4482619f))
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
### Reverts
|
|
163
|
-
|
|
164
|
-
* Revert "fix: Update engines to prevent agent from getting used when it will cause memory leak." (#706) ([9141c2f](https://www.github.com/googleapis/cloud-profiler-nodejs/commit/9141c2fc9373a8a8b26a577165a23a21835db779)), closes [#706](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/706) [#699](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/699)
|
|
165
|
-
|
|
166
|
-
### [4.0.3](https://www.github.com/googleapis/cloud-profiler-nodejs/compare/v4.0.2...v4.0.3) (2020-09-12)
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
### Bug Fixes
|
|
170
|
-
|
|
171
|
-
* move gitattributes files to node templates ([#679](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/679)) ([521e418](https://www.github.com/googleapis/cloud-profiler-nodejs/commit/521e4180f825299907ad374412d81d65bb674596))
|
|
172
|
-
* **deps:** update dependency parse-duration to 0.4.4 ([#668](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/668)) ([2757231](https://www.github.com/googleapis/cloud-profiler-nodejs/commit/2757231e07492bc38bf25fe3add1274b36d2bdca))
|
|
173
|
-
|
|
174
|
-
### [4.0.2](https://www.github.com/googleapis/cloud-profiler-nodejs/compare/v4.0.1...v4.0.2) (2020-07-14)
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
### Bug Fixes
|
|
178
|
-
|
|
179
|
-
* **deps:** update dependency protobufjs to ~6.10.0 ([#665](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/665)) ([dc4ed5c](https://www.github.com/googleapis/cloud-profiler-nodejs/commit/dc4ed5c57e675b0a87e193b0ba012d5d22b85951))
|
|
180
|
-
|
|
181
|
-
### [4.0.1](https://www.github.com/googleapis/cloud-profiler-nodejs/compare/v4.0.0...v4.0.1) (2020-07-09)
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
### Bug Fixes
|
|
185
|
-
|
|
186
|
-
* **deps:** update dependency pretty-ms to v7 ([#642](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/642)) ([f69c7a7](https://www.github.com/googleapis/cloud-profiler-nodejs/commit/f69c7a73b17c150c2b523412e430b5d1ac03e12a))
|
|
187
|
-
* **deps:** update dependency protobufjs to ~6.9.0 ([#634](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/634)) ([a90149c](https://www.github.com/googleapis/cloud-profiler-nodejs/commit/a90149c4f91630d75bb41fab145713637736d21c))
|
|
188
|
-
* malformed tsconfig causing broken tests [#640](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/640) ([#647](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/647)) ([09c19c8](https://www.github.com/googleapis/cloud-profiler-nodejs/commit/09c19c88a0ca137b7970c386730b145b66b77ec3))
|
|
189
|
-
* **deps:** update dependency teeny-request to v7 ([#652](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/652)) ([b46eb4f](https://www.github.com/googleapis/cloud-profiler-nodejs/commit/b46eb4f2552871f405579100e4e916dbde5c60d8))
|
|
190
|
-
* typeo in nodejs .gitattribute ([#661](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/661)) ([92f46ac](https://www.github.com/googleapis/cloud-profiler-nodejs/commit/92f46ac22a510c7bab05549b83779dd4f60096b7))
|
|
191
|
-
|
|
192
|
-
## [4.0.0](https://www.github.com/googleapis/cloud-profiler-nodejs/compare/v3.0.1...v4.0.0) (2020-04-17)
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
### ⚠ BREAKING CHANGES
|
|
196
|
-
|
|
197
|
-
* require node.js 10.x and up (#623)
|
|
198
|
-
* `start({...}) ` now throws an error when the profiling agent cannot be set up because required fields are not set in the config and cannot be determined based on metadata or environment variables.
|
|
199
|
-
|
|
200
|
-
### Features
|
|
201
|
-
|
|
202
|
-
* add support for Node 12 ([#580](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/580)) ([e7cb85e](https://www.github.com/googleapis/cloud-profiler-nodejs/commit/e7cb85efafb72f3f50acb48cafcc99e00cdd4616))
|
|
203
|
-
* package is now GA ([#627](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/627)) ([1327ece](https://www.github.com/googleapis/cloud-profiler-nodejs/commit/1327ece67da31c2fc5ab1e20f6481cfa8d207e63))
|
|
204
|
-
* require the project ID to be set before starting the profiling agent ([#516](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/516)) ([5b46b66](https://www.github.com/googleapis/cloud-profiler-nodejs/commit/5b46b66db3354bff611e2b34d51d40fc4e4befa5))
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
### Bug Fixes
|
|
208
|
-
|
|
209
|
-
* **deps:** TypeScript 3.7.0 causes breaking change in typings ([#564](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/564)) ([3ac08e5](https://www.github.com/googleapis/cloud-profiler-nodejs/commit/3ac08e52a8f9dbb87aaa70324c2f5bc69f805b7c))
|
|
210
|
-
* apache license URL ([#468](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/468)) ([#618](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/618)) ([1ae39be](https://www.github.com/googleapis/cloud-profiler-nodejs/commit/1ae39bef02389451ecf5b120770c6b6c914e96b8))
|
|
211
|
-
* **deps:** update dependency @google-cloud/common to v3 ([#613](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/613)) ([356dfa6](https://www.github.com/googleapis/cloud-profiler-nodejs/commit/356dfa6d461be219d9937c3ca1430b6b0891bee1))
|
|
212
|
-
* **deps:** update dependency @types/semver to v7 ([#587](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/587)) ([1400fda](https://www.github.com/googleapis/cloud-profiler-nodejs/commit/1400fda2018331ceb41df9434f307b8046fdde89))
|
|
213
|
-
* **deps:** update dependency gcp-metadata to v4 ([#609](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/609)) ([66875dd](https://www.github.com/googleapis/cloud-profiler-nodejs/commit/66875dd259adcab7e18068bee1d76afa7dc641e9))
|
|
214
|
-
* **deps:** update dependency pprof to v1.3.0 ([#595](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/595)) ([7ba1423](https://www.github.com/googleapis/cloud-profiler-nodejs/commit/7ba14239d5096811c30148fa1f405765cc13f0d2))
|
|
215
|
-
* **deps:** update dependency pprof to v2 ([#619](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/619)) ([37c7655](https://www.github.com/googleapis/cloud-profiler-nodejs/commit/37c7655b227676af7a400e379d7b172f41f2592e))
|
|
216
|
-
* **deps:** update dependency pretty-ms to v6 ([#596](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/596)) ([bed6c20](https://www.github.com/googleapis/cloud-profiler-nodejs/commit/bed6c2007bd7224b827c3f8dcf8369c4d9b8ba8c))
|
|
217
|
-
* **deps:** update dependency semver to v7 ([#567](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/567)) ([b6f80f6](https://www.github.com/googleapis/cloud-profiler-nodejs/commit/b6f80f6819e6fc42b767ecc17594a933e4ff8316))
|
|
218
|
-
* **docs:** snippets are now replaced in jsdoc comments ([#560](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/560)) ([07164f3](https://www.github.com/googleapis/cloud-profiler-nodejs/commit/07164f372913255a0b84754668ea2216cc2a6944))
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
### Build System
|
|
222
|
-
|
|
223
|
-
* require node.js 10.x and up ([#623](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/623)) ([90d20bb](https://www.github.com/googleapis/cloud-profiler-nodejs/commit/90d20bb566ed54237074af85dedb249653a06657))
|
|
224
|
-
|
|
225
|
-
### [3.0.1](https://www.github.com/googleapis/cloud-profiler-nodejs/compare/v3.0.0...v3.0.1) (2019-10-30)
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
### Bug Fixes
|
|
229
|
-
|
|
230
|
-
* remove @google-cloud/common retries for CreateProfile and UpdateProfile requests ([#555](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/555)) ([09ef74d](https://www.github.com/googleapis/cloud-profiler-nodejs/commit/09ef74d9a9a84d4c3a04edd9f93013cf8c56425b))
|
|
231
|
-
* **deps:** update dependency pprof to v1.2.0 ([#557](https://www.github.com/googleapis/cloud-profiler-nodejs/issues/557)) ([664bf0e](https://www.github.com/googleapis/cloud-profiler-nodejs/commit/664bf0e948cfb898702a2c4198e8d30f0699862c))
|
|
232
|
-
|
|
233
|
-
## v3.0.0
|
|
234
|
-
|
|
235
|
-
09-17-2019 10:42 PDT
|
|
236
|
-
|
|
237
|
-
### New Features
|
|
238
|
-
- feat(breaking!): support API endpoint override ([#509](https://github.com/googleapis/cloud-profiler-nodejs/pull/509))
|
|
239
|
-
- chore: message to log agent version should be consistent with other agents ([#531](https://github.com/googleapis/cloud-profiler-nodejs/pull/531))
|
|
240
|
-
- chore: log the agent's version on start-up ([#530](https://github.com/googleapis/cloud-profiler-nodejs/pull/530))
|
|
241
|
-
- chore: log the agent's version on start-up ([#530](https://github.com/googleapis/cloud-profiler-nodejs/pull/530))
|
|
242
|
-
|
|
243
|
-
### Dependencies
|
|
244
|
-
- fix(deps): update dependency gcp-metadata to v3 ([#541](https://github.com/googleapis/cloud-profiler-nodejs/pull/541))
|
|
245
|
-
- chore(deps): pin pprof module ([#539](https://github.com/googleapis/cloud-profiler-nodejs/pull/539))
|
|
246
|
-
- chore(deps): update dependency nock to v11 ([#538](https://github.com/googleapis/cloud-profiler-nodejs/pull/538))
|
|
247
|
-
- chore(deps): update dependency source-map to ^0.7.0 ([#537](https://github.com/googleapis/cloud-profiler-nodejs/pull/537))
|
|
248
|
-
- Revert "chore(deps): update dependency nock to v11 ([#534](https://github.com/googleapis/cloud-profiler-nodejs/pull/534))" ([#535](https://github.com/googleapis/cloud-profiler-nodejs/pull/535))
|
|
249
|
-
- chore(deps): update dependency nock to v11 ([#534](https://github.com/googleapis/cloud-profiler-nodejs/pull/534))
|
|
250
|
-
- chore(deps): update dependency typescript to ~3.6.0 ([#532](https://github.com/googleapis/cloud-profiler-nodejs/pull/532))
|
|
251
|
-
- fix(dep): update to be compatible with @google-cloud/common 2.1.X ([#529](https://github.com/googleapis/cloud-profiler-nodejs/pull/529))
|
|
252
|
-
- fix(deps): use the latest extend ([#523](https://github.com/googleapis/cloud-profiler-nodejs/pull/523))
|
|
253
|
-
|
|
254
|
-
### Documentation
|
|
255
|
-
- docs: use the jsdoc-fresh theme ([#519](https://github.com/googleapis/cloud-profiler-nodejs/pull/519))
|
|
256
|
-
- docs: note support for Node 12 in documentation ([#540](https://github.com/googleapis/cloud-profiler-nodejs/pull/540))
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
### Internal / Testing Changes
|
|
260
|
-
- build: add Node 12 remove Node 11 ([#520](https://github.com/googleapis/cloud-profiler-nodejs/pull/520))
|
|
261
|
-
- update .nycrc ignore rules ([#536](https://github.com/googleapis/cloud-profiler-nodejs/pull/536))
|
|
262
|
-
- chore: confirm zone is set in e2e test ([#518](https://github.com/googleapis/cloud-profiler-nodejs/pull/518))
|
|
263
|
-
- build: use config file for linkinator ([#517](https://github.com/googleapis/cloud-profiler-nodejs/pull/517))
|
|
264
|
-
|
|
265
|
-
## v2.0.2
|
|
266
|
-
|
|
267
|
-
06-26-2019 08:59 PDT
|
|
268
|
-
|
|
269
|
-
### Dependencies
|
|
270
|
-
- chore(deps): update dependency typescript to ~3.5.0 ([#498](https://github.com/googleapis/cloud-profiler-nodejs/pull/498))
|
|
271
|
-
- chore(deps): update dependency js-green-licenses to v1 ([#503](https://github.com/googleapis/cloud-profiler-nodejs/pull/503))
|
|
272
|
-
- chore(deps): update sinon and @types/sinon ([#504](https://github.com/googleapis/cloud-profiler-nodejs/pull/504))
|
|
273
|
-
- fix(deps): update dependency pprof to v1 ([#487](https://github.com/googleapis/cloud-profiler-nodejs/pull/487))
|
|
274
|
-
|
|
275
|
-
### Documentation
|
|
276
|
-
- fix(docs): make anchors work in jsdoc ([#513](https://github.com/googleapis/cloud-profiler-nodejs/pull/513))
|
|
277
|
-
- docs: add repo-metadata for docs ([#511](https://github.com/googleapis/cloud-profiler-nodejs/pull/511))
|
|
278
|
-
|
|
279
|
-
### Internal / Testing Changes
|
|
280
|
-
- build: switch to GitHub magic proxy ([#510](https://github.com/googleapis/cloud-profiler-nodejs/pull/510))
|
|
281
|
-
- build: set correct src path for template ([#508](https://github.com/googleapis/cloud-profiler-nodejs/pull/508))
|
|
282
|
-
- build: use standard kokoro configuration ([#502](https://github.com/googleapis/cloud-profiler-nodejs/pull/502))
|
|
283
|
-
- chore: run gts fix ([#506](https://github.com/googleapis/cloud-profiler-nodejs/pull/506))
|
|
284
|
-
- build: share some code for E2E tests ([#505](https://github.com/googleapis/cloud-profiler-nodejs/pull/505))
|
|
285
|
-
- build: don't run test scripts in verbose mode ([#501](https://github.com/googleapis/cloud-profiler-nodejs/pull/501))
|
|
286
|
-
- build: ignore proto files in test coverage ([#497](https://github.com/googleapis/cloud-profiler-nodejs/pull/497))
|
|
287
|
-
|
|
288
|
-
## v2.0.1
|
|
289
|
-
|
|
290
|
-
05-23-2019 13:08 PDT
|
|
291
|
-
|
|
292
|
-
### Implementation Changes
|
|
293
|
-
- fix: agent should correctly set zone in GCP ([#489](https://github.com/googleapis/cloud-profiler-nodejs/pull/489))
|
|
294
|
-
|
|
295
|
-
### Dependencies
|
|
296
|
-
- fix(deps): remove unused dependencies ([#494](https://github.com/googleapis/cloud-profiler-nodejs/pull/494))
|
|
297
|
-
- refactor: drop dependency on pify ([#493](https://github.com/googleapis/cloud-profiler-nodejs/pull/493))
|
|
298
|
-
|
|
299
|
-
### Documentation
|
|
300
|
-
- doc: remove reference to Node 6 from documentation ([#485](https://github.com/googleapis/cloud-profiler-nodejs/pull/485))
|
|
301
|
-
|
|
302
|
-
### Internal / Testing Changes
|
|
303
|
-
- chore: retry npm install in system test when the command hangs ([#491](https://github.com/googleapis/cloud-profiler-nodejs/pull/491))
|
|
304
|
-
- chore: remove unused third_party directory ([#486](https://github.com/googleapis/cloud-profiler-nodejs/pull/486))
|
|
305
|
-
|
|
306
|
-
## v2.0.0
|
|
307
|
-
|
|
308
|
-
05-14-2019 13:21 PDT
|
|
309
|
-
|
|
310
|
-
### Implementation Changes
|
|
311
|
-
- build: remove support for node 6 ([#472](https://github.com/googleapis/cloud-profiler-nodejs/pull/472))
|
|
312
|
-
|
|
313
|
-
### Dependencies
|
|
314
|
-
- fix(deps): update dependency gcp-metadata to v2 ([#481](https://github.com/googleapis/cloud-profiler-nodejs/pull/481))
|
|
315
|
-
- fix(deps): update dependency @google-cloud/common to v1 ([#482](https://github.com/googleapis/cloud-profiler-nodejs/pull/482))
|
|
316
|
-
- fix(deps): update dependency pretty-ms to v5 ([#464](https://github.com/googleapis/cloud-profiler-nodejs/pull/464))
|
|
317
|
-
- chore(deps): update dependency gts to v1 ([#474](https://github.com/googleapis/cloud-profiler-nodejs/pull/474))
|
|
318
|
-
- fix(deps): update dependency gaxios to v2 ([#469](https://github.com/googleapis/cloud-profiler-nodejs/pull/469))
|
|
319
|
-
- chore(deps): update dependency @types/nock to v10 ([#470](https://github.com/googleapis/cloud-profiler-nodejs/pull/470))
|
|
320
|
-
- chore(dep): update mocha to 6.1 ([#461](https://github.com/googleapis/cloud-profiler-nodejs/pull/461))
|
|
321
|
-
|
|
322
|
-
### Documentation
|
|
323
|
-
- Specify default logging level ([#483](https://github.com/googleapis/cloud-profiler-nodejs/pull/483))
|
|
324
|
-
|
|
325
|
-
### Internal / Testing Changes
|
|
326
|
-
- build: allow Node 10 to push to codecov ([#480](https://github.com/googleapis/cloud-profiler-nodejs/pull/480))
|
|
327
|
-
- build: patch Windows container, fixing Node 10 ([#479](https://github.com/googleapis/cloud-profiler-nodejs/pull/479))
|
|
328
|
-
- Revert "build!: upgrade engines field to >=8.10.0 ([#476](https://github.com/googleapis/cloud-profiler-nodejs/pull/476))" ([#477](https://github.com/googleapis/cloud-profiler-nodejs/pull/477))
|
|
329
|
-
- build!: upgrade engines field to >=8.10.0 ([#476](https://github.com/googleapis/cloud-profiler-nodejs/pull/476))
|
|
330
|
-
- chore: update to .nycrc with --all enabled ([#473](https://github.com/googleapis/cloud-profiler-nodejs/pull/473))
|
|
331
|
-
- fix: update dependencies for npm audit ([#468](https://github.com/googleapis/cloud-profiler-nodejs/pull/468))
|
|
332
|
-
- fix: add es2015 as target for tsconfig.json ([#466](https://github.com/googleapis/cloud-profiler-nodejs/pull/466))
|
|
333
|
-
- chore: remove old kokoro configs ([#458](https://github.com/googleapis/cloud-profiler-nodejs/pull/458))
|
|
334
|
-
|
|
335
|
-
## v1.1.2
|
|
336
|
-
|
|
337
|
-
04-04-2019 13:05 PDT
|
|
338
|
-
|
|
339
|
-
No changes since last release.
|
|
340
|
-
|
|
341
|
-
Confirming that we can use [releasetool](https://github.com/googleapis/releasetool) to release the agent going forward.
|