Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.java.programmer > #21816

Re: ultralog: new concept of logging API

X-Received by 10.224.110.68 with SMTP id m4mr7434875qap.2.1359346504565; Sun, 27 Jan 2013 20:15:04 -0800 (PST)
X-Received by 10.49.94.143 with SMTP id dc15mr2088513qeb.32.1359346504469; Sun, 27 Jan 2013 20:15:04 -0800 (PST)
Path csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!news.glorb.com!p13no5709143qai.0!news-out.google.com!k2ni2734qap.0!nntp.google.com!p13no5709141qai.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail
Newsgroups comp.lang.java.programmer
Date Sun, 27 Jan 2013 20:15:04 -0800 (PST)
In-Reply-To <1qriau87gfqqh$.1b0kgnpw8hf4v.dlg@40tude.net>
Complaints-To groups-abuse@google.com
Injection-Info glegroupsg2000goo.googlegroups.com; posting-host=217.172.23.24; posting-account=Z-5a_wkAAABTzN1pAiC7xNW_xfTNp2Vr
NNTP-Posting-Host 217.172.23.24
References <0cfefb99-94f9-44e0-9b58-926818a9560d@googlegroups.com> <ke3s9v$md5$1@dont-email.me> <78bfbd4c-a257-44ed-ae03-73ceb19fab18@googlegroups.com> <1qriau87gfqqh$.1b0kgnpw8hf4v.dlg@40tude.net>
User-Agent G2/1.0
MIME-Version 1.0
Message-ID <fb5795d7-d594-48d0-9bea-0b21f7e58d51@googlegroups.com> (permalink)
Subject Re: ultralog: new concept of logging API
From Mikhail Vladimirov <vladimirow@mail.ru>
Injection-Date Mon, 28 Jan 2013 04:15:04 +0000
Content-Type text/plain; charset=ISO-8859-1
Content-Transfer-Encoding quoted-printable
Xref csiph.com comp.lang.java.programmer:21816

Show key headers only | View raw


> But the latter still has to be SOMEWHERE. You just hide it behind a method.
> But your logger isn't magic, it can't guess what I want the log entry to
> look like, so I still have to specify it somewhere. Your way just forces me
> to write half a dozen extra classes/methods for every class.
I'm not sure you checked examples in ultralog's WiKi before guessing.

Simple syntax like

    logger.info ("Hello, " + user + "!");

or

    logger.error ("Oh, My!", exception);

is still available in ultralog and is supposed to be used in places where we just need to quickly add some logging and we don't care about garbage, or in cases where we want to log plain messages without any substitutions.

When you use new syntax like:

    logger.userLoggedIn (userName, address);

in Eclipse you just need to put mouse pointer over method name and wait for a moment to popup appear to know literal message template and level.  And you need to just Ctrl+Click on it to start editing message template.

Ultralog is not magic, but it tries to lock like magic.  You need to define method for parametrized log messages, but you never need to implement them, so there is no executable code in them.

The idea is that each class that needs high-performance logging, will define it's own logger interface, usually as inner interface with protected access level, and then define all log messages in it.  Once each logger interface belongs to separate class, they are not supposed to be reused.

Back to comp.lang.java.programmer | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

