[Koha-bugs] [Bug 16715] Koha::Cache - Use Sereal for serialization

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Sun Jun 12 10:10:15 CEST 2016


https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=16715

--- Comment #2 from Jonathan Druart <jonathan.druart at bugs.koha-community.org> ---
% more t.pl
use Koha::Cache;
my $t; 
for my $i ( 1 .. 3 ) { 
    for my $j ( 1 .. 100000 ) { 
        $t->{$i}{$j} = "$i$j";
    }   
}
for ( 1 .. 10 ) { 
    my $cache = Koha::Cache->get_instance;
    $cache->set_in_cache( 'my_t', $t );
    $cache->get_from_cache( $t );
}

% git checkout master
% time perl t.pl
perl t.pl  4.76s user 0.11s system 100% cpu 4.875 total

% git checkout bug_16166 ( Bug 16166: Improve L1 cache performance and safety +
 Bug 16166: Fix t/Cache.t tests )
% time perl t.pl
perl t.pl  2.28s user 0.14s system 100% cpu 2.423 total

% git checkout bug_16715 ( Bug 16166: Proposed followup to use Sereal for
serialization )
% time perl t.pl
perl t.pl  1.75s user 0.05s system 99% cpu 1.803 total

Note that I did not manage to prove the gain using Koha, I have tried an
intranet search with 100 results (xslt) and the execution time is always
between 13s and 13.5s. I did not notice a significant gain.

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list