This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "main Koha release repository".

The branch, master has been updated
       via  6c90c6f7d9e0f04ce148b723fc3a4828f03e9079 (commit)
       via  f2b27975679e64722f06b175e759801227a313fc (commit)
       via  bca4453c50d8b5b1d3c7029ded2b522a9a2bf868 (commit)
       via  7958e7f3f9b4275cd8da0ed2e04dfbc90d863a60 (commit)
       via  79e15278f718768fa082b7b3d7b48e6adde164da (commit)
      from  8d8d002eecee3ca78bf44c64b20bf2b91ea8a201 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 6c90c6f7d9e0f04ce148b723fc3a4828f03e9079
Author: Tomas Cohen Arazi <tomasco...@theke.io>
Date:   Wed Sep 25 10:44:03 2019 -0300

    Bug 23624: (QA follow-up) Test error cases
    
    Signed-off-by: Tomas Cohen Arazi <tomasco...@theke.io>
    Signed-off-by: Martin Renvoize <martin.renvo...@ptfs-europe.com>

commit f2b27975679e64722f06b175e759801227a313fc
Author: Kyle M Hall <k...@bywatersolutions.com>
Date:   Fri Sep 20 07:14:34 2019 -0400

    Bug 23624: (QA follow-up) Don't fetch the count unless the query was 
successful
    
    Signed-off-by: Liz Rea <wizzy...@gmail.com>
    Signed-off-by: Tomas Cohen Arazi <tomasco...@theke.io>
    Signed-off-by: Martin Renvoize <martin.renvo...@ptfs-europe.com>

commit bca4453c50d8b5b1d3c7029ded2b522a9a2bf868
Author: Tomas Cohen Arazi <tomasco...@theke.io>
Date:   Thu Sep 19 11:13:28 2019 -0300

    Bug 23624: (QA follow-up) Optimize even more
    
    This patch makes counting the results have no memory footprint by
    leveraging on the DB to count the rows.
    
    To test:
    - Without this path, run:
      $ kshell
     k$ prove t/db_dependent/Reports/Guided.t
    => SUCCESS: Tests pass
    - Apply this patch
    - Run:
     k$ prove t/db_dependent/Reports/Guided.t
    => SUCCESS: Tests still pass!
    
    Signed-off-by: Tomas Cohen Arazi <tomasco...@theke.io>
    Signed-off-by: Liz Rea <wizzy...@gmail.com>
    Signed-off-by: Tomas Cohen Arazi <tomasco...@theke.io>
    Signed-off-by: Martin Renvoize <martin.renvo...@ptfs-europe.com>

commit 7958e7f3f9b4275cd8da0ed2e04dfbc90d863a60
Author: Tomas Cohen Arazi <tomasco...@theke.io>
Date:   Thu Sep 19 10:50:46 2019 -0300

    Bug 23624: Unit tests
    
    Signed-off-by: Tomas Cohen Arazi <tomasco...@theke.io>
    Signed-off-by: Liz Rea <wizzy...@gmail.com>
    Signed-off-by: Tomas Cohen Arazi <tomasco...@theke.io>
    Signed-off-by: Martin Renvoize <martin.renvo...@ptfs-europe.com>

commit 79e15278f718768fa082b7b3d7b48e6adde164da
Author: Paul Hoffman <p...@flo.org>
Date:   Tue Sep 17 13:00:03 2019 -0400

    Bug 23624: Count rows in report without (potentially) consuming all memory
    
    C4::Reports::Guided::nb_rows (called by get_prepped_report in 
reports/guided_reports.pl) uses DBI::fetchall_arrayref to retrieve all rows at 
once; counts them; and then discards the rows and returns the count.  This has 
the potential, if the number of rows is very large, to exhaust all available 
memory.
    
    (Other code in guided_reports.pl has the same potential effect, but because 
the solution to that is much less straightforward it will be addressed in a 
separate bug report.)
    
    This patch uses the second ($max_rows) parameter to DBI::fetchall_arrayref 
to retrieve a smaller number (1,000) of rows at a time, looping until all 
results have been retrieved.  This will only use as much memory as the maximum 
amount used by a single call to DBI::fetchall_arrayref.
    
    Test Plan:
    1) Create a report the will generate a huge number of results
    2) Run the report, watch your memory usage spike
    3) Apply this patch
    4) Restart all the things!
    5) Run the report again, note your memory usage is much lower
    
    Signed-off-by: Kyle M Hall <k...@bywatersolutions.com>
    Signed-off-by: Tomas Cohen Arazi <tomasco...@theke.io>
    Signed-off-by: Liz Rea <wizzy...@gmail.com>
    Signed-off-by: Tomas Cohen Arazi <tomasco...@theke.io>
    Signed-off-by: Martin Renvoize <martin.renvo...@ptfs-europe.com>

-----------------------------------------------------------------------

Summary of changes:
 C4/Reports/Guided.pm            |   22 +++++++++++++++++++---
 t/db_dependent/Reports/Guided.t |   36 +++++++++++++++++++++++++++++++++++-
 2 files changed, 54 insertions(+), 4 deletions(-)


hooks/post-receive
-- 
main Koha release repository
_______________________________________________
koha-commits mailing list
koha-commits@lists.koha-community.org
https://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-commits

Reply via email to