ultralog: new concept of logging API Mikhail Vladimirov <vladimirow@mail.ru> - 2013-01-26 22:05 -0800
  Re: ultralog: new concept of logging API markspace <markspace@nospam.nospam> - 2013-01-27 10:39 -0800
    Re: ultralog: new concept of logging API vladimirow@mail.ru - 2013-01-27 11:03 -0800
      Re: ultralog: new concept of logging API Joerg Meier <joergmmeier@arcor.de> - 2013-01-27 20:48 +0100
        Re: ultralog: new concept of logging API Mikhail Vladimirov <vladimirow@mail.ru> - 2013-01-27 20:15 -0800
      Re: ultralog: new concept of logging API Leif Roar Moldskred <leifm@dimnakorr.com> - 2013-01-27 13:51 -0600
        Re: ultralog: new concept of logging API Mikhail Vladimirov <vladimirow@mail.ru> - 2013-01-27 19:57 -0800
  Re: ultralog: new concept of logging API Arved Sandstrom <asandstrom2@eastlink.ca> - 2013-01-28 05:23 -0400
    Re: ultralog: new concept of logging API Mikhail Vladimirov <vladimirow@mail.ru> - 2013-01-28 01:32 -0800
      Re: ultralog: new concept of logging API Arved Sandstrom <asandstrom2@eastlink.ca> - 2013-01-28 05:37 -0400
        Re: ultralog: new concept of logging API Mikhail Vladimirov <vladimirow@mail.ru> - 2013-01-28 02:06 -0800
      Re: ultralog: new concept of logging API Lew <lewbloch@gmail.com> - 2013-01-28 13:49 -0800
        Re: ultralog: new concept of logging API Mikhail Vladimirov <vladimirow@mail.ru> - 2013-01-29 06:04 -0800
          Re: ultralog: new concept of logging API Lew <lewbloch@gmail.com> - 2013-01-29 10:19 -0800
          Re: ultralog: new concept of logging API Leif Roar Moldskred <leifm@dimnakorr.com> - 2013-01-29 13:10 -0600
            Re: ultralog: new concept of logging API Mikhail Vladimirov <vladimirow@mail.ru> - 2013-01-29 11:34 -0800
              Re: ultralog: new concept of logging API Arne Vajhøj <arne@vajhoej.dk> - 2013-01-29 20:16 -0500
                Re: ultralog: new concept of logging API Mikhail Vladimirov <vladimirow@mail.ru> - 2013-01-29 19:57 -0800
                Re: ultralog: new concept of logging API Lew <lewbloch@gmail.com> - 2013-01-29 22:56 -0800
                Re: ultralog: new concept of logging API Mikhail Vladimirov <vladimirow@mail.ru> - 2013-01-29 23:19 -0800
                Re: ultralog: new concept of logging API Lew <lewbloch@gmail.com> - 2013-01-30 08:23 -0800
                Re: ultralog: new concept of logging API lipska the kat <"nospam at neversurrender dot co dot uk"> - 2013-01-30 16:54 +0000
                Re: ultralog: new concept of logging API Mikhail Vladimirov <vladimirow@mail.ru> - 2013-01-30 13:33 -0800
                Re: ultralog: new concept of logging API tisue@cs.nwu.edu (Seth Tisue) - 2013-01-30 16:37 -0500
                Re: ultralog: new concept of logging API tisue@cs.nwu.edu (Seth Tisue) - 2013-01-30 16:33 -0500
                Re: ultralog: new concept of logging API Arne Vajhøj <arne@vajhoej.dk> - 2013-01-30 21:50 -0500
                Re: ultralog: new concept of logging API lipska the kat <"nospam at neversurrender dot co dot uk"> - 2013-01-31 10:38 +0000
                Re: ultralog: new concept of logging API T®oll <spooksRus@derbyshire-crania.org> - 2013-01-31 12:30 -0500
                Re: ultralog: new concept of logging API T®oll <spooksRus@derbyshire-crania.org> - 2013-01-31 12:30 -0500
                Re: ultralog: new concept of logging API lipska the kat <"nospam at neversurrender dot co dot uk"> - 2013-01-31 17:55 +0000
                Re: ultralog: new concept of logging API lipska the kat <"nospam at neversurrender dot co dot uk"> - 2013-01-31 10:48 +0000
                Re: ultralog: new concept of logging API T®oll <spooksRus@derbyshire-crania.org> - 2013-01-31 12:32 -0500
                Re: ultralog: new concept of logging API lipska the kat <"nospam at neversurrender dot co dot uk"> - 2013-01-31 17:58 +0000
                Re: ultralog: new concept of logging API Mikhail Vladimirov <vladimirow@mail.ru> - 2013-01-31 21:49 -0800
                Re: ultralog: new concept of logging API Arne Vajhøj <arne@vajhoej.dk> - 2013-01-30 21:47 -0500
                Re: ultralog: new concept of logging API Mikhail Vladimirov <vladimirow@mail.ru> - 2013-01-30 21:14 -0800
                Re: ultralog: new concept of logging API Arne Vajhøj <arne@vajhoej.dk> - 2013-01-30 21:43 -0500
                Re: ultralog: new concept of logging API Mikhail Vladimirov <vladimirow@mail.ru> - 2013-01-30 21:11 -0800
  Re: ultralog: new concept of logging API Mikhail Vladimirov <vladimirow@mail.ru> - 2013-01-30 13:43 -0800

csiph-web