@dnlycticket/common 1.0.11 → 1.0.13
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.
|
@@ -8,7 +8,7 @@ export declare abstract class Listener<T extends Event> {
|
|
|
8
8
|
abstract subject: T['subject'];
|
|
9
9
|
abstract queueGroupName: string;
|
|
10
10
|
abstract onMessage(data: T['data'], msg: Message): void;
|
|
11
|
-
|
|
11
|
+
protected client: Stan;
|
|
12
12
|
protected ackWait: number;
|
|
13
13
|
constructor(client: Stan);
|
|
14
14
|
subscriptionOptions(): import("node-nats-streaming").SubscriptionOptions;
|
|
@@ -14,6 +14,7 @@ var Listener = /** @class */ (function () {
|
|
|
14
14
|
.setDeliverAllAvailable()
|
|
15
15
|
// 手动告诉nats完成,否则自动完成
|
|
16
16
|
.setManualAckMode(true)
|
|
17
|
+
// NATS 服务器等待客户端确认(ACK)消息的超时时间,超过这个时间会马上在尝试发送
|
|
17
18
|
.setAckWait(this.ackWait)
|
|
18
19
|
// 获取收到DurableName的断线钱积压的消息
|
|
19
20
|
.setDurableName(this.queueGroupName);
|