ns qw(catfile tmpdir);
use Mojo::Util qw(slurp spurt steady_time);
use Mojo::JSON qw(encode_json decode_json);
has initialized => sub { 0 };
has qw(file);
use constant DEBUG =>
) {
spurt(encode_json($hash), $state->file);
$state->_unlock($fh);
return $hash;
}
elsif (-f $state->file) {
my $ret = decode_json(slurp($state->file));
use File::Spec::Functions qw(catfile tmpdir);
use IO::Handle;
use Mojo::JSON qw(encode_json decode_json);
use POSIX qw(:sys_wait_h);
use Time::HiRes qw(usleep);
use Mojo::Util