JBossWeb SVN: r1554 - trunk/lib.
by jbossweb-commits@lists.jboss.org
Author: remy.maucherat(a)jboss.com
Date: 2010-09-21 09:23:58 -0400 (Tue, 21 Sep 2010)
New Revision: 1554
Removed:
trunk/lib/xnio-api-2.0.1.GA-sources.jar
trunk/lib/xnio-api-2.0.1.GA.jar
trunk/lib/xnio-nio-2.0.1.GA-sources.jar
trunk/lib/xnio-nio-2.0.1.GA.jar
Log:
- Remove libs for now.
Deleted: trunk/lib/xnio-api-2.0.1.GA-sources.jar
===================================================================
(Binary files differ)
Deleted: trunk/lib/xnio-api-2.0.1.GA.jar
===================================================================
(Binary files differ)
Deleted: trunk/lib/xnio-nio-2.0.1.GA-sources.jar
===================================================================
(Binary files differ)
Deleted: trunk/lib/xnio-nio-2.0.1.GA.jar
===================================================================
(Binary files differ)
14 years, 3 months
JBossWeb SVN: r1553 - in branches/2.1.x: webapps/docs and 1 other directory.
by jbossweb-commits@lists.jboss.org
Author: remy.maucherat(a)jboss.com
Date: 2010-09-17 10:20:24 -0400 (Fri, 17 Sep 2010)
New Revision: 1553
Modified:
branches/2.1.x/java/org/apache/jasper/Constants.java
branches/2.1.x/webapps/docs/changelog.xml
Log:
- Port JBWEB-180.
Modified: branches/2.1.x/java/org/apache/jasper/Constants.java
===================================================================
--- branches/2.1.x/java/org/apache/jasper/Constants.java 2010-09-16 13:35:21 UTC (rev 1552)
+++ branches/2.1.x/java/org/apache/jasper/Constants.java 2010-09-17 14:20:24 UTC (rev 1553)
@@ -78,7 +78,7 @@
/**
* Default size of the JSP buffer.
*/
- public static final int DEFAULT_BUFFER_SIZE = 8 * 1024;
+ public static final int DEFAULT_BUFFER_SIZE = Integer.parseInt(System.getProperty("org.apache.jasper.Constants.DEFAULT_BUFFER_SIZE", "8192"));
/**
* Default size for the tag buffers.
Modified: branches/2.1.x/webapps/docs/changelog.xml
===================================================================
--- branches/2.1.x/webapps/docs/changelog.xml 2010-09-16 13:35:21 UTC (rev 1552)
+++ branches/2.1.x/webapps/docs/changelog.xml 2010-09-17 14:20:24 UTC (rev 1553)
@@ -29,6 +29,14 @@
</fix>
</changelog>
</subsection>
+ <subsection name="Jasper">
+ <changelog>
+ <fix>
+ <jira>180</jira>: Add system property to configure default buffer size.
+ Submitted by James Livingston. (remm)
+ </fix>
+ </changelog>
+ </subsection>
</section>
<section name="JBoss Web 2.1.9.GA (remm)">
14 years, 3 months
JBossWeb SVN: r1552 - trunk/webapps/docs.
by jbossweb-commits@lists.jboss.org
Author: remy.maucherat(a)jboss.com
Date: 2010-09-16 09:35:21 -0400 (Thu, 16 Sep 2010)
New Revision: 1552
Modified:
trunk/webapps/docs/changelog.xml
Log:
- Changelog update.
Modified: trunk/webapps/docs/changelog.xml
===================================================================
--- trunk/webapps/docs/changelog.xml 2010-09-16 13:34:45 UTC (rev 1551)
+++ trunk/webapps/docs/changelog.xml 2010-09-16 13:35:21 UTC (rev 1552)
@@ -62,6 +62,9 @@
<fix>
Skip out invalid headers when writing the response. (remm)
</fix>
+ <fix>
+ Use production defaults for endpoints. (remm, jfclere)
+ </fix>
</changelog>
</subsection>
<subsection name="Jasper">
@@ -69,6 +72,10 @@
<fix>
<jboss-jira>JBAS-8374</jboss-jira>: Allow empty parameters brackets for EL method calls. (remm)
</fix>
+ <fix>
+ <jira>180</jira>: Add system property to configure default buffer size.
+ Submitted by James Livingston. (remm)
+ </fix>
</changelog>
</subsection>
</section>
14 years, 3 months
JBossWeb SVN: r1551 - trunk/java/org/apache/tomcat/util/net.
by jbossweb-commits@lists.jboss.org
Author: remy.maucherat(a)jboss.com
Date: 2010-09-16 09:34:45 -0400 (Thu, 16 Sep 2010)
New Revision: 1551
Modified:
trunk/java/org/apache/tomcat/util/net/AprEndpoint.java
trunk/java/org/apache/tomcat/util/net/JIoEndpoint.java
Log:
- Production defaults for the endpoints. Hopefully ...
- Related to JBPAPP-4779: Drop socket when out of workers.
Modified: trunk/java/org/apache/tomcat/util/net/AprEndpoint.java
===================================================================
--- trunk/java/org/apache/tomcat/util/net/AprEndpoint.java 2010-09-16 13:32:46 UTC (rev 1550)
+++ trunk/java/org/apache/tomcat/util/net/AprEndpoint.java 2010-09-16 13:34:45 UTC (rev 1551)
@@ -170,7 +170,7 @@
/**
* Maximum amount of worker threads.
*/
- protected int maxThreads = 200;
+ protected int maxThreads = 32 * Runtime.getRuntime().availableProcessors();
public void setMaxThreads(int maxThreads) { this.maxThreads = maxThreads; }
public int getMaxThreads() { return maxThreads; }
@@ -186,7 +186,7 @@
/**
* Size of the socket poller.
*/
- protected int pollerSize = 8 * 1024;
+ protected int pollerSize = (OS.IS_WIN32 || OS.IS_WIN64) ? (8 * 1024) : (32 * 1024);
public void setPollerSize(int pollerSize) { this.pollerSize = pollerSize; }
public int getPollerSize() { return pollerSize; }
@@ -194,7 +194,7 @@
/**
* Size of the sendfile (= concurrent files which can be served).
*/
- protected int sendfileSize = 1 * 1024;
+ protected int sendfileSize = (OS.IS_WIN32 || OS.IS_WIN64) ? (1 * 1024) : (16 * 1024);
public void setSendfileSize(int sendfileSize) { this.sendfileSize = sendfileSize; }
public int getSendfileSize() { return sendfileSize; }
@@ -934,26 +934,6 @@
/**
- * Return a new worker thread, and block while to worker is available.
- */
- protected Worker getWorkerThread() {
- // Allocate a new worker thread
- Worker workerThread = createWorkerThread();
- while (workerThread == null) {
- try {
- synchronized (workers) {
- workers.wait();
- }
- } catch (InterruptedException e) {
- // Ignore
- }
- workerThread = createWorkerThread();
- }
- return workerThread;
- }
-
-
- /**
* Recycle the specified Processor so that it can be used again.
*
* @param workerThread The processor to be recycled
@@ -991,7 +971,12 @@
protected boolean processSocketWithOptions(long socket) {
try {
if (executor == null) {
- getWorkerThread().assignWithOptions(socket);
+ Worker worker = createWorkerThread();
+ if (worker != null) {
+ worker.assignWithOptions(socket);
+ } else {
+ return false;
+ }
} else {
executor.execute(new SocketWithOptionsProcessor(socket));
}
@@ -1011,7 +996,12 @@
protected boolean processSocket(long socket) {
try {
if (executor == null) {
- getWorkerThread().assign(socket);
+ Worker worker = createWorkerThread();
+ if (worker != null) {
+ worker.assign(socket);
+ } else {
+ return false;
+ }
} else {
executor.execute(new SocketProcessor(socket));
}
@@ -1031,7 +1021,12 @@
protected boolean processSocket(long socket, SocketStatus status) {
try {
if (executor == null) {
- getWorkerThread().assign(socket, status);
+ Worker worker = createWorkerThread();
+ if (worker != null) {
+ worker.assign(socket, status);
+ } else {
+ return false;
+ }
} else {
executor.execute(new SocketEventProcessor(socket, status));
}
Modified: trunk/java/org/apache/tomcat/util/net/JIoEndpoint.java
===================================================================
--- trunk/java/org/apache/tomcat/util/net/JIoEndpoint.java 2010-09-16 13:32:46 UTC (rev 1550)
+++ trunk/java/org/apache/tomcat/util/net/JIoEndpoint.java 2010-09-16 13:34:45 UTC (rev 1551)
@@ -155,7 +155,7 @@
/**
* Maximum amount of worker threads.
*/
- protected int maxThreads = 200;
+ protected int maxThreads = 512 * Runtime.getRuntime().availableProcessors();
public void setMaxThreads(int maxThreads) { this.maxThreads = maxThreads; }
public int getMaxThreads() { return maxThreads; }
@@ -1205,26 +1205,6 @@
/**
- * Return a new worker thread, and block while to worker is available.
- */
- protected Worker getWorkerThread() {
- // Allocate a new worker thread
- Worker workerThread = createWorkerThread();
- while (workerThread == null) {
- try {
- synchronized (workers) {
- workers.wait();
- }
- } catch (InterruptedException e) {
- // Ignore
- }
- workerThread = createWorkerThread();
- }
- return workerThread;
- }
-
-
- /**
* Recycle the specified Processor so that it can be used again.
*
* @param workerThread The processor to be recycled
@@ -1244,7 +1224,12 @@
protected boolean processSocket(Socket socket) {
try {
if (executor == null) {
- getWorkerThread().assign(socket);
+ Worker worker = createWorkerThread();
+ if (worker != null) {
+ worker.assign(socket);
+ } else {
+ return false;
+ }
} else {
executor.execute(new SocketProcessor(socket));
}
@@ -1264,7 +1249,12 @@
protected boolean processSocket(Socket socket, SocketStatus status) {
try {
if (executor == null) {
- getWorkerThread().assign(socket, status);
+ Worker worker = createWorkerThread();
+ if (worker != null) {
+ worker.assign(socket, status);
+ } else {
+ return false;
+ }
} else {
executor.execute(new SocketEventProcessor(socket, status));
}
14 years, 3 months
JBossWeb SVN: r1550 - trunk/java/org/apache/jasper.
by jbossweb-commits@lists.jboss.org
Author: remy.maucherat(a)jboss.com
Date: 2010-09-16 09:32:46 -0400 (Thu, 16 Sep 2010)
New Revision: 1550
Modified:
trunk/java/org/apache/jasper/Constants.java
Log:
- JBWEB-180: Add system property for buffer size.
Modified: trunk/java/org/apache/jasper/Constants.java
===================================================================
--- trunk/java/org/apache/jasper/Constants.java 2010-09-14 13:07:25 UTC (rev 1549)
+++ trunk/java/org/apache/jasper/Constants.java 2010-09-16 13:32:46 UTC (rev 1550)
@@ -84,7 +84,7 @@
/**
* Default size of the JSP buffer.
*/
- public static final int DEFAULT_BUFFER_SIZE = 8 * 1024;
+ public static final int DEFAULT_BUFFER_SIZE = Integer.parseInt(System.getProperty("org.apache.jasper.Constants.DEFAULT_BUFFER_SIZE", "8192"));
/**
* Default size for the tag buffers.
14 years, 3 months
JBossWeb SVN: r1549 - in trunk/java/org/apache/catalina: core and 1 other directory.
by jbossweb-commits@lists.jboss.org
Author: remy.maucherat(a)jboss.com
Date: 2010-09-14 09:07:25 -0400 (Tue, 14 Sep 2010)
New Revision: 1549
Modified:
trunk/java/org/apache/catalina/Context.java
trunk/java/org/apache/catalina/core/StandardContext.java
Log:
- Add a lifecycle event for finer thread association management during start/stop of a webapp.
Modified: trunk/java/org/apache/catalina/Context.java
===================================================================
--- trunk/java/org/apache/catalina/Context.java 2010-09-11 10:04:33 UTC (rev 1548)
+++ trunk/java/org/apache/catalina/Context.java 2010-09-14 13:07:25 UTC (rev 1549)
@@ -76,6 +76,18 @@
public static final String COMPLETE_CONFIG_EVENT = "complete-config";
+ /**
+ * The LifecycleEvent type sent to bind context information to the thread.
+ */
+ public static final String BIND_THREAD_EVENT = "bind-thread";
+
+
+ /**
+ * The LifecycleEvent type sent to unbind context information to the thread.
+ */
+ public static final String UNBIND_THREAD_EVENT = "unbind-thread";
+
+
// ------------------------------------------------------------- Properties
Modified: trunk/java/org/apache/catalina/core/StandardContext.java
===================================================================
--- trunk/java/org/apache/catalina/core/StandardContext.java 2010-09-11 10:04:33 UTC (rev 1548)
+++ trunk/java/org/apache/catalina/core/StandardContext.java 2010-09-14 13:07:25 UTC (rev 1549)
@@ -4207,6 +4207,8 @@
(getLoader().getClassLoader());
}
+ lifecycle.fireLifecycleEvent(BIND_THREAD_EVENT, null);
+
DirContextURLStreamHandler.bind(getResources());
return oldContextClassLoader;
@@ -4219,6 +4221,8 @@
*/
protected void unbindThread(ClassLoader oldContextClassLoader) {
+ lifecycle.fireLifecycleEvent(UNBIND_THREAD_EVENT, null);
+
Thread.currentThread().setContextClassLoader(oldContextClassLoader);
oldContextClassLoader = null;
14 years, 3 months
JBossWeb SVN: r1548 - sandbox/webapps.
by jbossweb-commits@lists.jboss.org
Author: jfrederic.clere(a)jboss.com
Date: 2010-09-11 06:04:33 -0400 (Sat, 11 Sep 2010)
New Revision: 1548
Modified:
sandbox/webapps/myapp.xml
Log:
Add a welcome entry.
Modified: sandbox/webapps/myapp.xml
===================================================================
--- sandbox/webapps/myapp.xml 2010-08-31 16:35:24 UTC (rev 1547)
+++ sandbox/webapps/myapp.xml 2010-09-11 10:04:33 UTC (rev 1548)
@@ -30,6 +30,7 @@
<!-- Servlets -->
<servlet>
<servlet-name>MySession</servlet-name>
+ <display-name>installerDownload</display-name>
<servlet-class>MySession</servlet-class>
<init-param>
<param-name>debug</param-name>
@@ -88,10 +89,6 @@
<servlet-class>TestOutputStream</servlet-class>
</servlet>
<servlet>
- <servlet-name>TestSlow</servlet-name>
- <servlet-class>TestSlow</servlet-class>
- </servlet>
- <servlet>
<servlet-name>TestError</servlet-name>
<servlet-class>TestError</servlet-class>
</servlet>
@@ -103,6 +100,10 @@
<servlet-name>TestDispatch</servlet-name>
<servlet-class>TestDispatch</servlet-class>
</servlet>
+ <servlet>
+ <servlet-name>NPEDemoServlet</servlet-name>
+ <servlet-class>NPEDemoServlet</servlet-class>
+ </servlet>
<servlet-mapping>
@@ -150,10 +151,6 @@
<url-pattern>/TestOutputStream</url-pattern>
</servlet-mapping>
<servlet-mapping>
- <servlet-name>TestSlow</servlet-name>
- <url-pattern>/TestSlow</url-pattern>
- </servlet-mapping>
- <servlet-mapping>
<servlet-name>TestError</servlet-name>
<url-pattern>/TestError</url-pattern>
</servlet-mapping>
@@ -165,7 +162,14 @@
<servlet-name>TestDispatch</servlet-name>
<url-pattern>/TestDispatch</url-pattern>
</servlet-mapping>
+ <servlet-mapping>
+ <servlet-name>NPEDemoServlet</servlet-name>
+ <url-pattern>/NPEDemoServlet</url-pattern>
+ </servlet-mapping>
+ <welcome-file-list>
+ <welcome-file>index.jsp</welcome-file>
+ </welcome-file-list>
<!-- Security testings -->
<security-constraint>
14 years, 3 months