File tree Expand file tree Collapse file tree 1 file changed +16
-16
lines changed Expand file tree Collapse file tree 1 file changed +16
-16
lines changed Original file line number Diff line number Diff line change @@ -182,6 +182,22 @@ class ConnectionPool extends EventEmitter {
182
182
} ) ;
183
183
}
184
184
185
+ get address ( ) {
186
+ return `${ this . options . host } :${ this . options . port } ` ;
187
+ }
188
+
189
+ get generation ( ) {
190
+ return this [ kGeneration ] ;
191
+ }
192
+
193
+ get totalConnectionCount ( ) {
194
+ return this [ kConnections ] . length + ( this . options . maxPoolSize - this [ kPermits ] ) ;
195
+ }
196
+
197
+ get availableConnectionCount ( ) {
198
+ return this [ kConnections ] . length ;
199
+ }
200
+
185
201
/**
186
202
* Check a connection out of this pool. The connection will continue to be tracked, but no reference to it
187
203
* will be held by the pool. This means that if a connection is checked out it MUST be checked back in or
@@ -343,22 +359,6 @@ class ConnectionPool extends EventEmitter {
343
359
} ) ;
344
360
} ) ;
345
361
}
346
-
347
- get generation ( ) {
348
- return this [ kGeneration ] ;
349
- }
350
-
351
- get totalConnectionCount ( ) {
352
- return this [ kConnections ] . length + ( this . options . maxPoolSize - this [ kPermits ] ) ;
353
- }
354
-
355
- get availableConnectionCount ( ) {
356
- return this [ kConnections ] . length ;
357
- }
358
-
359
- get address ( ) {
360
- return `${ this . options . host } :${ this . options . port } ` ;
361
- }
362
362
}
363
363
364
364
function ensureMinPoolSize ( pool ) {
You can’t perform that action at this time.
0 commit comments