@konplit-services/common 1.0.318 → 1.0.320

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.
@@ -307,6 +307,7 @@ declare class AppConfigs {
307
307
  invoice_url: string;
308
308
  noReplyEmail: string;
309
309
  emailName: string;
310
+ checkoutUrl: string;
310
311
  };
311
312
  getOpayDetails(): Opay;
312
313
  getNIBSSDetails(): NIBSS;
@@ -522,6 +522,9 @@ class AppConfigs {
522
522
  if (!this.env.VALUEPAY_EMAIL_NAME) {
523
523
  throw new Error("VALUEPAY_NO_REPLY_EMAIL is required");
524
524
  }
525
+ if (!this.env.CHECKOUT_URL) {
526
+ throw new Error("CHECKOUT_URL is required");
527
+ }
525
528
  return {
526
529
  visa_redirect_url: this.env.VALUEPAY_VISA_REDIRECT_URL,
527
530
  visa_redirect_fail_url: this.env.VALUEPAY_VISA_FAIL_REDIRECT_URL,
@@ -533,6 +536,7 @@ class AppConfigs {
533
536
  invoice_url: this.env.VALUEPAY_INVOICE_URL,
534
537
  noReplyEmail: this.env.VALUEPAY_NO_REPLY_EMAIL,
535
538
  emailName: this.env.VALUEPAY_EMAIL_NAME,
539
+ checkoutUrl: this.env.CHECKOUT_URL,
536
540
  };
537
541
  }
538
542
  getOpayDetails() {
@@ -48,7 +48,7 @@ class Listener {
48
48
  * Acknowledgment wait time of 5 seconds before retrying.
49
49
  * @protected
50
50
  */
51
- this.ackWait = (0, nats_1.nanos)(5 * 1000); // acknowledge time of 5 seconds before retry
51
+ this.ackWait = (0, nats_1.nanos)(5 * 60 * 1000); // acknowledge time of 5 minutes before retry
52
52
  this.client = client;
53
53
  this.nc = nc;
54
54
  }
@@ -188,7 +188,7 @@ class Listener {
188
188
  filter_subject: subject,
189
189
  deliver_policy: nats_1.DeliverPolicy.All,
190
190
  ack_wait: this.ackWait,
191
- max_deliver: 20,
191
+ max_deliver: 576, //5 minutes * 576 equals two days assuming the system is down
192
192
  };
193
193
  yield jsm.consumers.add(streamName, consumerConfig);
194
194
  console.log(`Consumer '${durableName}' created`);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@konplit-services/common",
3
- "version": "1.0.318",
3
+ "version": "1.0.320",
4
4
  "description": "",
5
5
  "main": "./build/index.js",
6
6
  "types": "./build/index.d.ts",