我们在哪里可以找到Jboss EAP 6中的Server.xml?

时间:2013-08-01 06:59:11

标签: java deployment jboss setting jboss-eap-6

我正在尝试一些性能调优并遵循Jboss性能调优指南。所以我读了第3章,我想转向Cached Connection Manager。但是有人提到它的配置是在server.xml中。我无法在任何地方找到server.xml。我在Windows 7上使用jboss-eap-6.1。所以我的问题在哪里我会找到server.xml或者如何关闭缓存连接管理器?

这是来自tunning guide的文本:

配置位于JBOSS_EAP_DIST / jboss-as / server // deploy / jbossweb.sar目录下的文件server.xml中。请注意,最小配置不包括JBoss Web。 以下是server.xml的摘录,其中启用了CachedConnectionManager。

 <!-- Check for unclosed connections and transaction terminated checks in servlets/jsps.   Important: The dependency on the CachedConnectionManager in META-INF/jboss-service.xml must be  uncommented, too -->

 <Valve className="org.jboss.web.tomcat.service.jca.CachedConnectionValve"  cachedConnectionManagerObjectName="jboss.jca:service=CachedConnectionManager" transactionManagerObjectName="jboss:service=TransactionManager" />

要禁用CachedConnectionManager,请按照以下示例注释最后三行:

 <!-- Check for unclosed connections and transaction terminated checks in servlets/jsps. Important: The dependency on the CachedConnectionManager in META-INF/jboss-service.xml must be uncommented, too
 <Valve className="org.jboss.web.tomcat.service.jca.CachedConnectionValve" cachedConnectionManagerObjectName="jboss.jca:service=CachedConnectionManager" transactionManagerObjectName="jboss:service=TransactionManager" /> -->

还需要编辑另一个配置文件:JBOSS_EAP_DIST / jboss-as / server // deploy / jbossweb.sar / META-INF目录中的jboss-beans.xml。请注意,最小配置不包括JBoss Web。这个文件由微容器用于JBoss Web与它的集成,它指定了依赖组件之间的连接。在这种情况下,CachedConnectionManager的阀门依赖于事务管理器。因此,为了正确摆脱阀门,我们必须从此配置文件中删除相关性信息。相关信息位于文件的顶部,如下所示:

 <!-- Only needed if the org.jboss.web.tomcat.service.jca.CachedConnectionValve is enabled in the tomcat server.xml file. -? 
  <depends>jboss.jca:service=CachedConnectionManager</depends>

 <!-- Transaction manager for unfinished transaction checking in the CachedConnectionValve -->
  <depends>jboss:service=TransactionManager</depends>

注释这些行,如下例所示:        jboss.jca:service = CachedConnectionManager - ?                  JBoss的:服务=事务管理器&LT; /取决于&GT; - &GT;

1 个答案:

答案 0 :(得分:2)

您使用的EAP版本与您的配置指南告诉您的文件结构不同。您是否正在使用JBoss AS 6的配置指南来配置JBoss EAP 6?如果是这样,这就是你沮丧的根源。 您拥有的说明适用于EAP 5文件结构。 您可以找到EAP 6文档here

如果您在独立模式下运行,您的配置将在$ {JBOSS_HOME} /standalone/configuration/standalone.xml

中找到