Skip to content

Commit

Permalink
reuse connections by default (#52)
Browse files Browse the repository at this point in the history
* reuse connections by default

* bump version to 4.5.2
  • Loading branch information
soulplant authored Mar 30, 2022
1 parent 6da063b commit 84e5a15
Show file tree
Hide file tree
Showing 9 changed files with 19 additions and 4 deletions.
2 changes: 1 addition & 1 deletion generate/generate.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ if [ -z "$TEMPLATES_PATH" ]; then
die "TEMPLATES_PATH must be set, e.g. /path/to/sajari/sdk-node/generate/templates"
fi

VERSION=4.5.1
VERSION=4.5.2

docker-entrypoint.sh generate \
-i /openapi.json \
Expand Down
2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@sajari/sdk-node",
"version": "4.5.1",
"version": "4.5.2",
"repository": "[email protected]:github.com/sajari/sdk-node.git",
"author": "Search.io",
"license": "MIT",
Expand Down
3 changes: 3 additions & 0 deletions src/collections.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@ export class CollectionsClient extends Client {
this.client.defaultHeaders = {
[clientUserAgentHeader]: clientUserAgent(),
};
this.client.addInterceptor(opts => {
opts.forever = true;
})
}

async getCollection(id: string) {
Expand Down
3 changes: 3 additions & 0 deletions src/events.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@ export class EventsClient extends Client {
this.client.defaultHeaders = {
[clientUserAgentHeader]: clientUserAgent(),
};
this.client.addInterceptor(opts => {
opts.forever = true;
})
}

async sendEvent(accountId: string, args: SendEventRequest) {
Expand Down
3 changes: 3 additions & 0 deletions src/pipelines.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,9 @@ export class PipelinesClient extends Client {
this.client.defaultHeaders = {
[clientUserAgentHeader]: clientUserAgent(),
};
this.client.addInterceptor(opts => {
opts.forever = true;
})
}

async getPipeline({
Expand Down
3 changes: 3 additions & 0 deletions src/records.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,9 @@ export class RecordsClient extends Client {
this.client.defaultHeaders = {
[clientUserAgentHeader]: clientUserAgent(),
};
this.client.addInterceptor(opts => {
opts.forever = true;
})
}

async getRecord(key: RecordKey) {
Expand Down
3 changes: 3 additions & 0 deletions src/schema.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@ export class SchemaClient extends Client {
this.client.defaultHeaders = {
[clientUserAgentHeader]: clientUserAgent(),
};
this.client.addInterceptor(opts => {
opts.forever = true;
})
}

async listFields({
Expand Down
2 changes: 1 addition & 1 deletion src/version.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
// Code generated by generate-version.ts. DO NOT EDIT.

export const version = "4.5.1";
export const version = "4.5.2";

0 comments on commit 84e5a15

Please sign in to comment.