blob: f42514275a3a161ea6286d9ade0fd22f48b09fe0 [file] [log] [blame]
Guillaume Nodet05fac962009-04-27 10:01:58 +00001<?xml version="1.0" encoding="UTF-8"?>
2<!--
3
4 Licensed to the Apache Software Foundation (ASF) under one or more
5 contributor license agreements. See the NOTICE file distributed with
6 this work for additional information regarding copyright ownership.
7 The ASF licenses this file to You under the Apache License, Version 2.0
8 (the "License"); you may not use this file except in compliance with
9 the License. You may obtain a copy of the License at
10
11 http://www.apache.org/licenses/LICENSE-2.0
12
13 Unless required by applicable law or agreed to in writing, software
14 distributed under the License is distributed on an "AS IS" BASIS,
15 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16 See the License for the specific language governing permissions and
17 limitations under the License.
18
19-->
20<beans xmlns="http://www.springframework.org/schema/beans"
21 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
22 xmlns:ctx="http://www.springframework.org/schema/context"
23 xmlns:osgi="http://www.springframework.org/schema/osgi"
24 xmlns:osgix="http://www.springframework.org/schema/osgi-compendium"
25 xmlns:util="http://www.springframework.org/schema/util"
26 xmlns:gshell="http://servicemix.apache.org/schema/servicemix-gshell"
27 xsi:schemaLocation="
28 http://www.springframework.org/schema/beans
29 http://www.springframework.org/schema/beans/spring-beans.xsd
30 http://www.springframework.org/schema/context
31 http://www.springframework.org/schema/context/spring-context.xsd
32 http://www.springframework.org/schema/osgi
33 http://www.springframework.org/schema/osgi/spring-osgi.xsd
34 http://www.springframework.org/schema/osgi-compendium
35 http://www.springframework.org/schema/osgi-compendium/spring-osgi-compendium.xsd
36 http://www.springframework.org/schema/util
37 http://www.springframework.org/schema/util/spring-util.xsd
38 http://servicemix.apache.org/schema/servicemix-gshell
39 http://servicemix.apache.org/schema/servicemix-gshell/servicemix-gshell.xsd">
40
Guillaume Nodet05fac962009-04-27 10:01:58 +000041 <gshell:command-bundle>
42 <gshell:command name="log/display">
Gert Vanthienenf54a8392009-05-02 19:57:13 +000043 <gshell:action class="org.apache.felix.karaf.gshell.log.DisplayLog">
Guillaume Nodet810fec92009-05-04 11:26:15 +000044 <property name="bundleContext" ref="bundleContext"/>
Guillaume Nodet05fac962009-04-27 10:01:58 +000045 <property name="events" ref="events" />
46 <property name="pattern" value="${pattern}" />
47 </gshell:action>
48 </gshell:command>
49 <gshell:link name="log/d" target="log/display" />
50 <gshell:command name="log/display-exception">
Gert Vanthienenf54a8392009-05-02 19:57:13 +000051 <gshell:action class="org.apache.felix.karaf.gshell.log.DisplayException">
Guillaume Nodet810fec92009-05-04 11:26:15 +000052 <property name="bundleContext" ref="bundleContext"/>
Guillaume Nodet05fac962009-04-27 10:01:58 +000053 <property name="events" ref="events" />
54 </gshell:action>
55 </gshell:command>
56 <gshell:link name="log/de" target="log/display-exception" />
57 <gshell:command name="log/get">
Guillaume Nodet810fec92009-05-04 11:26:15 +000058 <gshell:action class="org.apache.felix.karaf.gshell.log.GetLogLevel">
59 <property name="bundleContext" ref="bundleContext"/>
60 </gshell:action>
Guillaume Nodet05fac962009-04-27 10:01:58 +000061 </gshell:command>
62 <gshell:command name="log/set">
Guillaume Nodet810fec92009-05-04 11:26:15 +000063 <gshell:action class="org.apache.felix.karaf.gshell.log.SetLogLevel">
64 <property name="bundleContext" ref="bundleContext"/>
65 </gshell:action>
Guillaume Nodet05fac962009-04-27 10:01:58 +000066 </gshell:command>
67
68 <gshell:alias name="ld" alias="log/d" />
69 <gshell:alias name="lde" alias="log/de" />
70 </gshell:command-bundle>
71
Gert Vanthienenf54a8392009-05-02 19:57:13 +000072 <bean id="vmLogAppender" class="org.apache.felix.karaf.gshell.log.VmLogAppender">
Guillaume Nodet05fac962009-04-27 10:01:58 +000073 <property name="events" ref="events" />
74 </bean>
75
Gert Vanthienenf54a8392009-05-02 19:57:13 +000076 <bean id="events" class="org.apache.felix.karaf.gshell.log.LruList">
Guillaume Nodet05fac962009-04-27 10:01:58 +000077 <constructor-arg value="${size}" />
78 </bean>
79
80 <osgi:service ref="vmLogAppender" interface="org.ops4j.pax.logging.spi.PaxAppender">
81 <osgi:service-properties>
82 <entry>
83 <key><util:constant static-field="org.ops4j.pax.logging.PaxLoggingService.APPENDER_NAME_PROPERTY"/></key>
84 <value>VmLogAppender</value>
85 </entry>
86 </osgi:service-properties>
87 </osgi:service>
88
Guillaume Nodetb3f74802009-05-12 16:43:44 +000089 <osgix:cm-properties id="cmProps" persistent-id="org.apache.felix.karaf.log">
Guillaume Nodet05fac962009-04-27 10:01:58 +000090 <prop key="size">500</prop>
91 <prop key="pattern">%d{ABSOLUTE} | %-5.5p | %-16.16t | %-32.32c{1} | %-32.32C %4L | %m%n</prop>
92 </osgix:cm-properties>
93
94 <ctx:property-placeholder properties-ref="cmProps" />
95
Gert Vanthienenf54a8392009-05-02 19:57:13 +000096</beans>