Author: remy.maucherat(a)jboss.com
Date: 2013-12-10 12:43:48 -0500 (Tue, 10 Dec 2013)
New Revision: 2326
Modified:
branches/7.4.x/src/main/java/org/apache/coyote/http11/AbstractInternalInputBuffer.java
branches/7.4.x/src/main/java/org/apache/coyote/http11/Constants.java
branches/7.4.x/src/main/java/org/apache/coyote/http11/InternalInputBuffer.java
branches/7.4.x/src/main/java/org/apache/coyote/http11/InternalNioOutputBuffer.java
branches/7.4.x/src/main/java/org/apache/coyote/http11/InternalOutputBuffer.java
Log:
Some (basic) constant cleanups and removal of old unused code.
Modified:
branches/7.4.x/src/main/java/org/apache/coyote/http11/AbstractInternalInputBuffer.java
===================================================================
---
branches/7.4.x/src/main/java/org/apache/coyote/http11/AbstractInternalInputBuffer.java 2013-12-10
17:41:35 UTC (rev 2325)
+++
branches/7.4.x/src/main/java/org/apache/coyote/http11/AbstractInternalInputBuffer.java 2013-12-10
17:43:48 UTC (rev 2326)
@@ -119,15 +119,6 @@
* Create a new instance of {@code AbstractInternalInputBuffer}
*
* @param request
- */
- public AbstractInternalInputBuffer(Request request) {
- this(request, Constants.DEFAULT_HTTP_HEADER_BUFFER_SIZE);
- }
-
- /**
- * Create a new instance of {@code AbstractInternalInputBuffer}
- *
- * @param request
* @param headerBufferSize
*/
public AbstractInternalInputBuffer(Request request, int headerBufferSize) {
Modified: branches/7.4.x/src/main/java/org/apache/coyote/http11/Constants.java
===================================================================
--- branches/7.4.x/src/main/java/org/apache/coyote/http11/Constants.java 2013-12-10
17:41:35 UTC (rev 2325)
+++ branches/7.4.x/src/main/java/org/apache/coyote/http11/Constants.java 2013-12-10
17:43:48 UTC (rev 2326)
@@ -126,13 +126,6 @@
/**
- * Default HTTP header buffer size.
- */
- public static final int DEFAULT_HTTP_HEADER_BUFFER_SIZE =
-
Integer.valueOf(System.getProperty("org.apache.coyote.http11.DEFAULT_HTTP_HEADER_BUFFER_SIZE",
"8192")).intValue();
-
-
- /**
* Async buffer size.
*/
public static final int ASYNC_BUFFER_SIZE =
Modified: branches/7.4.x/src/main/java/org/apache/coyote/http11/InternalInputBuffer.java
===================================================================
---
branches/7.4.x/src/main/java/org/apache/coyote/http11/InternalInputBuffer.java 2013-12-10
17:41:35 UTC (rev 2325)
+++
branches/7.4.x/src/main/java/org/apache/coyote/http11/InternalInputBuffer.java 2013-12-10
17:43:48 UTC (rev 2326)
@@ -47,14 +47,6 @@
/**
- * Default constructor.
- */
- public InternalInputBuffer(Request request) {
- this(request, Constants.DEFAULT_HTTP_HEADER_BUFFER_SIZE);
- }
-
-
- /**
* Alternate constructor.
*/
public InternalInputBuffer(Request request, int headerBufferSize) {
Modified:
branches/7.4.x/src/main/java/org/apache/coyote/http11/InternalNioOutputBuffer.java
===================================================================
---
branches/7.4.x/src/main/java/org/apache/coyote/http11/InternalNioOutputBuffer.java 2013-12-10
17:41:35 UTC (rev 2325)
+++
branches/7.4.x/src/main/java/org/apache/coyote/http11/InternalNioOutputBuffer.java 2013-12-10
17:43:48 UTC (rev 2326)
@@ -155,11 +155,7 @@
this.response = response;
this.headers = response.getMimeHeaders();
buf = new byte[headerBufferSize];
- if (headerBufferSize < Constants.DEFAULT_HTTP_HEADER_BUFFER_SIZE) {
- bbuf = ByteBuffer.allocateDirect(6 * 1500);
- } else {
- bbuf = ByteBuffer.allocateDirect((headerBufferSize / 1500 + 1) * 1500);
- }
+ bbuf = ByteBuffer.allocateDirect(headerBufferSize);
outputBuffer = new OutputBufferImpl();
filterLibrary = new OutputFilter[0];
Modified: branches/7.4.x/src/main/java/org/apache/coyote/http11/InternalOutputBuffer.java
===================================================================
---
branches/7.4.x/src/main/java/org/apache/coyote/http11/InternalOutputBuffer.java 2013-12-10
17:41:35 UTC (rev 2325)
+++
branches/7.4.x/src/main/java/org/apache/coyote/http11/InternalOutputBuffer.java 2013-12-10
17:43:48 UTC (rev 2326)
@@ -47,14 +47,6 @@
/**
- * Default constructor.
- */
- public InternalOutputBuffer(Response response) {
- this(response, Constants.DEFAULT_HTTP_HEADER_BUFFER_SIZE);
- }
-
-
- /**
* Alternate constructor.
*/
public InternalOutputBuffer(Response response, int headerBufferSize) {