Changeset 17649
- Timestamp:
- May 12, 2008, 5:12:52 PM (18 years ago)
- Location:
- trunk/DataStore
- Files:
-
- 7 edited
-
Changes (modified) (1 diff)
-
lib/DataStore.pm (modified) (2 diffs)
-
scripts/dsfilesetls (modified) (3 diffs)
-
scripts/dsget (modified) (2 diffs)
-
scripts/dsleech (modified) (2 diffs)
-
scripts/dsproductls (modified) (2 diffs)
-
scripts/dsrootls (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/DataStore/Changes
r17638 r17649 1 1 Revision history for Perl module DataStore 2 3 0.08 4 - change ds*ls utilties to always return the HTTP status code - 300 as the 5 exit status 2 6 3 7 0.07 Mon May 12 12:04:24 HST 2008 -
trunk/DataStore/lib/DataStore.pm
r15022 r17649 1 1 # Copyright (C) 2006 Joshua Hoblitt 2 2 # 3 # $Id: DataStore.pm,v 1.1 0 2007-09-25 23:52:46jhoblitt Exp $3 # $Id: DataStore.pm,v 1.11 2008-05-13 03:12:52 jhoblitt Exp $ 4 4 5 5 package DataStore; … … 9 9 10 10 use vars qw($VERSION); 11 $VERSION = '0.0 7';11 $VERSION = '0.08'; 12 12 13 13 =pod -
trunk/DataStore/scripts/dsfilesetls
r17637 r17649 3 3 # Copyright (C) 2006-2008 Joshua Hoblitt 4 4 # 5 # $Id: dsfilesetls,v 1. 7 2008-05-12 22:04:53jhoblitt Exp $5 # $Id: dsfilesetls,v 1.8 2008-05-13 03:12:52 jhoblitt Exp $ 6 6 7 7 use strict; … … 19 19 20 20 GetOptions( 21 'uri|u=s' => \$uri,21 'uri|u=s' => \$uri, 22 22 'timeout|t' => \$timeout, 23 23 ) or pod2usage( 2 ); … … 36 36 ); 37 37 38 die "request failed" unless defined $response; 39 die "request failed: ", $response->status_line unless $response->is_success; 38 unless (defined $response or $response->is_success) { 39 warn "request failed: ", $response->status_line; 40 exit($response->code - 300); 41 } 40 42 41 43 # file retreival succeed -
trunk/DataStore/scripts/dsget
r17637 r17649 3 3 # Copyright (C) 2006-2008 Joshua Hoblitt 4 4 # 5 # $Id: dsget,v 1.2 4 2008-05-12 22:04:53jhoblitt Exp $5 # $Id: dsget,v 1.25 2008-05-13 03:12:52 jhoblitt Exp $ 6 6 7 7 use strict; … … 130 130 ); 131 131 132 die "request failed" unless defined $response; 133 unless ( $response->is_success) {132 133 unless (defined $response or $response->is_success) { 134 134 warn "request failed: ", $response->status_line; 135 135 exit($response->code - 300); 136 136 } 137 137 138 die "checksum failed" unless $response->data; 138 139 -
trunk/DataStore/scripts/dsleech
r17637 r17649 3 3 # Copyright (C) 2006-2008 Joshua Hoblitt 4 4 # 5 # $Id: dsleech,v 1.1 0 2008-05-12 22:04:53jhoblitt Exp $5 # $Id: dsleech,v 1.11 2008-05-13 03:12:52 jhoblitt Exp $ 6 6 7 7 use strict; … … 67 67 ); 68 68 69 unless (defined $response->is_success) { 70 die "request failed: ", $response->status_line; 69 unless (defined $response or $response->is_success) { 70 warn "request failed: ", $response->status_line; 71 exit($response->code - 300); 71 72 } 72 73 -
trunk/DataStore/scripts/dsproductls
r17637 r17649 3 3 # Copyright (C) 2006-2008 Joshua Hoblitt 4 4 # 5 # $Id: dsproductls,v 1. 4 2008-05-12 22:04:53jhoblitt Exp $5 # $Id: dsproductls,v 1.5 2008-05-13 03:12:52 jhoblitt Exp $ 6 6 7 7 use strict; … … 43 43 ); 44 44 45 die "request failed" unless defined $response; 46 die "request failed: ", $response->status_line unless $response->is_success; 45 unless (defined $response or $response->is_success) { 46 warn "request failed: ", $response->status_line; 47 exit($response->code - 300); 48 } 47 49 48 50 # file retreival succeed -
trunk/DataStore/scripts/dsrootls
r17637 r17649 3 3 # Copyright (C) 2006-2008 Joshua Hoblitt 4 4 # 5 # $Id: dsrootls,v 1. 2 2008-05-12 22:04:53jhoblitt Exp $5 # $Id: dsrootls,v 1.3 2008-05-13 03:12:52 jhoblitt Exp $ 6 6 7 7 use strict; … … 40 40 ); 41 41 42 die "request failed" unless defined $response; 43 die "request failed: ", $response->status_line unless $response->is_success; 42 unless (defined $response or $response->is_success) { 43 warn "request failed: ", $response->status_line; 44 exit($response->code - 300); 45 } 44 46 45 47 # file retreival succeed
Note:
See TracChangeset
for help on using the changeset viewer.
