[英]How to configure pool size of Message Driven Bean
I would like to configure the pool size of a MDB but just one. 我只想配置一个MDB的池大小。 I deploy my application on JBOSS 6 or Glassfish 3 so the solution must be standard.
我将应用程序部署在JBOSS 6或Glassfish 3上,因此该解决方案必须是标准的。
I found for JBOSS maxSession for @ActivationConfigProperty but it is not standard For glassfish i don't find anything to create sun-ejb-jar.xml ... 我为@ActivationConfigProperty找到了JBOSS maxSession,但它不是标准的对于glassfish,我找不到任何创建sun-ejb-jar.xml的东西...
Can you help me ? 你能帮助我吗 ? thanks.
谢谢。
For glassfish, you can specify bean's max-pool-size to 1 in glassfish-ejb-jar.xml. 对于glassfish,可以在glassfish-ejb-jar.xml中将bean的max-pool-size指定为1。 See deployment guide .
请参阅部署指南 。
You'll need a sun-ejb-jar.xm which goes in the META-INF folder. 您需要一个位于META-INF文件夹中的sun-ejb-jar.xm。
Here's one that you can use / edit. 这是您可以使用/编辑的一个。
<sun-ejb-jar>
<enterprise-beans>
<unique-id>0</unique-id>
<ejb>
<ejb-name>YOUR EJB NANME</ejb-name>
<jndi-name>YOUR JNDI NAME</jndi-name>
<bean-pool>
<steady-pool-size>1</steady-pool-size>
<resize-quantity>1</resize-quantity>
<max-pool-size>3</max-pool-size>
<pool-idle-timeout-in-seconds>600</pool-idle-timeout-in-seconds>
</bean-pool>
</ejb>
</enterprise-beans>
</sun-ejb-jar>
This is not settable through standard Java EE 6 activation config properties, which are: 这不能通过标准Java EE 6激活配置属性来设置,这些属性是:
acknowledgeMode
, acknowledgeMode
, messageSelector
, messageSelector
, subscriptionDurability
, subscriptionDurability
, destinationType
. destinationType
。 All others are provider-specific. 所有其他都是特定于提供程序的。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.