@tsed/temporal 7.70.1 → 7.71.0

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.
@@ -1,6 +1,6 @@
1
1
  import { Logger } from "@tsed/common";
2
2
  import { InjectorService } from "@tsed/di";
3
- import { TemporalClient } from "./services/TemporalFactory";
3
+ import { TemporalClient } from "./services/TemporalFactory.js";
4
4
  export declare class TemporalModule {
5
5
  private temporalServices;
6
6
  protected logger: Logger;
@@ -1,2 +1,2 @@
1
- import { ActivityOptions } from "../interfaces/TemporalStore";
1
+ import { ActivityOptions } from "../interfaces/TemporalStore.js";
2
2
  export declare function Activity(options?: ActivityOptions): MethodDecorator;
@@ -1,11 +1,11 @@
1
1
  /**
2
- * @file Automatically generated by barrelsby.
2
+ * @file Automatically generated by @tsed/barrels.
3
3
  */
4
- export * from "./TemporalModule";
5
- export * from "./constants";
6
- export * from "./decorators/activity";
7
- export * from "./decorators/temporal";
8
- export * from "./interfaces/TemporalStore";
9
- export * from "./interfaces/interfaces";
10
- export * from "./services/TemporalFactory";
11
- export * from "./utils/worker";
4
+ export * from "./constants.js";
5
+ export * from "./decorators/activity.js";
6
+ export * from "./decorators/temporal.js";
7
+ export * from "./interfaces/interfaces.js";
8
+ export * from "./interfaces/TemporalStore.js";
9
+ export * from "./services/TemporalFactory.js";
10
+ export * from "./TemporalModule.js";
11
+ export * from "./utils/worker.js";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tsed/temporal",
3
- "version": "7.70.1",
3
+ "version": "7.71.0",
4
4
  "description": "Temporal.io package for Ts.ED framework",
5
5
  "source": "./src/index.ts",
6
6
  "main": "./lib/cjs/index.js",
@@ -14,7 +14,7 @@
14
14
  },
15
15
  "scripts": {
16
16
  "build": "yarn barrels && yarn build:ts",
17
- "barrels": "yarn barrelsby --delete -d ./src -e \"\\.spec\\.ts\" -e \"__mock__\" -e \".benchmark.ts\"",
17
+ "barrels": "barrels",
18
18
  "test": "jest --runInBand --forceExit && jest-coverage-thresholds-bumper ",
19
19
  "build:ts": "tsc --build tsconfig.json && tsc --build tsconfig.esm.json"
20
20
  },
@@ -25,11 +25,11 @@
25
25
  "@temporalio/client": "1.8.4",
26
26
  "@temporalio/testing": "1.8.4",
27
27
  "@temporalio/worker": "1.8.4",
28
- "@tsed/common": "7.70.1",
29
- "@tsed/core": "7.70.1",
30
- "@tsed/di": "7.70.1",
31
- "@tsed/typescript": "7.70.1",
32
- "barrelsby": "^2.8.1",
28
+ "@tsed/barrels": "7.71.0",
29
+ "@tsed/common": "7.71.0",
30
+ "@tsed/core": "7.71.0",
31
+ "@tsed/di": "7.71.0",
32
+ "@tsed/typescript": "7.71.0",
33
33
  "cross-env": "7.0.3",
34
34
  "eslint": "^8.57.0",
35
35
  "jest": "^29.7.0"
package/readme.md CHANGED
@@ -83,7 +83,10 @@ import {Temporal, Activity} from "@tsed/temporal";
83
83
 
84
84
  @Temporal()
