@@ -196,11 +196,9 @@ public BatchCursor<T> execute(final ReadBinding binding) {
196
196
return withConnection (binding , new CallableWithConnectionAndSource <BatchCursor <T >>() {
197
197
@ Override
198
198
public BatchCursor <T > call (final ConnectionSource source , final Connection connection ) {
199
- return executeWrappedCommandProtocol (namespace .getDatabaseName (), asCommandDocument (connection .getDescription ()),
200
- CommandResultDocumentCodec .create (decoder ,
201
- getFieldNameWithResults (connection
202
- .getDescription ())),
203
- connection , binding .getReadPreference (), transformer (source , connection ));
199
+ return executeWrappedCommandProtocol (binding , namespace .getDatabaseName (), asCommandDocument (connection .getDescription ()),
200
+ CommandResultDocumentCodec .create (decoder , getFieldNameWithResults (connection .getDescription ())),
201
+ connection , transformer (source , connection ));
204
202
}
205
203
});
206
204
}
@@ -213,12 +211,11 @@ public void call(final AsyncConnectionSource source, final AsyncConnection conne
213
211
if (t != null ) {
214
212
errorHandlingCallback (callback ).onResult (null , t );
215
213
} else {
216
- executeWrappedCommandProtocolAsync (namespace .getDatabaseName (), asCommandDocument (connection .getDescription ()),
217
- CommandResultDocumentCodec .create (decoder ,
218
- getFieldNameWithResults (connection
219
- .getDescription ())),
220
- connection , binding .getReadPreference (), asyncTransformer (source , connection ),
221
- releasingCallback (errorHandlingCallback (callback ), source , connection ));
214
+ executeWrappedCommandProtocolAsync (binding , namespace .getDatabaseName (),
215
+ asCommandDocument (connection .getDescription ()),
216
+ CommandResultDocumentCodec .create (decoder , getFieldNameWithResults (connection .getDescription ())),
217
+ connection , asyncTransformer (source , connection ),
218
+ releasingCallback (errorHandlingCallback (callback ), source , connection ));
222
219
}
223
220
}
224
221
});
0 commit comments