[open-ils-commits] r15605 - trunk/Open-ILS/src/perlmods/OpenILS/WWW (miker)
svn at svn.open-ils.org
svn at svn.open-ils.org
Sat Feb 20 23:47:38 EST 2010
Author: miker
Date: 2010-02-20 23:47:35 -0500 (Sat, 20 Feb 2010)
New Revision: 15605
Modified:
trunk/Open-ILS/src/perlmods/OpenILS/WWW/SuperCat.pm
Log:
stream holdings xml to the client
Modified: trunk/Open-ILS/src/perlmods/OpenILS/WWW/SuperCat.pm
===================================================================
--- trunk/Open-ILS/src/perlmods/OpenILS/WWW/SuperCat.pm 2010-02-20 20:54:41 UTC (rev 15604)
+++ trunk/Open-ILS/src/perlmods/OpenILS/WWW/SuperCat.pm 2010-02-21 04:47:35 UTC (rev 15605)
@@ -540,7 +540,6 @@
my @params = ($id);
if ($base_format eq 'holdings_xml') {
- $method .= '.atomic';
push @params, $lib;
if ($format !~ /-full$/o) {
push @params, 1;
@@ -548,10 +547,8 @@
}
my $req = $supercat->request($method, at params);
- my $data = $req->gather(1);
+ my $data = $req->gather();
- $data = join('', @$data) if ($base_format eq 'holdings_xml');
-
if ($req->failed || !$data) {
print "Content-type: text/html; charset=utf-8\n\n";
$apache->custom_response( 404, <<" HTML");
@@ -570,6 +567,12 @@
print "Content-type: application/xml; charset=utf-8\n\n$data";
+ if ($base_format eq 'holdings_xml') {
+ while (my $c = $req->recv) {
+ print $c->content;
+ }
+ }
+
return Apache2::Const::OK;
}
More information about the open-ils-commits
mailing list