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

    <property name="LOG_FILE" value="src/main/resources/logs/eni.log"/>

    <!-- Appender pour la console -->
    <appender name="Console" class="ch.qos.logback.core.ConsoleAppender">
        <encoder>
            <pattern>%d{HH:mm:ss.SSS} [%thread] %-5level %logger{36} - %msg%n</pattern>
        </encoder>
    </appender>

    <!-- Appender pour le fichier -->
    <appender name="File" class="ch.qos.logback.core.FileAppender">
        <file>${LOG_FILE}</file>
        <encoder>
            <pattern>%d{HH:mm:ss.SSS} [%thread] %-5level %logger{36} - %msg%n</pattern>
        </encoder>
    </appender>

    <!-- Configuration du niveau de log -->
    <root level="INFO">
        <!-- Référence aux appenders -->
        <appender-ref ref="Console"/>
        <appender-ref ref="File"/>
    </root>
</configuration>