You are viewing a plain text version of this content. The canonical link for it is here.
Posted to log4j-user@logging.apache.org by Philip Denno <pd...@tsi.bc.ca> on 2006/07/26 20:43:43 UTC
RE: [BULK] log4j write synchronization
I don't think so. I use it in a multi - threaded environment and control
access to it by synchronizing around a wrapper class for my loggers.
Cheers,
Philip.
-----Original Message-----
From: Michael Gesundheit [mailto:mikeg@rocketmail.com]
Sent: Wednesday, July 26, 2006 11:37 AM
To: log4j-user@logging.apache.org
Subject: [BULK] log4j write synchronization
Importance: Low
Hi,
Does log4j ensures atomic write for every log line? (in a multi
threaded environment obviously)
Thanks,
-Michael
IMPORTANT NOTICE
Email from TSI Terminal Systems Inc. (TSI) is confidential and may be legally privileged. If it is not intended for you, please delete it immediately unread. Under no circumstances should this e-mail be redistributed without prior written consent of TSI. The internet cannot guarantee that this communication is free of viruses, interception or interference and anyone who communicates with us by email is taken to accept the risks in so doing. Without limitation, TSI and its affiliates accept no liability whatsoever and howsoever arising in connection with the use of this email. Under no circumstances shall this email constitute a binding agreement for provision of services by TSI, which is subject to the terms and conditions of TSI's standard schedule for Terminal Tariffs which is also available at http://www.tsi.bc.ca.
---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-user-help@logging.apache.org
Re: [BULK] log4j write synchronization
Posted by Michael Gesundheit <mi...@rocketmail.com>.
Since I have previous experience (not with j4log) that if you don't synchronize writes you will get log lines that that are NOT from one thread. Means a log line will have the begining of one log line and the end of another log line. Most probebly the log line will not be valid log line (incorrect format).
This is not something that will happened with mild logging load but it does occur.
So, does anyone knows for a fact if the writes are synchronized or not?
Thanks,
-Michael
James Stauffer <st...@gmail.com> wrote:
I also use it in a multi-threaded program, don't explicitly
synchronize it, and have never had issues. This is a common setup and
I have never heard of explicit synchronization being added.
On 7/26/06, Philip Denno
wrote:
>
> I don't think so. I use it in a multi - threaded environment and control
> access to it by synchronizing around a wrapper class for my loggers.
>
> Cheers,
> Philip.
>
> -----Original Message-----
> From: Michael Gesundheit [mailto:mikeg@rocketmail.com]
> Sent: Wednesday, July 26, 2006 11:37 AM
> To: log4j-user@logging.apache.org
> Subject: [BULK] log4j write synchronization
> Importance: Low
>
> Hi,
>
> Does log4j ensures atomic write for every log line? (in a multi
> threaded environment obviously)
>
> Thanks,
> -Michael
>
>
>
>
>
>
>
> IMPORTANT NOTICE
> Email from TSI Terminal Systems Inc. (TSI) is confidential and may be legally privileged. If it is not intended for you, please delete it immediately unread. Under no circumstances should this e-mail be redistributed without prior written consent of TSI. The internet cannot guarantee that this communication is free of viruses, interception or interference and anyone who communicates with us by email is taken to accept the risks in so doing. Without limitation, TSI and its affiliates accept no liability whatsoever and howsoever arising in connection with the use of this email. Under no circumstances shall this email constitute a binding agreement for provision of services by TSI, which is subject to the terms and conditions of TSI's standard schedule for Terminal Tariffs which is also available at http://www.tsi.bc.ca.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
> For additional commands, e-mail: log4j-user-help@logging.apache.org
>
>
--
James Stauffer
Are you good? Take the test at http://www.livingwaters.com/good/
---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-user-help@logging.apache.org
Re: [BULK] log4j write synchronization
Posted by James Stauffer <st...@gmail.com>.
I also use it in a multi-threaded program, don't explicitly
synchronize it, and have never had issues. This is a common setup and
I have never heard of explicit synchronization being added.
On 7/26/06, Philip Denno <pd...@tsi.bc.ca> wrote:
>
> I don't think so. I use it in a multi - threaded environment and control
> access to it by synchronizing around a wrapper class for my loggers.
>
> Cheers,
> Philip.
>
> -----Original Message-----
> From: Michael Gesundheit [mailto:mikeg@rocketmail.com]
> Sent: Wednesday, July 26, 2006 11:37 AM
> To: log4j-user@logging.apache.org
> Subject: [BULK] log4j write synchronization
> Importance: Low
>
> Hi,
>
> Does log4j ensures atomic write for every log line? (in a multi
> threaded environment obviously)
>
> Thanks,
> -Michael
>
>
>
>
>
>
>
> IMPORTANT NOTICE
> Email from TSI Terminal Systems Inc. (TSI) is confidential and may be legally privileged. If it is not intended for you, please delete it immediately unread. Under no circumstances should this e-mail be redistributed without prior written consent of TSI. The internet cannot guarantee that this communication is free of viruses, interception or interference and anyone who communicates with us by email is taken to accept the risks in so doing. Without limitation, TSI and its affiliates accept no liability whatsoever and howsoever arising in connection with the use of this email. Under no circumstances shall this email constitute a binding agreement for provision of services by TSI, which is subject to the terms and conditions of TSI's standard schedule for Terminal Tariffs which is also available at http://www.tsi.bc.ca.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
> For additional commands, e-mail: log4j-user-help@logging.apache.org
>
>
--
James Stauffer
Are you good? Take the test at http://www.livingwaters.com/good/
---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-user-help@logging.apache.org