MCPcopy
hub / github.com/nestjs/nest / handleClose

Method handleClose

packages/microservices/server/server-tcp.ts:136–150  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

134 }
135
136 public handleClose(): undefined | number | NodeJS.Timer {
137 if (
138 this.isManuallyTerminated ||
139 !this.getOptionsProp(this.options, 'retryAttempts') ||
140 this.retryAttemptsCount >=
141 this.getOptionsProp(this.options, 'retryAttempts', 0)
142 ) {
143 return undefined;
144 }
145 ++this.retryAttemptsCount;
146 return setTimeout(
147 () => this.server.listen(this.port, this.host),
148 this.getOptionsProp(this.options, 'retryDelay', 0),
149 );
150 }
151
152 public unwrap<T>(): T {
153 if (!this.server) {

Callers 1

registerCloseListenerMethod · 0.95

Calls 2

listenMethod · 0.65
setTimeoutFunction · 0.50

Tested by

no test coverage detected