我的server.xml文件中有两个连接器:
<Connector protocol="HTTP/1.1" maxThreads="1" connectionTimeout="20000" redirectPort="8443" disableUploadTimeout="true" port="29171" />
<Connector protocol="AJP/1.3" maxThreads="1" redirectPort="8443" port="29172" />
我添加了maxThreads =“1”,但似乎我仍然可以获得多个请求。我也尝试设置垃圾值(字符串),但服务仍然会加载和处理请求。
我在这里做错了什么?
感谢
已编辑:附加主题转储
2012-04-22 09:31:41 Commons Daemon procrun stdout initialized
The following NLogHandler level was read - WARNING
log4j:WARN No appenders could be found for logger (org.apache.axis.i18n.ProjectResourceBundle).
log4j:WARN Please initialize the log4j system properly.
2012-04-22 10:51:57 Commons Daemon procrun stdout initialized
2012-04-22 10:52:03 Commons Daemon procrun stdout initialized
The following NLogHandler level was read - WARNING
log4j:WARN No appenders could be found for logger (org.apache.axis.i18n.ProjectResourceBundle).
log4j:WARN Please initialize the log4j system properly.
2012-04-22 10:53:41 Commons Daemon procrun stdout initialized
2012-04-22 10:53:46 Commons Daemon procrun stdout initialized
2012-04-22 10:54:03 Commons Daemon procrun stdout initialized
The following NLogHandler level was read - WARNING
log4j:WARN No appenders could be found for logger (org.apache.axis.i18n.ProjectResourceBundle).
log4j:WARN Please initialize the log4j system properly.
2012-04-22 11:11:25 Commons Daemon procrun stdout initialized
The following NLogHandler level was read - WARNING
log4j:WARN No appenders could be found for logger (org.apache.axis.i18n.ProjectResourceBundle).
log4j:WARN Please initialize the log4j system properly.
2012-04-22 11:11:29
Full thread dump Java HotSpot(TM) 64-Bit Server VM (20.2-b06 mixed mode):
"Low Memory Detector" daemon prio=6 tid=0x0000000004ecb000 nid=0x34f4 runnable [0x0000000000000000]
java.lang.Thread.State: RUNNABLE
"C2 CompilerThread1" daemon prio=10 tid=0x0000000004eb3000 nid=0x3348 waiting on condition [0x0000000000000000]
java.lang.Thread.State: RUNNABLE
"C2 CompilerThread0" daemon prio=10 tid=0x0000000000428800 nid=0x25c4 waiting on condition [0x0000000000000000]
java.lang.Thread.State: RUNNABLE
"Attach Listener" daemon prio=10 tid=0x0000000000426000 nid=0x3934 runnable [0x0000000000000000]
java.lang.Thread.State: RUNNABLE
"Signal Dispatcher" daemon prio=10 tid=0x0000000000425000 nid=0x38b8 waiting on condition [0x0000000000000000]
java.lang.Thread.State: RUNNABLE
"Finalizer" daemon prio=8 tid=0x0000000000412000 nid=0x12e8 in Object.wait() [0x0000000004e5f000]
java.lang.Thread.State: WAITING (on object monitor)
at java.lang.Object.wait(Native Method)
- waiting on <0x00000000e0c01300> (a java.lang.ref.ReferenceQueue$Lock)
at java.lang.ref.ReferenceQueue.remove(Unknown Source)
- locked <0x00000000e0c01300> (a java.lang.ref.ReferenceQueue$Lock)
at java.lang.ref.ReferenceQueue.remove(Unknown Source)
at java.lang.ref.Finalizer$FinalizerThread.run(Unknown Source)
"Reference Handler" daemon prio=10 tid=0x0000000000409000 nid=0x6a8 in Object.wait() [0x0000000004d5f000]
java.lang.Thread.State: WAITING (on object monitor)
at java.lang.Object.wait(Native Method)
- waiting on <0x00000000e0c011d8> (a java.lang.ref.Reference$Lock)
at java.lang.Object.wait(Object.java:485)
at java.lang.ref.Reference$ReferenceHandler.run(Unknown Source)
- locked <0x00000000e0c011d8> (a java.lang.ref.Reference$Lock)
"main" prio=6 tid=0x00000000001dc800 nid=0x3890 runnable [0x000000000101d000]
java.lang.Thread.State: RUNNABLE
at speechcat.externalinterfacecomm.MdalAccess.mdalInit(Native Method)
at speechcat.externalinterfacecomm.ExternalInterfaceHandler.connect(ExternalInterfaceHandler.java:65)
at speechcat.QueryEngine.load(QueryEngine.java:621)
at speechcat.SpeechCat.loadSpeechCat(SpeechCat.java:4295)
at localhost.axis.services.SpeechCat.SpeechCatSoapBindingImpl.init(SpeechCatSoapBindingImpl.java:48)
- locked <0x000000009de54248> (a java.lang.Class for localhost.axis.services.SpeechCat.SpeechCatSoapBindingImpl)
- locked <0x000000009de54248> (a java.lang.Class for localhost.axis.services.SpeechCat.SpeechCatSoapBindingImpl)
at localhost.axis.services.SpeechCat.SpeechCatSoapBindingImpl.<clinit>(SpeechCatSoapBindingImpl.java:19)
at localhost.axis.services.SpeechCat.SpeechCatWSConfig.contextInitialized(SpeechCatWSConfig.java:29)
at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4206)
at org.apache.catalina.core.StandardContext.start(StandardContext.java:4705)
- locked <0x00000000e18152d0> (a org.apache.catalina.core.StandardContext)
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:799)
- locked <0x00000000e15e4c50> (a java.util.HashMap)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:779)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:601)
at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:943)
at org.apache.catalina.startup.HostConfig.deployWARs(HostConfig.java:778)
at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:504)
at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1317)
at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:324)
at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:142)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1065)
- locked <0x00000000e15e4ba8> (a org.apache.catalina.core.StandardHost)
at org.apache.catalina.core.StandardHost.start(StandardHost.java:840)
- locked <0x00000000e15e4ba8> (a org.apache.catalina.core.StandardHost)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1057)
- locked <0x00000000e1551a58> (a org.apache.catalina.core.StandardEngine)
at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:463)
at org.apache.catalina.core.StandardService.start(StandardService.java:525)
- locked <0x00000000e1551a58> (a org.apache.catalina.core.StandardEngine)
at org.apache.catalina.core.StandardServer.start(StandardServer.java:754)
- locked <0x00000000e1617c78> (a [Lorg.apache.catalina.Service;)
at org.apache.catalina.startup.Catalina.start(Catalina.java:595)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:289)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:414)
"VM Thread" prio=10 tid=0x0000000000401800 nid=0x1ce4 runnable
"GC task thread#0 (ParallelGC)" prio=6 tid=0x0000000000360800 nid=0x660 runnable
"GC task thread#1 (ParallelGC)" prio=6 tid=0x0000000000362800 nid=0x3af8 runnable
"VM Periodic Task Thread" prio=10 tid=0x0000000004edc000 nid=0x3818 waiting on condition
JNI global references: 1190
Heap
PSYoungGen total 448000K, used 46336K [0x00000000e0c00000, 0x0000000100000000, 0x0000000100000000)
eden space 384000K, 12% used [0x00000000e0c00000,0x00000000e39402e8,0x00000000f8300000)
from space 64000K, 0% used [0x00000000fc180000,0x00000000fc180000,0x0000000100000000)
to space 64000K, 0% used [0x00000000f8300000,0x00000000f8300000,0x00000000fc180000)
PSOldGen total 1024000K, used 0K [0x00000000a2400000, 0x00000000e0c00000, 0x00000000e0c00000)
object space 1024000K, 0% used [0x00000000a2400000,0x00000000a2400000,0x00000000e0c00000)
PSPermGen total 21248K, used 17124K [0x000000009d200000, 0x000000009e6c0000, 0x00000000a2400000)
object space 21248K, 80% used [0x000000009d200000,0x000000009e2b91d8,0x000000009e6c0000)
答案 0 :(得分:1)
除了maxThreads参数之外,还有acceptCount,它是排队请求的大小。我认为默认值是100.您可能需要将其设置为1或0.但是您要在这里做什么/实现?