projects
/
APKPM.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
20f7f35
)
store data in redis under table.name.login without timestamp
author
Dobrica Pavlinusic
<dpavlin@rot13.org>
Sun, 20 May 2012 19:54:03 +0000
(21:54 +0200)
committer
Dobrica Pavlinusic
<dpavlin@rot13.org>
Sun, 20 May 2012 19:54:03 +0000
(21:54 +0200)
lib/APKPM/Store.pm
patch
|
blob
|
history
diff --git
a/lib/APKPM/Store.pm
b/lib/APKPM/Store.pm
index
9e5ac67
..
bce29ac
100644
(file)
--- a/
lib/APKPM/Store.pm
+++ b/
lib/APKPM/Store.pm
@@
-64,7
+64,9
@@
order by
}
sub pg_insert {
- my ( $self, $table, $h ) = @_;
+ my ( $self, $base_table, $h ) = @_;
+
+ my $table = $base_table;
my @c;
@@
-109,7
+111,7
@@
sub pg_insert {
$h_lc->{ lc $_ } = $h->{$_} foreach keys %$h;
if ( my $username = $h->{username} ) {
- my $key = join('.', 'table', $table, $username);
+ my $key = join('.', 'table', $
base_
table, $username);
$self->redis->set( $key => $self->e_json($h) );
$self->redis->expire( $key => 15 * 60 ); # 15 min timeout
}