@punks/backend-entity-manager 0.0.284 → 0.0.285
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/dist/cjs/index.js +2 -1
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/types/platforms/nest/extensions/jobs/services/jobs-service/service.d.ts +2 -2
- package/dist/esm/index.js +2 -1
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/types/platforms/nest/extensions/jobs/services/jobs-service/service.d.ts +2 -2
- package/dist/index.d.ts +1 -1
- package/package.json +1 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { IJobDefinitionsRepository, IJobInstancesRepository, JobDefinition } from "../../abstractions";
|
|
1
|
+
import { IJobDefinitionsRepository, IJobInstancesRepository, JobDefinition, JobInstance } from "../../abstractions";
|
|
2
2
|
import { CommandBus } from "@nestjs/cqrs";
|
|
3
3
|
import { JobTriggerInput } from "./types";
|
|
4
4
|
export declare class JobsService {
|
|
@@ -6,7 +6,7 @@ export declare class JobsService {
|
|
|
6
6
|
private readonly instances;
|
|
7
7
|
private readonly commandBus;
|
|
8
8
|
constructor(definitions: IJobDefinitionsRepository, instances: IJobInstancesRepository, commandBus: CommandBus);
|
|
9
|
-
triggerJob: (input: JobTriggerInput) => Promise<
|
|
9
|
+
triggerJob: (input: JobTriggerInput) => Promise<JobInstance>;
|
|
10
10
|
updateJob: (input: JobDefinition<unknown, unknown>) => Promise<void>;
|
|
11
11
|
instanceMonitor: (input: {
|
|
12
12
|
instanceId: string;
|
package/dist/esm/index.js
CHANGED
|
@@ -33964,10 +33964,11 @@ let JobDispatchHandler = JobDispatchHandler_1 = class JobDispatchHandler {
|
|
|
33964
33964
|
instanceId,
|
|
33965
33965
|
payload,
|
|
33966
33966
|
});
|
|
33967
|
-
await this.instances.updateInstance(instanceId, {
|
|
33967
|
+
const instance = await this.instances.updateInstance(instanceId, {
|
|
33968
33968
|
status: JobStatus.Ready,
|
|
33969
33969
|
});
|
|
33970
33970
|
this.logger.info(`JOB DISPATCH -> dispatching completed job ${job.uid} -> ${instanceId}`);
|
|
33971
|
+
return instance;
|
|
33971
33972
|
}
|
|
33972
33973
|
catch (e) {
|
|
33973
33974
|
await this.instances.updateInstance(instanceId, {
|