<?xml version="1.0" encoding="UTF-8"?>
<!--

    Licensed to the Apache Software Foundation (ASF) under one
    or more contributor license agreements.  See the NOTICE file
    distributed with this work for additional information
    regarding copyright ownership.  The ASF licenses this file
    to you under the Apache License, Version 2.0 (the
    "License"); you may not use this file except in compliance
    with the License.  You may obtain a copy of the License at

      http://www.apache.org/licenses/LICENSE-2.0

    Unless required by applicable law or agreed to in writing,
    software distributed under the License is distributed on an
    "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
    KIND, either express or implied.  See the License for the
    specific language governing permissions and limitations
    under the License.

-->
<Configuration status="warn" monitorInterval="10">
    <Properties>
        <Property name="bookkeeper.shell.log.dir">.</Property>
        <Property name="bookkeeper.shell.log.file">bookkeeper-shell.log</Property>
        <Property name="bookkeeper.shell.root.level">INFO</Property>
        <Property name="bookkeeper.shell.root.appender">ROLLINGFILE</Property>
    </Properties>
    <Appenders>
        <Console name="CONSOLE" target="SYSTEM_OUT">
            <PatternLayout pattern="%d{ABSOLUTE} %-5p %m%n"/>
        </Console>
        <RollingFile name="ROLLINGFILE" fileName="${sys:bookkeeper.shell.log.dir}/${sys:bookkeeper.shell.log.file}" filePattern="${sys:bookkeeper.shell.log.dir}/${sys:bookkeeper.shell.log.file}%d{.yyyy-MM-dd}">
            <PatternLayout pattern="%d{ISO8601} - %-5p - [%t:%C{1}@%L] - %m %X%n"/>
            <Policies>
                <TimeBasedTriggeringPolicy modulate="true"/>
            </Policies>
            <DefaultRolloverStrategy max="100"/>
        </RollingFile>
    </Appenders>
    <Loggers>
        <Root level="${sys:bookkeeper.shell.root.level}">
            <AppenderRef ref="${sys:bookkeeper.shell.root.appender}"/>
        </Root>
        <Logger name="org.apache.bookkeeper.bookie.BookieShell" level="INFO">
            <AppenderRef ref="CONSOLE"/>
        </Logger>
        <Logger name="org.apache.bookkeeper.bookie.InterleavedStorageRegenerateIndexOp" level="INFO">
            <AppenderRef ref="CONSOLE"/>
        </Logger>
        <Logger name="org.apache.bookkeeper.client.BookKeeperAdmin" level="INFO">
            <AppenderRef ref="CONSOLE"/>
        </Logger>
        <Logger name="org.apache.bookkeeper.tools.cli.commands" level="INFO">
            <AppenderRef ref="CONSOLE"/>
        </Logger>
    </Loggers>
</Configuration>