85
85
  export class UserOnboardingActivities {
86
- constructor(private userService: UserService, private emailService: EmailService) {}
86
+ constructor(
87
+ private userService: UserService,
88
+ private emailService: EmailService
89
+ ) {}
87
90
 
88
91
  @Activity()
89
92
  async sendVerificationEmail(email: string) {
@@ -136,7 +139,7 @@ Do not import any non temporal packages here. The workflows are bundled internal
136
139
 
137
140
  ```ts
138
141
  import {proxyActivities, defineSignal, setHandler, condition, sleep} from "@temporalio/workflow";
139
- import {Activities} from "../activities";
142
+ import {Activities} from "../activities.js";
140
143
 
141
144
  export const isVerifiedSignal = defineSignal("verificationSignal");
142
145
 
@@ -177,7 +180,7 @@ Inject the TemporalClient instance to interact with it directly, e.g. to start a
177
180
  ```typescript
178
181
  import {Service, AfterRoutesInit} from "@tsed/common";
179
182
  import {TemporalClient} from "@tsed/temporal";
180
- import {onboardUser} from "../workflows";
183
+ import {onboardUser} from "../workflows.js";
181
184
 
182
185
  @Service()
183
186
  export class UsersService implements AfterRoutesInit {
@@ -205,7 +208,7 @@ Read more about it [here](https://docs.temporal.io/typescript/troubleshooting/#w
205
208
 
206
209
  ```ts
207
210
  import {bootstrapWorker} from "@tsed/temporal";
208
- import {Server} from "./app/Server";
211
+ import {Server} from "./app/Server.js";
209
212
 
210
213
  const worker = await bootstrapWorker(Server, {
211
214
  worker: {
@@ -1,9 +1,9 @@
1
1
  import {classOf} from "@tsed/core";
2
2
  import {Logger} from "@tsed/common";
3
3
  import {Inject, InjectorService, Module, Provider} from "@tsed/di";
4
- import {PROVIDER_TYPE_TEMPORAL} from "./constants";
5
- import {TemporalStore, TEMPORAL_STORE_KEY} from "./interfaces/TemporalStore";
6
- import {TemporalClient} from "./services/TemporalFactory";
4
+ import {PROVIDER_TYPE_TEMPORAL} from "./constants.js";
5
+ import {TemporalStore, TEMPORAL_STORE_KEY} from "./interfaces/TemporalStore.js";
6
+ import {TemporalClient} from "./services/TemporalFactory.js";
7
7
 
8
8
  @Module()
9
9
  export class TemporalModule {
@@ -1,6 +1,6 @@
1
1
  import {Store} from "@tsed/core";
2
- import {Activity} from "./activity";
3
- import {Temporal} from "./temporal";
2
+ import {Activity} from "./activity.js";
3
+ import {Temporal} from "./temporal.js";
4
4
 
5
5
  describe("@Activity()", () => {
6
6
  it("should set metadata", () => {
@@ -1,5 +1,5 @@
1
1
  import {Store} from "@tsed/core";
2
- import {TemporalStore, ActivityOptions, TEMPORAL_STORE_KEY} from "../interfaces/TemporalStore";
2
+ import {TemporalStore, ActivityOptions, TEMPORAL_STORE_KEY} from "../interfaces/TemporalStore.js";
3
3
 
4
4
  export function Activity(options: ActivityOptions = {}): MethodDecorator {
5
5
  return (target: any, propertyKey: string | symbol) => {
@@ -1,5 +1,5 @@
1
1
  import {GlobalProviders} from "@tsed/di";
2
- import {Temporal} from "./temporal";
2
+ import {Temporal} from "./temporal.js";
3
3
 
4
4
  describe("@Activity()", () => {
5
5
  it("should set metadata", () => {
@@ -1,6 +1,6 @@
1
1
  import {useDecorators} from "@tsed/core";
2
2
  import {Injectable} from "@tsed/di";
3
- import {PROVIDER_TYPE_TEMPORAL} from "../constants";
3
+ import {PROVIDER_TYPE_TEMPORAL} from "../constants.js";
4
4
 
5
5
  export function Temporal(): ClassDecorator {
6
6
  return useDecorators(
package/src/index.ts CHANGED
@@ -1,12 +1,11 @@
1
1
  /**
2
- * @file Automatically generated by barrelsby.
2
+ * @file Automatically generated by @tsed/barrels.
3
3
  */
4
-
5
- export * from "./TemporalModule";
6
- export * from "./constants";
7
- export * from "./decorators/activity";
8
- export * from "./decorators/temporal";
9
- export * from "./interfaces/TemporalStore";
10
- export * from "./interfaces/interfaces";
11
- export * from "./services/TemporalFactory";
12
- export * from "./utils/worker";
4
+ export * from "./constants.js";
5
+ export * from "./decorators/activity.js";
6
+ export * from "./decorators/temporal.js";
7
+ export * from "./interfaces/interfaces.js";
8
+ export * from "./interfaces/TemporalStore.js";
9
+ export * from "./services/TemporalFactory.js";
10
+ export * from "./TemporalModule.js";
11
+ export * from "./utils/worker.js";
@@ -2,7 +2,7 @@ import {PlatformBuilderSettings, PlatformTest} from "@tsed/common";
2
2
  import {$log} from "@tsed/logger";
3
3
 
4
4
  import {NativeConnection, NativeConnectionOptions, Worker, WorkerOptions} from "@temporalio/worker";
5
- import {TemporalModule} from "../TemporalModule";
5
+ import {TemporalModule} from "../TemporalModule.js";
6
6
 
7
7
  type BootstrapWorkerOptions = {
8
8
  platform?: PlatformBuilderSettings;