@googlemaps/routing 1.0.0 → 1.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.
- package/CHANGELOG.md +7 -0
- package/README.md +1 -1
- package/build/src/v2/routes_client.d.ts +2 -3
- package/build/src/v2/routes_client.js +4 -5
- package/package.json +3 -3
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,12 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [1.0.1](https://github.com/googleapis/google-cloud-node/compare/routing-v1.0.0...routing-v1.0.1) (2023-09-06)
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
### Bug Fixes
|
|
7
|
+
|
|
8
|
+
* [Many APIs] simplify logic for HTTP/1.1 REST fallback option ([#4589](https://github.com/googleapis/google-cloud-node/issues/4589)) ([07967ad](https://github.com/googleapis/google-cloud-node/commit/07967add1b5fc28b548cf74721b595ea0ba90d5b))
|
|
9
|
+
|
|
3
10
|
## [1.0.0](https://github.com/googleapis/google-cloud-node/compare/routing-v0.6.0...routing-v1.0.0) (2023-08-06)
|
|
4
11
|
|
|
5
12
|
|
package/README.md
CHANGED
|
@@ -173,7 +173,7 @@ also contains samples.
|
|
|
173
173
|
|
|
174
174
|
## Supported Node.js Versions
|
|
175
175
|
|
|
176
|
-
Our client libraries follow the [Node.js release schedule](https://
|
|
176
|
+
Our client libraries follow the [Node.js release schedule](https://github.com/nodejs/release#release-schedule).
|
|
177
177
|
Libraries are compatible with all current _active_ and _maintenance_ versions of
|
|
178
178
|
Node.js.
|
|
179
179
|
If you are using an end-of-life version of Node.js, we recommend that you update
|
|
@@ -51,8 +51,7 @@ export declare class RoutesClient {
|
|
|
51
51
|
* API remote host.
|
|
52
52
|
* @param {gax.ClientConfig} [options.clientConfig] - Client configuration override.
|
|
53
53
|
* Follows the structure of {@link gapicConfig}.
|
|
54
|
-
* @param {boolean
|
|
55
|
-
* Pass "rest" to use HTTP/1.1 REST API instead of gRPC.
|
|
54
|
+
* @param {boolean} [options.fallback] - Use HTTP/1.1 REST mode.
|
|
56
55
|
* For more information, please check the
|
|
57
56
|
* {@link https://github.com/googleapis/gax-nodejs/blob/main/client-libraries.md#http11-rest-api-mode documentation}.
|
|
58
57
|
* @param {gax} [gaxInstance]: loaded instance of `google-gax`. Useful if you
|
|
@@ -60,7 +59,7 @@ export declare class RoutesClient {
|
|
|
60
59
|
* HTTP implementation. Load only fallback version and pass it to the constructor:
|
|
61
60
|
* ```
|
|
62
61
|
* const gax = require('google-gax/build/src/fallback'); // avoids loading google-gax with gRPC
|
|
63
|
-
* const client = new RoutesClient({fallback:
|
|
62
|
+
* const client = new RoutesClient({fallback: true}, gax);
|
|
64
63
|
* ```
|
|
65
64
|
*/
|
|
66
65
|
constructor(opts?: ClientOptions, gaxInstance?: typeof gax | typeof gax.fallback);
|
|
@@ -61,8 +61,7 @@ class RoutesClient {
|
|
|
61
61
|
* API remote host.
|
|
62
62
|
* @param {gax.ClientConfig} [options.clientConfig] - Client configuration override.
|
|
63
63
|
* Follows the structure of {@link gapicConfig}.
|
|
64
|
-
* @param {boolean
|
|
65
|
-
* Pass "rest" to use HTTP/1.1 REST API instead of gRPC.
|
|
64
|
+
* @param {boolean} [options.fallback] - Use HTTP/1.1 REST mode.
|
|
66
65
|
* For more information, please check the
|
|
67
66
|
* {@link https://github.com/googleapis/gax-nodejs/blob/main/client-libraries.md#http11-rest-api-mode documentation}.
|
|
68
67
|
* @param {gax} [gaxInstance]: loaded instance of `google-gax`. Useful if you
|
|
@@ -70,7 +69,7 @@ class RoutesClient {
|
|
|
70
69
|
* HTTP implementation. Load only fallback version and pass it to the constructor:
|
|
71
70
|
* ```
|
|
72
71
|
* const gax = require('google-gax/build/src/fallback'); // avoids loading google-gax with gRPC
|
|
73
|
-
* const client = new RoutesClient({fallback:
|
|
72
|
+
* const client = new RoutesClient({fallback: true}, gax);
|
|
74
73
|
* ```
|
|
75
74
|
*/
|
|
76
75
|
constructor(opts, gaxInstance) {
|
|
@@ -127,7 +126,7 @@ class RoutesClient {
|
|
|
127
126
|
if (!opts.fallback) {
|
|
128
127
|
clientHeader.push(`grpc/${this._gaxGrpc.grpcVersion}`);
|
|
129
128
|
}
|
|
130
|
-
else
|
|
129
|
+
else {
|
|
131
130
|
clientHeader.push(`rest/${this._gaxGrpc.grpcVersion}`);
|
|
132
131
|
}
|
|
133
132
|
if (opts.libName && opts.libVersion) {
|
|
@@ -138,7 +137,7 @@ class RoutesClient {
|
|
|
138
137
|
// Some of the methods on this service provide streaming responses.
|
|
139
138
|
// Provide descriptors for these.
|
|
140
139
|
this.descriptors.stream = {
|
|
141
|
-
computeRouteMatrix: new this._gaxModule.StreamDescriptor(this._gaxModule.StreamType.SERVER_STREAMING, opts.fallback
|
|
140
|
+
computeRouteMatrix: new this._gaxModule.StreamDescriptor(this._gaxModule.StreamType.SERVER_STREAMING, !!opts.fallback),
|
|
142
141
|
};
|
|
143
142
|
// Put together the default options sent with requests.
|
|
144
143
|
this._defaults = this._gaxGrpc.constructSettings('google.maps.routing.v2.Routes', gapicConfig, opts.clientConfig || {}, { 'x-goog-api-client': clientHeader.join(' ') });
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@googlemaps/routing",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.1",
|
|
4
4
|
"description": " client for Node.js",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -56,8 +56,8 @@
|
|
|
56
56
|
"gapic-tools": "^0.1.8",
|
|
57
57
|
"gts": "^5.0.0",
|
|
58
58
|
"jsdoc": "^4.0.0",
|
|
59
|
-
"jsdoc-fresh": "^
|
|
60
|
-
"jsdoc-region-tag": "^
|
|
59
|
+
"jsdoc-fresh": "^3.0.0",
|
|
60
|
+
"jsdoc-region-tag": "^3.0.0",
|
|
61
61
|
"linkinator": "4.1.2",
|
|
62
62
|
"long": "^5.2.3",
|
|
63
63
|
"mocha": "^9.2.2",
|