Skip to content

Commit

Permalink
Use STH.pm for number type correction.
Browse files Browse the repository at this point in the history
  • Loading branch information
Chih-Hao Huang committed Feb 24, 2012
1 parent bcb83c4 commit 0702117
Showing 1 changed file with 13 additions and 12 deletions.
25 changes: 13 additions & 12 deletions perl_lib/PHEDEX/Web/API/BlockReplicas.pm
Original file line number Diff line number Diff line change
Expand Up @@ -136,18 +136,18 @@ my $map = {
_KEY => 'BLOCK_ID',
id => 'BLOCK_ID',
name => 'BLOCK_NAME',
files => ['BLOCK_FILES', 'int'],
bytes => ['BLOCK_BYTES', 'int'],
files => 'BLOCK_FILES',
bytes => 'BLOCK_BYTES',
is_open => 'IS_OPEN',
replica => {
_KEY => 'NODE_ID',
node_id => 'NODE_ID',
node => 'NODE_NAME',
se => 'SE_NAME',
files => ['REPLICA_FILES', 'int'],
bytes => ['REPLICA_BYTES', 'int'],
time_create => ['REPLICA_CREATE', 'int'],
time_update => ['REPLICA_UPDATE', 'int'],
files => 'REPLICA_FILES',
bytes => 'REPLICA_BYTES',
time_create => 'REPLICA_CREATE',
time_update => 'REPLICA_UPDATE',
complete => 'REPLICA_COMPLETE',
subscribed => 'SUBSCRIBED',
custodial => 'IS_CUSTODIAL',
Expand All @@ -164,18 +164,18 @@ my $map_d = {
_KEY => 'BLOCK_ID',
id => 'BLOCK_ID',
name => 'BLOCK_NAME',
files => ['BLOCK_FILES', 'int'],
bytes => ['BLOCK_BYTES', 'int'],
files => 'BLOCK_FILES',
bytes => 'BLOCK_BYTES',
is_open => 'IS_OPEN',
replica => {
_KEY => 'NODE_ID',
node_id => 'NODE_ID',
node => 'NODE_NAME',
se => 'SE_NAME',
files => ['REPLICA_FILES', 'int'],
bytes => ['REPLICA_BYTES', 'int'],
time_create => ['REPLICA_CREATE', 'int'],
time_update => ['REPLICA_UPDATE', 'int'],
files => 'REPLICA_FILES',
bytes => 'REPLICA_BYTES',
time_create => 'REPLICA_CREATE',
time_update => 'REPLICA_UPDATE',
complete => 'REPLICA_COMPLETE',
subscribed => 'SUBSCRIBED',
custodial => 'IS_CUSTODIAL',
Expand Down Expand Up @@ -301,6 +301,7 @@ sub spool
my $r;

$sth = PHEDEX::Web::Spooler->new(PHEDEX::Web::SQL::getBlockReplicas($core, %p), $limit, @keys) if !$sth;

$r = $sth->spool();
if ($r)
{
Expand Down

0 comments on commit 0702117

Please sign in to comment.