You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The automatic behaviour for drivers such as MySql is to read all the records of the resultset into memory. For very large resultsets this is undesirable and will blow memory client side. One way to control this is to manipulate the jdbc Statement object see this SO post
Eg statement.fetchSize = Integer.MIN_VALUE will give a hint to the driver to emit one row at a time.
So you would end up with code that is equivalent to this hard coded example
I would normally pick this up but I am a bit snowed under ATM.
Actually as readOn returns a ZStream maybe we can get away with just hard coding the above for now for a quick win? - I can certainly create a PR for this simple defaulting.
The text was updated successfully, but these errors were encountered:
The automatic behaviour for drivers such as MySql is to read all the records of the resultset into memory. For very large resultsets this is undesirable and will blow memory client side. One way to control this is to manipulate the jdbc
Statement
object see this SO postEg
statement.fetchSize = Integer.MIN_VALUE
will give a hint to the driver to emit one row at a time.So you would end up with code that is equivalent to this hard coded example
I would normally pick this up but I am a bit snowed under ATM.
Actually as
readOn
returns aZStream
maybe we can get away with just hard coding the above for now for a quick win? - I can certainly create a PR for this simple defaulting.The text was updated successfully, but these errors were encountered: