[logback-user] About FileAppender in Logback

Hasan.Birol at ing.com.tr Hasan.Birol at ing.com.tr
Fri Nov 1 07:04:16 CET 2019


Dear Logback Team;


Have a problem with logback .
Have a logback.xml file find it below. Each thread has a single log file. However, cant recognize file is done or thread is done with looking the file. File is not locked or something (tried to lock the file by extending fileappender but cant succeed) . I don't would like to write a code to get content of file which I mean, dont wanna write a some symbol to find out file is done.  I also used, triggeringPolicy cant succeed..

<appender name="SIFT" class="XXXXX.SiftingAppender">
    <discriminator>
        <key>fileLocation</key>
        <defaultValue>${user.home}\start.log</defaultValue>
    </discriminator>
    <sift>
        <appender name="FILE-${fileLocation}" class="ch.qos.logback.core.FileAppender">
            <file>${fileLocation}</file>
            <append>false</append>
            <encoder>
                <pattern>%msg%n</pattern>
            </encoder>
        </appender>
    </sift>
</appender>

I just would like to change extension when thread is done .log to .xml, or lock the file while end of the thread, or move the file end of the thread.


Many many thanks.

Have a nice day,

Hasan Birol
Yaz?l?m Dan??man? - Software Consultant
Yaz?l?m Geli?tirme Sistemleri ve Platform Uygulamalar? B?l?m? - Software Development Frameworks and Platform Applications
T:
E: Hasan.Birol at ing.com.tr
[http://image.ing.com.tr/EmailBanner/ING_LOGO_89x42px-02.png]<https://www.ing.com.tr>

Kisiye ozel bu mesaj ve icerigindeki bilgiler gizlidir. ING bu mesajin icerigi ve ekleri ile ilgili olarak 
hukuksal hicbir sorumluluk kabul etmez.Yetkili alicilardan biri degilseniz, bu mesajin herhangi bir sekilde 
ifsa 
edilmesi, kullanilmasi, kopyalanmasi,yayilmasi veya mesajda yeralan hususlarla ilgili olarak herhangi bir 
islem 
yapilmasinin kesinlikle yasak oldugunu bildiririz.Boyle bir durumda lutfen hemen mesajin gondericisini 
bilgilendiriniz ve mesaji sisteminizden siliniz.Internet ortaminda gonderilen e-posta mesajlarindaki hata 
ve/veya 
eksikliklerden veya viruslerden dolayi mesajin gondericisi herhangi bir sorumluluk kabul 
etmemektedir.Tesekkur ederiz.

The information contained in this communication may contain confidential or legally privileged information. 
ING doesn't accept any legal responsibility for the contents and attachments of this message. If you 
are not the intended recipient you are hereby notified that any disclosure, use, copying, distribution or taking 
any action in reliance on the contents of this information is strictly prohibited. If you have received this 
communication in error, please notify the sender immediately by responding to this e-mail and then delete it 
from your system. The sender does not accept any liability for any errors or omissions or any viruses in the 
context of this message which arise as a result of internet transmission. Thank you.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.qos.ch/pipermail/logback-user/attachments/20191101/adf080a3/attachment-0001.html>


More information about the logback-user mailing list