开发者

Where to define <Environment...> elements in JBoss

开发者 https://www.devze.com 2022-12-18 07:27 出处:网络
I try to define environment entries in JBoss 5.1 and added following to the server/default/deploy/jbossweb.sar/context.xml file:

I try to define environment entries in JBoss 5.1 and added following to the server/default/deploy/jbossweb.sar/context.xml file:

<Environment type="java.lang.String" name="name" value="value" />

Following error occurs on startup:

2010-01-26 14:50:08,383 ERROR [org.jboss.web.tomcat.service.deployers.JBossContextConfig] (main开发者_开发问答) XML error parsing: context.xml org.jboss.xb.binding.JBossXBException: Failed to parse source: Resource cannot appear in this position. Expected content of Context is unordered_sequence: attributes? InstanceListener* Realm? Parameters* Manager? Loader? Valve* SessionCookie? Resources? Listener*

Where may I define environment entries in JBoss (but outside of application's EAR)?


This article confirms that (likely) it is not possible to configure environment entries in JBoss. Author suggests to use PropertiesService as alternative.

Property configuration in properties-service.xml works great!

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号