I haven't looked at the source, but the point is that FileDescriptor gives no guarantees what it is referencing.
Sent from my iPad > On May 25, 2016, at 12:49 AM, Mikael Ståldal <[email protected]> > wrote: > > > but I would guess the the FileDescriptor may just be a reference to the > > PrintStream. > > I think it's the other way around, System.out is a wrapper around > FileDescriptor.out. Look at the source code for java.lang.System in JDK 8. > >> On Tue, May 24, 2016 at 7:53 PM, Ralph Goers <[email protected]> >> wrote: >> The javadoc for FileDescriptor is fairly ambiguous. I’d have to look at the >> code, but I would guess the the FileDescriptor may just be a reference to >> the PrintStream. I really don’t think you can count on what it points to. I >> would also worry about us trying to use the FileDescriptor while the >> application might be writing to System.out. >> >> Ralph >> >>> On May 24, 2016, at 10:30 AM, Remko Popma <[email protected]> wrote: >>> >>> >>>> On Tuesday, May 24, 2016 at 11:27:33 PM UTC+9, Mikael Ståldal wrote: >>>> Could we avoid that by using FileDescriptor.out / FileDescriptor.err >>>> instead of System.out / System.err ? >>>> >>>>> On Tue, May 24, 2016 at 4:09 PM, Matt Sicker <[email protected]> wrote: >>>>> All the PrintStream.write() methods have locks. >>>>> >>>>>> On 24 May 2016 at 02:56, Mikael Ståldal <[email protected]> wrote: >>>>>> Do we know why Console has so bad performance (compared to File)? Is >>>>>> this true also if you redirect STDOUT to a file? >>>>>> >>>>>>> and a preview of the updated performance page is here: >>>>>>> http://home.apache.org/~rpopma/log4j/2.6/performance.html >>> >>> I think these are really interesting questions, and I am curious if anyone >>> on this list can share their insights >>> >>> >>> --------------------------------------------------------------------- >>> To unsubscribe, e-mail: [email protected] >>> For additional commands, e-mail: [email protected] >> > > > > -- > > > Mikael Ståldal > Senior software developer > > Magine TV > [email protected] > Grev Turegatan 3 | 114 46 Stockholm, Sweden | www.magine.com > > Privileged and/or Confidential Information may be contained in this message. > If you are not the addressee indicated in this message > (or responsible for delivery of the message to such a person), you may not > copy or deliver this message to anyone. In such case, > you should destroy this message and kindly notify the sender by reply email. >
