| 1 |
<?xml version="1.0" encoding="UTF-8"?> |
| 2 |
<!-- |
| 3 |
~ Copyright 2009-2012 Roland Huss |
| 4 |
~ |
| 5 |
~ Licensed under the Apache License, Version 2.0 (the "License"); |
| 6 |
~ you may not use this file except in compliance with the License. |
| 7 |
~ You may obtain a copy of the License at |
| 8 |
~ |
| 9 |
~ http://www.apache.org/licenses/LICENSE-2.0 |
| 10 |
~ |
| 11 |
~ Unless required by applicable law or agreed to in writing, software |
| 12 |
~ distributed under the License is distributed on an "AS IS" BASIS, |
| 13 |
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 14 |
~ See the License for the specific language governing permissions and |
| 15 |
~ limitations under the License. |
| 16 |
--> |
| 17 |
|
| 18 |
<beans xmlns="http://www.springframework.org/schema/beans" |
| 19 |
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" |
| 20 |
xmlns:context="http://www.springframework.org/schema/context" |
| 21 |
xmlns:util="http://www.springframework.org/schema/util" |
| 22 |
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd |
| 23 |
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context.xsd http://www.springframework.org/schema/util http://www.springframework.org/schema/util/spring-util.xsd"> |
| 24 |
|
| 25 |
<context:property-placeholder system-properties-mode="ENVIRONMENT"/> |
| 26 |
|
| 27 |
<util:map id="configuration"> |
| 28 |
<entry key="jmx.jolokiaPort" value="${jolokia.port}"/> |
| 29 |
</util:map> |
| 30 |
|
| 31 |
<bean name="server" id="jolokia" class="org.jolokia.jvmagent.spring.SpringJolokiaAgent"> |
| 32 |
<property name="config"> |
| 33 |
<bean class="org.jolokia.jvmagent.spring.SpringJolokiaConfigHolder"> |
| 34 |
<property name="config"> |
| 35 |
<util:map> |
| 36 |
<entry key="autoStart" value="true"/> |
| 37 |
<entry key="host" value="127.0.0.1"/> |
| 38 |
<entry key="port" value="#{configuration['jmx.jolokiaPort']}"/> |
| 39 |
<entry key="agentContext" value="/jolokia"/> |
| 40 |
</util:map> |
| 41 |
</property> |
| 42 |
</bean> |
| 43 |
</property> |
| 44 |
</bean> |
| 45 |
</beans> |