Changeset 9523

Show
Ignore:
Timestamp:
05/07/08 16:39:30 (2 months ago)
Author:
erickson
Message:

added content handler no longer tries to pull from the cache when the plugin cannot return data for that type of call anyway. removed Amazon stub methods because they 1. should have returned explicit undef, but more importantly because having them around means extra calls to memcache

Location:
branches/rel_1_2_2/Open-ILS/src/perlmods/OpenILS/WWW
Files:
2 modified

Legend:

Unmodified
Added
Removed
  • branches/rel_1_2_2/Open-ILS/src/perlmods/OpenILS/WWW/AddedContent.pm

    r8078 r9523  
    8787 
    8888    return Apache2::Const::NOT_FOUND unless $handler and $type and $format and $key; 
    89     return $res if defined($res = $AC->serve_from_cache($type, $format, $key)); 
    90     return Apache2::Const::NOT_FOUND unless $AC->lookups_enabled; 
    9189 
    9290    my $err; 
     
    9593 
    9694    return Apache2::Const::NOT_FOUND unless $handler->can($method); 
     95    return $res if defined($res = $AC->serve_from_cache($type, $format, $key)); 
     96    return Apache2::Const::NOT_FOUND unless $AC->lookups_enabled; 
    9797 
    9898    try { 
  • branches/rel_1_2_2/Open-ILS/src/perlmods/OpenILS/WWW/AddedContent/Amazon.pm

    r8077 r9523  
    4848# -------------------------------------------------------------------------- 
    4949 
    50 sub toc_html { 
    51     my( $self, $key ) = @_; 
    52 } 
    53  
    54 sub toc_xml { 
    55     my( $self, $key ) = @_; 
    56 } 
    57  
    58 sub toc_json { 
    59     my( $self, $key ) = @_; 
    60 } 
    61  
    62 # -------------------------------------------------------------------------- 
    63  
    64 sub anotes_html { 
    65     my( $self, $key ) = @_; 
    66 } 
    67  
    68 sub anotes_xml { 
    69     my( $self, $key ) = @_; 
    70 } 
    71  
    72 sub anotes_json { 
    73     my( $self, $key ) = @_; 
    74 } 
    75  
    76  
    77 # -------------------------------------------------------------------------- 
    78  
    79 sub excerpt_html { 
    80     my( $self, $key ) = @_; 
    81 } 
    82  
    83 sub excerpt_xml { 
    84     my( $self, $key ) = @_; 
    85 } 
    86  
    87 sub excerpt_json { 
    88     my( $self, $key ) = @_; 
    89 } 
    90  
    91 # -------------------------------------------------------------------------- 
    92  
    93 sub reviews_html { 
    94     my( $self, $key ) = @_; 
    95 } 
    96  
    97 # we have to aggregate the reviews 
    98 sub reviews_xml { 
    99     my( $self, $key ) = @_; 
    100 } 
    101  
    102  
    103 sub reviews_json { 
    104     my( $self, $key ) = @_; 
    105 } 
    106  
    107 # -------------------------------------------------------------------------- 
    108  
    10950sub send_img { 
    11051    my($self, $response) = @_;