@rufous/aem 1.1.90 → 1.1.92

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.
@@ -10,6 +10,7 @@ export declare abstract class Listener<T extends Event> {
10
10
  abstract onMessage(data: T['data'], msg: Message): void;
11
11
  protected client: Stan;
12
12
  protected ackWait: number;
13
+ protected maxInFlight: number;
13
14
  constructor(client: Stan);
14
15
  subscriptionOptions(): import("node-nats-streaming").SubscriptionOptions;
15
16
  listen(): void;
@@ -3,7 +3,8 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.Listener = void 0;
4
4
  var Listener = /** @class */ (function () {
5
5
  function Listener(client) {
6
- this.ackWait = 5 * 1000;
6
+ this.ackWait = 30 * 1000;
7
+ this.maxInFlight = 1;
7
8
  this.client = client;
8
9
  }
9
10
  Listener.prototype.subscriptionOptions = function () {
@@ -12,6 +13,7 @@ var Listener = /** @class */ (function () {
12
13
  .setDeliverAllAvailable()
13
14
  .setManualAckMode(true)
14
15
  .setAckWait(this.ackWait)
16
+ .setMaxInFlight(this.maxInFlight)
15
17
  .setDurableName(this.queueGroupName);
16
18
  };
17
19
  Listener.prototype.listen = function () {
@@ -22,6 +24,15 @@ var Listener = /** @class */ (function () {
22
24
  var parsedData = _this.parseMessage(msg);
23
25
  _this.onMessage(parsedData, msg);
24
26
  });
27
+ subscription.on('error', function (err) {
28
+ console.error("Subscription error on ".concat(_this.subject, " / ").concat(_this.queueGroupName, ":"), err);
29
+ });
30
+ subscription.on('unsubscribed', function () {
31
+ console.log("Unsubscribed from ".concat(_this.subject, " / ").concat(_this.queueGroupName));
32
+ });
33
+ subscription.on('ready', function () {
34
+ console.log("Subscription ready: ".concat(_this.subject, " / ").concat(_this.queueGroupName));
35
+ });
25
36
  };
26
37
  Listener.prototype.parseMessage = function (msg) {
27
38
  var data = msg.getData();
@@ -3,5 +3,6 @@ export interface CandidateBatchProfilesEvent {
3
3
  subject: Subjects.CandidateBatchProfiles;
4
4
  data: {
5
5
  startTime: string;
6
+ id: string;
6
7
  };
7
8
  }
@@ -22,5 +22,6 @@ export interface CompanyInfoCreatedEvent {
22
22
  subscriptionDiscount?: number;
23
23
  subscriptionDiscountStartDate?: Date;
24
24
  subscriptionDiscountEndDate?: Date;
25
+ status?: string;
25
26
  };
26
27
  }
@@ -14,5 +14,6 @@ export interface PartnerInfoCreatedEvent {
14
14
  subscriptionDiscount?: number;
15
15
  subscriptionDiscountStartDate?: Date;
16
16
  subscriptionDiscountEndDate?: Date;
17
+ status?: string;
17
18
  };
18
19
  }
@@ -46,6 +46,9 @@ export declare enum EmailTemplate {
46
46
  CompanyEndContractEmail = "company-end-contract-email",
47
47
  EmployeePayslipUploadEmail = "employee-payslip-upload-email",
48
48
  EmployeeDocumentUploadEmail = "employee-document-upload-email",
49
+ CandidateTimesheetSubmitedEmail = "candidate-timesheet-submited-email",
50
+ CandidateTimesheetApprovedEmail = "candidate-timesheet-approved-email",
51
+ CandidateTimesheetRejectedEmail = "candidate-timesheet-rejected-email",
49
52
  WorkItemCreatedEmail = "work-item-created-email",
50
53
  WorkItemArchiveEmail = "work-item-archive-email",
51
54
  WorkItemFileUploadEmail = "work-item-file-upload-email",
@@ -50,6 +50,9 @@ var EmailTemplate;
50
50
  EmailTemplate["CompanyEndContractEmail"] = "company-end-contract-email";
51
51
  EmailTemplate["EmployeePayslipUploadEmail"] = "employee-payslip-upload-email";
52
52
  EmailTemplate["EmployeeDocumentUploadEmail"] = "employee-document-upload-email";
53
+ EmailTemplate["CandidateTimesheetSubmitedEmail"] = "candidate-timesheet-submited-email";
54
+ EmailTemplate["CandidateTimesheetApprovedEmail"] = "candidate-timesheet-approved-email";
55
+ EmailTemplate["CandidateTimesheetRejectedEmail"] = "candidate-timesheet-rejected-email";
53
56
  EmailTemplate["WorkItemCreatedEmail"] = "work-item-created-email";
54
57
  EmailTemplate["WorkItemArchiveEmail"] = "work-item-archive-email";
55
58
  EmailTemplate["WorkItemFileUploadEmail"] = "work-item-file-upload-email";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rufous/aem",
3
- "version": "1.1.90",
3
+ "version": "1.1.92",
4
4
  "main": "./build/index.js",
5
5
  "types": "./build/index.d.ts",
6
6
  "files": [