DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT <http://nagoya.apache.org/bugzilla/show_bug.cgi?id=16903>. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND INSERTED IN THE BUG DATABASE.
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=16903 No caching if serializer buffer-size < content length ------- Additional Comments From [EMAIL PROTECTED] 2003-02-09 10:38 ------- Found some time for preparing a patch. Note that these are diffs against the cocoon_2_0_3_branch. Basically what I did was change CachedStreamObject so that it is constructed with a CachingOutputStream instead of a byte array and changed its getResponse method to get the bytes from that stream on its first call. The other diff is for CachingStreamPipeline accordingly this change. Please review and apply. cvs diff CachedStreamObject.java (in directory D:\apache\xml\xml-cocoon203 \src\java\org\apache\cocoon\caching\) Index: CachedStreamObject.java =================================================================== RCS file: /home/cvspublic/xml- cocoon2/src/java/org/apache/cocoon/caching/Attic/CachedStreamObject.java,v retrieving revision 1.6.2.1 diff -r1.6.2.1 CachedStreamObject.java 53a54 > import org.apache.cocoon.caching.CachingOutputStream; 63a65 > private CachingOutputStream outputStream; 74c76 < byte[] response) { --- > CachingOutputStream outputStream) { 76c78 < this.response = response; --- > this.outputStream = outputStream; 104a107,110 > if (this.response == null) { > response = outputStream.getContent(); > outputStream = null; > } cvs diff CachingStreamPipeline.java (in directory D:\apache\xml\xml-cocoon203 \src\java\org\apache\cocoon\components\pipeline\) Index: CachingStreamPipeline.java =================================================================== RCS file: /home/cvspublic/xml- cocoon2/src/java/org/apache/cocoon/components/pipeline/Attic/CachingStreamPipeli ne.java,v retrieving revision 1.8.2.4 diff -r1.8.2.4 CachingStreamPipeline.java 263c263 < ((CachingOutputStream)outputStream).getContent ())); --- > (CachingOutputStream)outputStream)); 417d416 < byte[] bytes = ((CachingOutputStream) outputStream).getContent(); 419c418 < new CachedStreamObject(validityObjects, bytes)); --- > new CachedStreamObject(validityObjects, (CachingOutputStream)outputStream)); --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]