DR-Tarantool

 view release on metacpan or  search on metacpan

st/Check/OneHash.pm  view on Meta::CPAN

use utf8;
use strict;
use warnings;

package Check::OneHash;
use AnyEvent;
use Coro;
use Coro::AnyEvent;
use DR::Tarantool ':constant';

use constant ITERATIONS => cfg 'check.onehash.iterations';

sub start {

    my $done_time = 0;
    my $total = 0;
    my @fields;
    my $total_errors = 0;
    
    while(1) {

st/Check/OneHash.pm  view on Meta::CPAN

        }

        @fields = ();
        
        my $period = now() - $started;

        $done_time += $period;
        $total += ITERATIONS;
        $total_errors += $errors;

        df '%d iterations in %3.3f seconds (%d errors)',
            $total,
            $done_time,
            $total_errors
        ;
        
        df "%d r/s, %3.5f s/r, %3.5f err/s",
            $total / $done_time,
            $done_time / $total,
            $total_errors / $done_time
        ;

st/Check/OneTree.pm  view on Meta::CPAN

use utf8;
use strict;
use warnings;

package Check::OneTree;
use AnyEvent;
use Coro;
use Coro::AnyEvent;
use DR::Tarantool ':constant';

use constant ITERATIONS => cfg 'check.onetree.iterations';

sub start {

    my $done_time = 0;
    my $total = 0;
    my @fields;
    my $total_errors = 0;
    
    while(1) {

st/Check/OneTree.pm  view on Meta::CPAN

        }

        @fields = ();
        
        my $period = now() - $started;

        $done_time += $period;
        $total += ITERATIONS;
        $total_errors += $errors;

        df '%d iterations in %3.3f seconds (%d errors)',
            $total,
            $done_time,
            $total_errors
        ;
        
        df "%d r/s, %3.5f s/r, %3.5f err/s",
            $total / $done_time,
            $done_time / $total,
            $total_errors / $done_time
        ;

st/Check/Order.pm  view on Meta::CPAN

use utf8;
use strict;
use warnings;

package Check::Order;

use constant ITERATIONS => cfg 'check.order.iterations';
use DR::Tarantool ':constant';

sub start {

    my $done_time = 0;
    my $total = 0;
    my $errors = 0;

    while(1) {

st/Check/Order.pm  view on Meta::CPAN

                    ),
                    'delete'
                );
        }

        my $period = now() - $started;
        $done_time += $period;
        $total += ITERATIONS;


        df "done %d iterations in %3.2f seconds (%d errors)",
            $total,
            $done_time,
            $errors
        ;


        df "%d r/s, %3.5f s/r, %3.5f errors/s",
            $total / $done_time,
            $done_time / $total,
            $errors / $done_time

st/Check/Ping.pm  view on Meta::CPAN

use utf8;
use strict;
use warnings;

package Check::Ping;

use constant ITERATIONS => cfg 'check.ping.iterations';

sub start {

    my $done_time = 0;
    my $total = 0;

    while(1) {

        my $started = now();
        for (my $i = 0; $i < ITERATIONS; $i++) {

st/stress.cfg  view on Meta::CPAN

# vim: set ft=perl :
{

    check => {
        onehash => {
            iterations  => 1000,
            verbose     => 1,
            enabled     => 1,
        },
        ping    => {
            iterations  => 5000,
            verbose     => 1,
            enabled     => 1,
        },
        onetree => {
            iterations  => 1000,
            verbose     => 1,
            enabled     => 1,
        },
        order => {
            iterations  => 1000,
            verbose     => 1,
            enabled     => 1,
        },
        xlogcleanup => {
            verbose         => 1,
            keep_xlogs      => 10,
            keep_snapshots  => 2,
            enabled         => 1,
        },
    },



( run in 1.432 second using v1.01-cache-2.11-cpan-71847e10f99 )