@hastehaul/common 4.0.0 → 4.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.
Files changed (35) hide show
  1. package/build/connections-wrappers/redis-connection-wrapper.d.ts +10 -0
  2. package/build/connections-wrappers/redis-connection-wrapper.js +14 -0
  3. package/build/utils/base_classes/jobs/base-producers.js +1 -1
  4. package/build/utils/base_classes/jobs/base-worker.js +1 -1
  5. package/package.json +1 -1
  6. package/build/connections-wrappers/index.d.ts +0 -2
  7. package/build/connections-wrappers/index.js +0 -18
  8. package/build/errors/index.d.ts +0 -30
  9. package/build/errors/index.js +0 -47
  10. package/build/events/base/index.d.ts +0 -21
  11. package/build/events/base/index.js +0 -38
  12. package/build/events/common/enums/index.d.ts +0 -18
  13. package/build/events/common/enums/index.js +0 -35
  14. package/build/events/common/index.d.ts +0 -14
  15. package/build/events/common/index.js +0 -31
  16. package/build/events/common/interfaces/customer-system-events-interfaces/customer-system-updated-customer-service-event.d.ts +0 -34
  17. package/build/events/common/interfaces/customer-system-events-interfaces/customer-system-updated-customer-service-event.js +0 -2
  18. package/build/events/common/interfaces/customer-system-events-interfaces/customer-system-updated-payment-service-event.d.ts +0 -34
  19. package/build/events/common/interfaces/customer-system-events-interfaces/customer-system-updated-payment-service-event.js +0 -2
  20. package/build/events/common/interfaces/index.d.ts +0 -13
  21. package/build/events/common/interfaces/index.js +0 -33
  22. package/build/events/common/interfaces/order-events-interfaces/index.d.ts +0 -18
  23. package/build/events/common/interfaces/order-events-interfaces/index.js +0 -35
  24. package/build/events/common/interfaces/payment-event-interfaces/index.d.ts +0 -0
  25. package/build/events/common/interfaces/payment-event-interfaces/index.js +0 -3
  26. package/build/events/common/interfaces/stream-interfaces/index.d.ts +0 -1
  27. package/build/events/common/interfaces/stream-interfaces/index.js +0 -18
  28. package/build/events/index.d.ts +0 -14
  29. package/build/events/index.js +0 -31
  30. package/build/middlewares/index.d.ts +0 -2
  31. package/build/middlewares/index.js +0 -18
  32. package/build/utils/base_classes/index.d.ts +0 -21
  33. package/build/utils/base_classes/index.js +0 -38
  34. package/build/utils/index.d.ts +0 -21
  35. package/build/utils/index.js +0 -38
@@ -5,6 +5,7 @@ import IORedis from "ioredis";
5
5
  */
6
6
  export declare class RedisWrapper {
7
7
  private _redisClient?;
8
+ private _bullmqClient?;
8
9
  private host;
9
10
  private port;
10
11
  /**
@@ -14,6 +15,15 @@ export declare class RedisWrapper {
14
15
  * @returns {IORedis} - The Redis client instance.
15
16
  */
16
17
  get client(): IORedis;
18
+ /**
19
+ * The client BullMQ queues and workers use, when one has been set; otherwise the shared client.
20
+ *
21
+ * BullMQ defines its Lua scripts on whatever client it is given, and ioredis copies every defined
22
+ * script onto every pipeline that client builds. Giving BullMQ its own client keeps the shared
23
+ * client's pipelines small.
24
+ */
25
+ get bullmqClient(): IORedis;
26
+ set bullmqClient(client: IORedis);
17
27
  /**
18
28
  * Connect to the Redis server using the specified host and port.
19
29
  *
@@ -34,6 +34,20 @@ class RedisWrapper {
34
34
  throw new Error("Cannot access Redis Client before connecting");
35
35
  return this._redisClient;
36
36
  }
37
+ /**
38
+ * The client BullMQ queues and workers use, when one has been set; otherwise the shared client.
39
+ *
40
+ * BullMQ defines its Lua scripts on whatever client it is given, and ioredis copies every defined
41
+ * script onto every pipeline that client builds. Giving BullMQ its own client keeps the shared
42
+ * client's pipelines small.
43
+ */
44
+ get bullmqClient() {
45
+ var _a;
46
+ return (_a = this._bullmqClient) !== null && _a !== void 0 ? _a : this.client;
47
+ }
48
+ set bullmqClient(client) {
49
+ this._bullmqClient = client;
50
+ }
37
51
  /**
38
52
  * Connect to the Redis server using the specified host and port.
39
53
  *
@@ -15,7 +15,7 @@ class AbstractJobQueue {
15
15
  */
16
16
  constructor(queueName, useReplicas = true) {
17
17
  // Initialize the job queue with the provided name and a Redis connection from the redisWrapper.
18
- this.que = new bullmq_1.Queue(queueName, { connection: useReplicas ? redis_wrapper_1.rWrapper.masterClient : redis_connection_wrapper_1.redisWrapper.client, prefix: '{BULLMQ}' });
18
+ this.que = new bullmq_1.Queue(queueName, { connection: useReplicas ? redis_wrapper_1.rWrapper.masterClient : redis_connection_wrapper_1.redisWrapper.bullmqClient, prefix: '{BULLMQ}' });
19
19
  }
20
20
  }
