This is a fix tentative of issue #286
To be honest, it should really be scrutinized by a Vert.x savvy person because those ReadStream, Publisher, InboundBuffer, Channel interactions are definitely beyond my grasp.
Unit tests are still passing, my program no longer fails with OutOfMemoryError, but still... at the end of my program, the capacity of the InboundBuffer (792) is slightly above the specified batchSize (598). It is probably not a good omen.
Motivation:
This is a fix tentative of issue #286 To be honest, it should really be scrutinized by a Vert.x savvy person because those
ReadStream
,Publisher
,InboundBuffer
,Channel
interactions are definitely beyond my grasp.Unit tests are still passing, my program no longer fails with
OutOfMemoryError
, but still... at the end of my program, the capacity of theInboundBuffer
(792) is slightly above the specifiedbatchSize
(598). It is probably not a good omen.I also noticed this part of
MongoClientImpl
:Maybe we should call the
batchSize(int)
method of theFindPublisher
between thedoFind
and before thereturn new
?