Author: remy.maucherat(a)jboss.com
Date: 2008-03-04 18:42:05 -0500 (Tue, 04 Mar 2008)
New Revision: 467
Modified:
trunk/java/org/apache/coyote/http11/InternalAprOutputBuffer.java
Log:
- Remove useless sys.outs as non blocking writes seem to mostly work. Add debug to show
partial writes.
Modified: trunk/java/org/apache/coyote/http11/InternalAprOutputBuffer.java
===================================================================
--- trunk/java/org/apache/coyote/http11/InternalAprOutputBuffer.java 2008-03-04 17:35:40
UTC (rev 466)
+++ trunk/java/org/apache/coyote/http11/InternalAprOutputBuffer.java 2008-03-04 23:42:05
UTC (rev 467)
@@ -821,20 +821,23 @@
if (bbuf.position() > 0) {
if (nonBlocking) {
- System.out.println("No leftovers present");
// Perform non blocking writes until all data is written, or the result
// of the write is 0
int pos = 0;
int end = bbuf.position();
while (pos < end) {
- // FIXME: temp testing
- //res = 0;
res = Socket.sendibb(socket, pos, bbuf.position());
+ if (res == 0) {
+ System.out.println("Wrote 0 bytes");
+ }
if (res > 0) {
pos += res;
} else {
break;
}
+ if (pos < end) {
+ System.out.println("Wrote: " + pos + " of " +
end);
+ }
}
if (pos < end) {
if (response.getFlushLeftovers() &&
(Http11AprProcessor.containerThread.get() == Boolean.TRUE)) {
Show replies by date