@@ -10,7 +10,6 @@ import { Monitor, MonitorOptions } from './monitor';
10
10
import { isTransactionCommand } from '../transactions' ;
11
11
import {
12
12
collationNotSupported ,
13
- debugOptions ,
14
13
makeStateMachine ,
15
14
maxWireVersion ,
16
15
Callback ,
@@ -56,34 +55,6 @@ import type { AutoEncrypter } from '../deps';
56
55
import type { ServerApi } from '../mongo_client' ;
57
56
import { TypedEventEmitter } from '../mongo_types' ;
58
57
59
- // Used for filtering out fields for logging
60
- const DEBUG_FIELDS = [
61
- 'reconnect' ,
62
- 'reconnectTries' ,
63
- 'reconnectInterval' ,
64
- 'emitError' ,
65
- 'cursorFactory' ,
66
- 'host' ,
67
- 'port' ,
68
- 'size' ,
69
- 'keepAlive' ,
70
- 'keepAliveInitialDelay' ,
71
- 'noDelay' ,
72
- 'connectionTimeout' ,
73
- 'checkServerIdentity' ,
74
- 'socketTimeoutMS' ,
75
- 'ssl' ,
76
- 'ca' ,
77
- 'crl' ,
78
- 'cert' ,
79
- 'key' ,
80
- 'rejectUnauthorized' ,
81
- 'promoteLongs' ,
82
- 'promoteValues' ,
83
- 'promoteBuffers' ,
84
- 'servername'
85
- ] ;
86
-
87
58
const stateTransition = makeStateMachine ( {
88
59
[ STATE_CLOSED ] : [ STATE_CLOSED , STATE_CONNECTING ] ,
89
60
[ STATE_CONNECTING ] : [ STATE_CONNECTING , STATE_CLOSING , STATE_CONNECTED , STATE_CLOSED ] ,
@@ -304,17 +275,6 @@ export class Server extends TypedEventEmitter<ServerEvents> {
304
275
// Clone the options
305
276
const finalOptions = Object . assign ( { } , options , { wireProtocolCommand : false } ) ;
306
277
307
- // Debug log
308
- if ( this . s . logger . isDebug ( ) ) {
309
- this . s . logger . debug (
310
- `executing command [${ JSON . stringify ( {
311
- ns,
312
- cmd,
313
- options : debugOptions ( DEBUG_FIELDS , options )
314
- } ) } ] against ${ this . name } `
315
- ) ;
316
- }
317
-
318
278
// error if collation not supported
319
279
if ( collationNotSupported ( this , cmd ) ) {
320
280
callback ( new MongoDriverError ( `server ${ this . name } does not support collation` ) ) ;
0 commit comments