21
21
  exports.AbstractJobQueue = AbstractJobQueue;
@@ -17,7 +17,7 @@ class AbstractWorker {
17
17
  constructor(queueName, useReplicas = true, opts) {
18
18
  this.events = new events_1.EventEmitter();
19
19
  // Create a worker instance with the provided queueName and bind the 'process' method to this worker.
20
- this.worker = new bullmq_1.Worker(queueName, this.process.bind(this), Object.assign({ connection: useReplicas ? redis_wrapper_1.rWrapper.masterClient : redis_connection_wrapper_1.redisWrapper.client, autorun: false, prefix: '{BULLMQ}' }, opts));
20
+ this.worker = new bullmq_1.Worker(queueName, this.process.bind(this), Object.assign({ connection: useReplicas ? redis_wrapper_1.rWrapper.masterClient : redis_connection_wrapper_1.redisWrapper.bullmqClient, autorun: false, prefix: '{BULLMQ}' }, opts));
21
21
  // Handle errors that may occur during job processing.
22
22
  this.worker.on("error", (err) => {
23
23
  console.error(`${queueName} Error: `, err);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hastehaul/common",
3
- "version": "4.0.0",
3
+ "version": "4.0.1",
4
4
  "description": "",
5
5
  "main": "./build/index.js",
6
6
  "types": "./build/index.d.ts",
@@ -1,2 +0,0 @@
1
- export * from "./redis-connection-wrapper";
2
- export * from "./socket-connection-wrapper";
@@ -1,18 +0,0 @@
1
- "use strict";
2
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
- if (k2 === undefined) k2 = k;
4
- var desc = Object.getOwnPropertyDescriptor(m, k);
5
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
- desc = { enumerable: true, get: function() { return m[k]; } };
7
- }
8
- Object.defineProperty(o, k2, desc);
9
- }) : (function(o, m, k, k2) {
10
- if (k2 === undefined) k2 = k;
11
- o[k2] = m[k];
12
- }));
13
- var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
- for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
- };
16
- Object.defineProperty(exports, "__esModule", { value: true });
17
- __exportStar(require("./redis-connection-wrapper"), exports);
18
- __exportStar(require("./socket-connection-wrapper"), exports);
@@ -1,30 +0,0 @@
1
- /**
2
- * Re-exports the "BadRequestError" class from the "bad-request-error" file.
3
- *
4
- * The "BadRequestError" class represents a specific "Bad Request" error and is used to handle client requests with invalid or malformed data.
5
- */
6
- export * from "./bad-request-error";
7
- /**
8
- * Re-exports the "CustomError" abstract class from the "custom-error" file.
9
- *
10
- * The "CustomError" abstract class serves as the foundation for creating specific error classes for different types of errors.
11
- */
12
- export * from "./custom-error";
13
- /**
14
- * Re-exports the "DatabaseError" class from the "database-error" file.
15
- *
16
- * The "DatabaseError" class represents a specific error related to database operations or connectivity issues.
17
- */
18
- export * from "./database-error";
19
- /**
20
- * Re-exports the "NotFoundError" class from the "not-found-error" file.
21
- *
22
- * The "NotFoundError" class represents a specific "Not Found" error and is used when a requested resource is not found.
23
- */
24
- export * from "./not-found-error";
25
- /**
26
- * Re-exports the "SystemError" class from the "system-error" file.
27
- *
28
- * The "SystemError" class represents a specific "System Error" that can occur due to unexpected issues in the system.
29
- */
30
- export * from "./system-error";
@@ -1,47 +0,0 @@
1
- "use strict";
2
- // Import and re-export custom error classes for easier access.
3
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
4
- if (k2 === undefined) k2 = k;
5
- var desc = Object.getOwnPropertyDescriptor(m, k);
6
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
7
- desc = { enumerable: true, get: function() { return m[k]; } };
8
- }
9
- Object.defineProperty(o, k2, desc);
10
- }) : (function(o, m, k, k2) {
11
- if (k2 === undefined) k2 = k;
12
- o[k2] = m[k];
13
- }));
14
- var __exportStar = (this && this.__exportStar) || function(m, exports) {
15
- for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
16
- };
17
- Object.defineProperty(exports, "__esModule", { value: true });
18
- /**
19
- * Re-exports the "BadRequestError" class from the "bad-request-error" file.
20
- *
21
- * The "BadRequestError" class represents a specific "Bad Request" error and is used to handle client requests with invalid or malformed data.
22
- */
23
- __exportStar(require("./bad-request-error"), exports);
24
- /**
25
- * Re-exports the "CustomError" abstract class from the "custom-error" file.
26
- *
27
- * The "CustomError" abstract class serves as the foundation for creating specific error classes for different types of errors.
28
- */
29
- __exportStar(require("./custom-error"), exports);
30
- /**
31
- * Re-exports the "DatabaseError" class from the "database-error" file.
32
- *
33
- * The "DatabaseError" class represents a specific error related to database operations or connectivity issues.
34
- */
35
- __exportStar(require("./database-error"), exports);
36
- /**
37
- * Re-exports the "NotFoundError" class from the "not-found-error" file.
38
- *
39
- * The "NotFoundError" class represents a specific "Not Found" error and is used when a requested resource is not found.
40
- */
41
- __exportStar(require("./not-found-error"), exports);
42
- /**
43
- * Re-exports the "SystemError" class from the "system-error" file.
44
- *
45
- * The "SystemError" class represents a specific "System Error" that can occur due to unexpected issues in the system.
46
- */
47
- __exportStar(require("./system-error"), exports);
@@ -1,21 +0,0 @@
1
- /**
2
- * Re-exports the "BaseConsumer" class from the "base-consumer" file.
3
- *
4
- * The "BaseConsumer" class serves as a base class for implementing event consumers.
5
- * It provides common functionality and methods that can be extended by specific consumer implementations.
6
- */
7
- export * from "./base-consumer";
8
- /**
9
- * Re-exports the "BasePublisher" class from the "base-publisher" file.
10
- *
11
- * The "BasePublisher" class serves as a base class for implementing event publishers.
12
- * It provides common functionality and methods that can be extended by specific publisher implementations.
13
- */
14
- export * from "./base-publisher";
15
- /**
16
- * Re-exports the "BaseStream" class from the "base-stream" file.
17
- *
18
- * The "BaseStream" class serves as a base class for implementing event streams.
19
- * It provides common functionality and methods that can be extended by specific stream implementations.
20
- */
21
- export * from "./base-stream";
@@ -1,38 +0,0 @@
1
- "use strict";
2
- // Import and re-export base classes for consumers, publishers, and streams.
3
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
4
- if (k2 === undefined) k2 = k;
5
- var desc = Object.getOwnPropertyDescriptor(m, k);
6
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
7
- desc = { enumerable: true, get: function() { return m[k]; } };
8
- }
9
- Object.defineProperty(o, k2, desc);
10
- }) : (function(o, m, k, k2) {
11
- if (k2 === undefined) k2 = k;
12
- o[k2] = m[k];
13
- }));
14
- var __exportStar = (this && this.__exportStar) || function(m, exports) {
15
- for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
16
- };
17
- Object.defineProperty(exports, "__esModule", { value: true });
18
- /**
19
- * Re-exports the "BaseConsumer" class from the "base-consumer" file.
20
- *
21
- * The "BaseConsumer" class serves as a base class for implementing event consumers.
22
- * It provides common functionality and methods that can be extended by specific consumer implementations.
23
- */
24
- __exportStar(require("./base-consumer"), exports);
25
- /**
26
- * Re-exports the "BasePublisher" class from the "base-publisher" file.
27
- *
28
- * The "BasePublisher" class serves as a base class for implementing event publishers.
29
- * It provides common functionality and methods that can be extended by specific publisher implementations.
30
- */
31
- __exportStar(require("./base-publisher"), exports);
32
- /**
33
- * Re-exports the "BaseStream" class from the "base-stream" file.
34
- *
35
- * The "BaseStream" class serves as a base class for implementing event streams.
36
- * It provides common functionality and methods that can be extended by specific stream implementations.
37
- */
38
- __exportStar(require("./base-stream"), exports);
@@ -1,18 +0,0 @@
1
- /**
2
- * Re-exports all the types related to durable names from the "durable-names" file.
3
- *
4
- * The types include enums and utility types used to define durable names for consumers of different event types.
5
- */
6
- export * from "./durable-names";
7
- /**
8
- * Re-exports the type related to streams from the "streams" file.
9
- *
10
- * The "Streams" type alias represents a JetStream stream that can handle different event types.
11
- */
12
- export * from "./streams";
13
- /**
14
- * Re-exports the type related to subjects from the "subjects" file.
15
- *
16
- * The "Subjects" type alias represents the subjects for different event types.
17
- */
18
- export * from "./subjects";
@@ -1,35 +0,0 @@
1
- "use strict";
2
- // Import and re-export types from other files for easier access.
3
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
4
- if (k2 === undefined) k2 = k;
5
- var desc = Object.getOwnPropertyDescriptor(m, k);
6
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
7
- desc = { enumerable: true, get: function() { return m[k]; } };
8
- }
9
- Object.defineProperty(o, k2, desc);
10
- }) : (function(o, m, k, k2) {
11
- if (k2 === undefined) k2 = k;
12
- o[k2] = m[k];
13
- }));
14
- var __exportStar = (this && this.__exportStar) || function(m, exports) {
15
- for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
16
- };
17
- Object.defineProperty(exports, "__esModule", { value: true });
18
- /**
19
- * Re-exports all the types related to durable names from the "durable-names" file.
20
- *
21
- * The types include enums and utility types used to define durable names for consumers of different event types.
22
- */
23
- __exportStar(require("./durable-names"), exports);
24
- /**
25
- * Re-exports the type related to streams from the "streams" file.
26
- *
27
- * The "Streams" type alias represents a JetStream stream that can handle different event types.
28
- */
29
- __exportStar(require("./streams"), exports);
30
- /**
31
- * Re-exports the type related to subjects from the "subjects" file.
32
- *
33
- * The "Subjects" type alias represents the subjects for different event types.
34
- */
35
- __exportStar(require("./subjects"), exports);
@@ -1,14 +0,0 @@
1
- /**
2
- * Re-exports all the enums from the "enums" module.
3
- *
4
- * The "enums" module contains various enumerations used in the application.
5
- * Enumerations are used to define named constant values, such as status codes, subject names, or stream names.
6
- */
7
- export * from "./enums";
8
- /**
9
- * Re-exports all the interfaces from the "interfaces" module.
10
- *
11
- * The "interfaces" module contains various interfaces used in the application to define data structures and contracts.
12
- * Interfaces are used to describe the shape of objects and provide a common structure for communication between different parts of the application.
13
- */
14
- export * from "./interfaces";
@@ -1,31 +0,0 @@
1
- "use strict";
2
- // Import and re-export multiple modules related to enums and interfaces.
3
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
4
- if (k2 === undefined) k2 = k;
5
- var desc = Object.getOwnPropertyDescriptor(m, k);
6
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
7
- desc = { enumerable: true, get: function() { return m[k]; } };
8
- }
9
- Object.defineProperty(o, k2, desc);
10
- }) : (function(o, m, k, k2) {
11
- if (k2 === undefined) k2 = k;
12
- o[k2] = m[k];
13
- }));
14
- var __exportStar = (this && this.__exportStar) || function(m, exports) {
15
- for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
16
- };
17
- Object.defineProperty(exports, "__esModule", { value: true });
18
- /**
19
- * Re-exports all the enums from the "enums" module.
20
- *
21
- * The "enums" module contains various enumerations used in the application.
22
- * Enumerations are used to define named constant values, such as status codes, subject names, or stream names.
23
- */
24
- __exportStar(require("./enums"), exports);
25
- /**
26
- * Re-exports all the interfaces from the "interfaces" module.
27
- *
28
- * The "interfaces" module contains various interfaces used in the application to define data structures and contracts.
29
- * Interfaces are used to describe the shape of objects and provide a common structure for communication between different parts of the application.
30
- */
31
- __exportStar(require("./interfaces"), exports);
@@ -1,34 +0,0 @@
1
- import { CustomerSystemDurableName } from '../../enums/durable-names/customer-system-dname';
2
- import { CustomerSystemStream } from '../../enums/streams/customer-system-stream';
3
- import { CustomerSystemSubjects } from '../../enums/subjects/customer-system-subjects';
4
- /**
5
- * Interface representing the "Customer Updated Customer Service" event.
6
- *
7
- * The "CustomerUpdated Customer ServiceEvent" interface defines the structure of an event related to the cancellation of an customer.
8
- * Events of this type are used to communicate customer cancellation details across the application.
9
- */
10
- export interface CustomerSystemUpdatedCustomerServiceEvent {
11
- /**
12
- * The subject of the event, specifying that it represents an "Customer Updated Customer Service" event.
13
- */
14
- subject: CustomerSystemSubjects.CustomerSystemUpdateCustomerService;
15
- /**
16
- * The durable name associated with the consumer handling the "Customer Updated Customer Service" event.
17
- * This property is optional and may be used to identify the consumer processing the event in a durable manner.
18
- */
19
- durableName?: CustomerSystemDurableName.CustomerSystemUpdateCustomerServiceDurablename;
20
- /**
21
- * The stream to which the event belongs, specifying that it is an "Customer" stream.
22
- * Events of different types may be grouped into different streams based on their common characteristics.
23
- */
24
- stream: CustomerSystemStream.CustomerSystem;
25
- /**
26
- * The data payload of the "Customer Updated Customer Service" event.
27
- * The data payload contains specific details related to the customer cancellation, such as key, value and version
28
- */
29
- data: {
30
- key: string;
31
- value: string;
32
- version: number;
33
- };
34
- }
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,34 +0,0 @@
1
- import { CustomerSystemDurableName } from '../../enums/durable-names/customer-system-dname';
2
- import { CustomerSystemStream } from '../../enums/streams/customer-system-stream';
3
- import { CustomerSystemSubjects } from '../../enums/subjects/customer-system-subjects';
4
- /**
5
- * Interface representing the "Customer Updated Payment Service" event.
6
- *
7
- * The "CustomerUpdated Payment ServiceEvent" interface defines the structure of an event related to the cancellation of an customer.
8
- * Events of this type are used to communicate customer cancellation details across the application.
9
- */
10
- export interface CustomerSystemUpdatedPaymentServiceEvent {
11
- /**
12
- * The subject of the event, specifying that it represents an "Customer Updated Payment Service" event.
13
- */
14
- subject: CustomerSystemSubjects.CustomerSystemUpdatePaymentService;
15
- /**
16
- * The durable name associated with the consumer handling the "Customer Updated Payment Service" event.
17
- * This property is optional and may be used to identify the consumer processing the event in a durable manner.
18
- */
19
- durableName?: CustomerSystemDurableName.CustomerSystemUpdatePaymentServiceDurablename;
20
- /**
21
- * The stream to which the event belongs, specifying that it is an "Customer" stream.
22
- * Events of different types may be grouped into different streams based on their common characteristics.
23
- */
24
- stream: CustomerSystemStream.CustomerSystem;
25
- /**
26
- * The data payload of the "Customer Updated Payment Service" event.
27
- * The data payload contains specific details related to the customer cancellation, such as key, value and version
28
- */
29
- data: {
30
- key: string;
31
- value: string;
32
- version: number;
33
- };
34
- }
@@ -1,2 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,13 +0,0 @@
1
- /**
2
- * Re-exports all the interfaces related to order events from the "order-events-interfaces" file.
3
- *
4
- * The "order-events-interfaces" file contains interfaces for various order-related events such as order requested, order cancelled, and order completed.
5
- */
6
- export * from "./order-events-interfaces";
7
- /**
8
- * Re-exports all the interfaces related to streams from the "stream-interfaces" file.
9
- *
10
- * The "stream-interfaces" file contains interfaces for various streams used in the application.
11
- * For example, "OrderStreamEvent" represents an event associated with the "Order" stream.
12
- */
13
- export * from "./stream-interfaces";
@@ -1,33 +0,0 @@
1
- "use strict";
2
- // Import and re-export multiple interfaces related to different events and streams.
3
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
4
- if (k2 === undefined) k2 = k;
5
- var desc = Object.getOwnPropertyDescriptor(m, k);
6
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
7
- desc = { enumerable: true, get: function() { return m[k]; } };
8
- }
9
- Object.defineProperty(o, k2, desc);
10
- }) : (function(o, m, k, k2) {
11
- if (k2 === undefined) k2 = k;
12
- o[k2] = m[k];
13
- }));
14
- var __exportStar = (this && this.__exportStar) || function(m, exports) {
15
- for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
16
- };
17
- Object.defineProperty(exports, "__esModule", { value: true });
18
- /**
19
- * Re-exports all the interfaces related to order events from the "order-events-interfaces" file.
20
- *
21
- * The "order-events-interfaces" file contains interfaces for various order-related events such as order requested, order cancelled, and order completed.
22
- */
23
- __exportStar(require("./order-events-interfaces"), exports);
24
- // Interfaces related to payment events are currently commented out using '//'.
25
- // If needed, uncomment the following line to re-export the payment event interfaces.
26
- // export * from "./payment-event-interfaces";
27
- /**
28
- * Re-exports all the interfaces related to streams from the "stream-interfaces" file.
29
- *
30
- * The "stream-interfaces" file contains interfaces for various streams used in the application.
31
- * For example, "OrderStreamEvent" represents an event associated with the "Order" stream.
32
- */
33
- __exportStar(require("./stream-interfaces"), exports);
@@ -1,18 +0,0 @@
1
- /**
2
- * Re-exports the "OrderCancelledEvent" class from the "order-cancelled-event" file.
3
- *
4
- * The "OrderCancelledEvent" class represents an event related to the cancellation of an order.
5
- */
6
- export * from "./order-cancelled-event";
7
- /**
8
- * Re-exports the "OrderCompletedEvent" class from the "order-completed-event" file.
9
- *
10
- * The "OrderCompletedEvent" class represents an event related to the completion of an order.
11
- */
12
- export * from "./order-completed-event";
13
- /**
14
- * Re-exports the "OrderRequestedEvent" class from the "order-requested-event" file.
15
- *
16
- * The "OrderRequestedEvent" class represents an event related to a request for an order.
17
- */
18
- export * from "./order-requested-event";
@@ -1,35 +0,0 @@
1
- "use strict";
2
- // Import and re-export event classes for easier access.
3
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
4
- if (k2 === undefined) k2 = k;
5
- var desc = Object.getOwnPropertyDescriptor(m, k);
6
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
7
- desc = { enumerable: true, get: function() { return m[k]; } };
8
- }
9
- Object.defineProperty(o, k2, desc);
10
- }) : (function(o, m, k, k2) {
11
- if (k2 === undefined) k2 = k;
12
- o[k2] = m[k];
13
- }));
14
- var __exportStar = (this && this.__exportStar) || function(m, exports) {
15
- for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
16
- };
17
- Object.defineProperty(exports, "__esModule", { value: true });
18
- /**
19
- * Re-exports the "OrderCancelledEvent" class from the "order-cancelled-event" file.
20
- *
21
- * The "OrderCancelledEvent" class represents an event related to the cancellation of an order.
22
- */
23
- __exportStar(require("./order-cancelled-event"), exports);
24
- /**
25
- * Re-exports the "OrderCompletedEvent" class from the "order-completed-event" file.
26
- *
27
- * The "OrderCompletedEvent" class represents an event related to the completion of an order.
28
- */
29
- __exportStar(require("./order-completed-event"), exports);
30
- /**
31
- * Re-exports the "OrderRequestedEvent" class from the "order-requested-event" file.
32
- *
33
- * The "OrderRequestedEvent" class represents an event related to a request for an order.
34
- */
35
- __exportStar(require("./order-requested-event"), exports);
@@ -1,3 +0,0 @@
1
- "use strict";
2
- // export * from "./payment-created-event"
3
- // export * from "./payment-failed-event"
@@ -1 +0,0 @@
1
- export * from "./order-stream-interface";
@@ -1,18 +0,0 @@
1
- "use strict";
2
- // Import and re-export the contents of the "order-stream-interface.ts" file.
3
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
4
- if (k2 === undefined) k2 = k;
5
- var desc = Object.getOwnPropertyDescriptor(m, k);
6
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
7
- desc = { enumerable: true, get: function() { return m[k]; } };
8
- }
9
- Object.defineProperty(o, k2, desc);
10
- }) : (function(o, m, k, k2) {
11
- if (k2 === undefined) k2 = k;
12
- o[k2] = m[k];
13
- }));
14
- var __exportStar = (this && this.__exportStar) || function(m, exports) {
15
- for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
16
- };
17
- Object.defineProperty(exports, "__esModule", { value: true });
18
- __exportStar(require("./order-stream-interface"), exports);
@@ -1,14 +0,0 @@
1
- /**
2
- * Re-exports all the contents from the "base" module.
3
- *
4
- * The "base" module contains base classes and utilities that provide foundational functionality for various parts of the application.
5
- * This includes base classes for consumers, publishers, streams, etc., that can be extended to implement specific functionality.
6
- */
7
- export * from "./base";
8
- /**
9
- * Re-exports all the contents from the "common" module.
10
- *
11
- * The "common" module contains shared utilities, helper functions, enums, and interfaces that are commonly used across the application.
12
- * These shared resources provide a common set of functionalities to be used by different components or modules within the application.
13
- */
14
- export * from "./common";
@@ -1,31 +0,0 @@
1
- "use strict";
2
- // Import and re-export multiple modules related to "base" and "common" functionalities.
3
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
4
- if (k2 === undefined) k2 = k;
5
- var desc = Object.getOwnPropertyDescriptor(m, k);
6
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
7
- desc = { enumerable: true, get: function() { return m[k]; } };
8
- }
9
- Object.defineProperty(o, k2, desc);
10
- }) : (function(o, m, k, k2) {
11
- if (k2 === undefined) k2 = k;
12
- o[k2] = m[k];
13
- }));
14
- var __exportStar = (this && this.__exportStar) || function(m, exports) {
15
- for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
16
- };
17
- Object.defineProperty(exports, "__esModule", { value: true });
18
- /**
19
- * Re-exports all the contents from the "base" module.
20
- *
21
- * The "base" module contains base classes and utilities that provide foundational functionality for various parts of the application.
22
- * This includes base classes for consumers, publishers, streams, etc., that can be extended to implement specific functionality.
23
- */
24
- __exportStar(require("./base"), exports);
25
- /**
26
- * Re-exports all the contents from the "common" module.
27
- *
28
- * The "common" module contains shared utilities, helper functions, enums, and interfaces that are commonly used across the application.
29
- * These shared resources provide a common set of functionalities to be used by different components or modules within the application.
30
- */
31
- __exportStar(require("./common"), exports);
@@ -1,2 +0,0 @@
1
- export * from "./current-user";
2
- export * from "./error-handler";
@@ -1,18 +0,0 @@
1
- "use strict";
2
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
- if (k2 === undefined) k2 = k;
4
- var desc = Object.getOwnPropertyDescriptor(m, k);
5
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
- desc = { enumerable: true, get: function() { return m[k]; } };
7
- }
8
- Object.defineProperty(o, k2, desc);
9
- }) : (function(o, m, k, k2) {
10
- if (k2 === undefined) k2 = k;
11
- o[k2] = m[k];
12
- }));
13
- var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
- for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
- };
16
- Object.defineProperty(exports, "__esModule", { value: true });
17
- __exportStar(require("./current-user"), exports);
18
- __exportStar(require("./error-handler"), exports);
@@ -1,21 +0,0 @@
1
- /**
2
- * Re-exports all the contents from the "base-producers" module.
3
- *
4
- * The "base-producers" module contains base classes and utilities for implementing job producers in the application.
5
- * Job producers are responsible for generating and queuing jobs to be processed by job workers.
6
- */
7
- export * from "./jobs/base-producers";
8
- /**
9
- * Re-exports all the contents from the "base-worker" module.
10
- *
11
- * The "base-worker" module contains base classes and utilities for implementing job workers in the application.
12
- * Job workers are responsible for processing jobs generated by job producers and executing the required tasks.
13
- */
14
- export * from "./jobs/base-worker";
15
- /**
16
- * Re-exports all the contents from the "base-namespace" module.
17
- *
18
- * The "base-namespace" module contains base classes and utilities for implementing custom namespaces in the application.
19
- * Custom namespaces provide separate channels for communication between connected clients and the server, allowing for organized event handling within separate contexts.
20
- */
21
- export * from "./listeners/base-namespace";
@@ -1,38 +0,0 @@
1
- "use strict";
2
- // Import and re-export multiple modules related to jobs and listeners.
3
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
4
- if (k2 === undefined) k2 = k;
5
- var desc = Object.getOwnPropertyDescriptor(m, k);
6
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
7
- desc = { enumerable: true, get: function() { return m[k]; } };
8
- }
9
- Object.defineProperty(o, k2, desc);
10
- }) : (function(o, m, k, k2) {
11
- if (k2 === undefined) k2 = k;
12
- o[k2] = m[k];
13
- }));
14
- var __exportStar = (this && this.__exportStar) || function(m, exports) {
15
- for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
16
- };
17
- Object.defineProperty(exports, "__esModule", { value: true });
18
- /**
19
- * Re-exports all the contents from the "base-producers" module.
20
- *
21
- * The "base-producers" module contains base classes and utilities for implementing job producers in the application.
22
- * Job producers are responsible for generating and queuing jobs to be processed by job workers.
23
- */
24
- __exportStar(require("./jobs/base-producers"), exports);
25
- /**
26
- * Re-exports all the contents from the "base-worker" module.
27
- *
28
- * The "base-worker" module contains base classes and utilities for implementing job workers in the application.
29
- * Job workers are responsible for processing jobs generated by job producers and executing the required tasks.
30
- */
31
- __exportStar(require("./jobs/base-worker"), exports);
32
- /**
33
- * Re-exports all the contents from the "base-namespace" module.
34
- *
35
- * The "base-namespace" module contains base classes and utilities for implementing custom namespaces in the application.
36
- * Custom namespaces provide separate channels for communication between connected clients and the server, allowing for organized event handling within separate contexts.
37
- */
38
- __exportStar(require("./listeners/base-namespace"), exports);
@@ -1,21 +0,0 @@
1
- /**
2
- * Re-exports all the enums from the "enums" module.
3
- *
4
- * The "enums" module contains various enumerations used in the application.
5
- * Enumerations are used to define named constant values, such as status codes, subject names, or stream names.
6
- */
7
- export * from "./enums";
8
- /**
9
- * Re-exports all the base classes from the "base_classes" module.
10
- *
11
- * The "base_classes" module contains base classes and utilities that provide foundational functionality for different parts of the application.
12
- * This includes base classes for consumers, publishers, streams, etc., which can be extended to implement specific functionality.
13
- */
14
- export * from "./base_classes";
15
- /**
16
- * Re-exports all the functions related to reading directories from the "read-dir" module.
17
- *
18
- * The "read-dir" module contains utility functions to read and access files and directories in the application.
19
- * These functions are used for dynamic loading, configuration, and other file-related operations.
20
- */
21
- export * from "./read-dir";
@@ -1,38 +0,0 @@
1
- "use strict";
2
- // Import and re-export multiple modules for enums, base classes, and read-dir functionality.
3
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
4
- if (k2 === undefined) k2 = k;
5
- var desc = Object.getOwnPropertyDescriptor(m, k);
6
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
7
- desc = { enumerable: true, get: function() { return m[k]; } };
8
- }
9
- Object.defineProperty(o, k2, desc);
10
- }) : (function(o, m, k, k2) {
11
- if (k2 === undefined) k2 = k;
12
- o[k2] = m[k];
13
- }));
14
- var __exportStar = (this && this.__exportStar) || function(m, exports) {
15
- for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
16
- };
17
- Object.defineProperty(exports, "__esModule", { value: true });
18
- /**
19
- * Re-exports all the enums from the "enums" module.
20
- *
21
- * The "enums" module contains various enumerations used in the application.
22
- * Enumerations are used to define named constant values, such as status codes, subject names, or stream names.
23
- */
24
- __exportStar(require("./enums"), exports);
25
- /**
26
- * Re-exports all the base classes from the "base_classes" module.
27
- *
28
- * The "base_classes" module contains base classes and utilities that provide foundational functionality for different parts of the application.
29
- * This includes base classes for consumers, publishers, streams, etc., which can be extended to implement specific functionality.
30
- */
31
- __exportStar(require("./base_classes"), exports);
32
- /**
33
- * Re-exports all the functions related to reading directories from the "read-dir" module.
34
- *
35
- * The "read-dir" module contains utility functions to read and access files and directories in the application.
36
- * These functions are used for dynamic loading, configuration, and other file-related operations.
37
- */
38
- __exportStar(require("./read-dir"), exports);