title: How to share same file for different appender in logback configuration
body: <p>I am using different appender in logback-spring.xml, This is my configuration,</p>
  <p>Here I am having unique file name and fileNamePattern for each appender so this is working fine but creating each new file for each appender.</p>
  <p>Appender 1:</p>
  <pre><code>&lt;appender name=&quot;JSONASYNCAPPENDER&quot; class=&quot;ch.qos.logback.core.rolling.RollingFileAppender&quot;&gt;
          &lt;file&gt;json_async.log&lt;/file&gt;
          &lt;encoder class=&quot;net.logstash.logback.encoder.LoggingEventCompositeJsonEncoder&quot;&gt;
              &lt;providers&gt;
                  *****
              &lt;/providers&gt;
              &lt;jsonFactoryDecorator class=&quot;net.logstash.logback.decorate.CharacterEscapesJsonFactoryDecorator&quot;&gt;
                  ***
              &lt;/jsonFactoryDecorator&gt;
          &lt;/encoder&gt;
          &lt;rollingPolicy class=&quot;ch.qos.logback.core.rolling.TimeBasedRollingPolicy&quot;&gt;
              &lt;fileNamePattern&gt;JSONAsync-%d{yyyy-MM-dd}.%i.logback.zip
              &lt;/fileNamePattern&gt;
              &lt;timeBasedFileNamingAndTriggeringPolicy
                      class=&quot;ch.qos.logback.core.rolling.SizeAndTimeBasedFNATP&quot;&gt;
                  &lt;maxFileSize&gt;${maxFileSize}&lt;/maxFileSize&gt;
              &lt;/timeBasedFileNamingAndTriggeringPolicy&gt;
              &lt;maxHistory&gt;15&lt;/maxHistory&gt;
          &lt;/rollingPolicy&gt;
    &lt;/appender&gt;
  </code></pre>
  <p>Appender 2:</p>
  <pre><code>&lt;appender name=&quot;FILEAPPENDER&quot; class=&quot;ch.qos.logback.core.rolling.RollingFileAppender&quot;&gt;
          &lt;file&gt;File_async.log&lt;/file&gt;
          &lt;encoder class=&quot;ch.qos.logback.classic.encoder.PatternLayoutEncoder&quot;&gt;
              &lt;Pattern&gt;
                  ${FILE_LOG_PATTERN}
              &lt;/Pattern&gt;
          &lt;/encoder&gt;
          &lt;rollingPolicy class=&quot;ch.qos.logback.core.rolling.TimeBasedRollingPolicy&quot;&gt;
              &lt;fileNamePattern&gt;File_Async-%d{yyyy-MM-dd}.%i.logback.zip
              &lt;/fileNamePattern&gt;
              &lt;timeBasedFileNamingAndTriggeringPolicy
                      class=&quot;ch.qos.logback.core.rolling.SizeAndTimeBasedFNATP&quot;&gt;
                  &lt;maxFileSize&gt;${maxFileSize}&lt;/maxFileSize&gt;
              &lt;/timeBasedFileNamingAndTriggeringPolicy&gt;
              &lt;maxHistory&gt;15&lt;/maxHistory&gt;
          &lt;/rollingPolicy&gt;
      &lt;/appender&gt;
  </code></pre>
  <p>If I want to generate only one file for all appenders, then how to achieve. I tried to set same name for all appenders I am getting below error.</p>
  <p>ERROR in ch.qos.logback.core.rolling.RollingFileAppender[] - 'File' option has the same value</p>
  <p>Is it possible to share log message in one file in logback.</p>