Hitachi Vantara Pentaho Community Forums
Results 1 to 3 of 3

Thread: Control Resultset Configuration

  1. #1

    Smile Control Resultset Configuration

    There are some scenarios where the data retrieved will be very large. Currently the resultset is scrollable causing all of the data to eventually be stored in memory even with the 'live' resultset option.

    I would like more control over the resultset for scenarios where very large amounts of data is retrieved.

    It would be nice if similar to <live>true</live> there was a

    <resultset type="FORWARD_ONLY" concur="READ_ONLY" cursor="CLOSE" fetch="FORWARD" />

    This would need to be defined on the query not the component which is a little more difficult to implement.

    However, this would allow me to create reports without worrying about running out of memory. Or create reports that are sensitive to changes, or allow updates.

    I think this would be very beneficial and the default could remain the same as today.

  2. #2
    Join Date
    Mar 2003


    Well, for reports, anything that is not encapsulated in a way that repeated reads return the same value, will cause the report engine to go crazy.

    The report engine is a multi-pass engine - so we iterate the data at least three times: (1) compute the function values (2) pagination (3) printing. We also follow the premise to not copy data unless it is absolutely necessary (so that the engine's memory footprint stays small, which increases the overall scalability). So if a function's computed value changes between the pagination and printing steps, your whole layout will be messed up. If the data changes while we compute a global percentages based on a precomputed global sum, then you can just wait for the trouble to happen.

    So what ever you do: If you want to feed the report engine, then make the result insensitive to outside-changes by using a proper transactional encapsulation. If the result set is not scrollable, then the engine (or platform) will have to copy the data into memory anyway to produce something that we can iterate multiple times.
    Get the latest news and tips and tricks for Pentaho Reporting at the Pentaho Reporting Blog.

  3. #3

    Default Non Reporting Scenario

    I understand why the current setting is scrollable/read-only. I am saying I have business use cases that need large amounts of data and I cannot have my server crash because of out-of-memory errors.

    No report is generated in this scenario I actually just create a file on an ftp server for the caller to pickup.

    I have changed the code to forward only and it works very well. I can now produce several hundred MB files without consuming much memory.

    My feature request is to make this option available, not change how most reports are generated.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
Privacy Policy | Legal Notices | Safe Harbor Privacy Policy

Copyright © 2005 - 2019 Hitachi Vantara Corporation. All Rights Reserved.