You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@deltaspike.apache.org by "John D. Ament" <jo...@gmail.com> on 2016/06/02 01:19:30 UTC

Re: Why is log level overridden in cdi test runner?

Gerhard,

I still don't quite see the issue with letting the log level dictate what
gets shown.  Do you consider the log level to be a valid config option
here, assuming we document how to override (e.g. with logging.properties)?

John

On Tue, Apr 26, 2016 at 6:53 AM Gerhard Petracek <gp...@apache.org>
wrote:

> @john:
>
> we just force the level of one logger (used by us) to avoid that important
> information (start/stop/failed messages) get skipped (due to a global
> config).
> e.g. some jpa-issues (esp. in combination with in-memory-dbs) can lead to
> strange side-effects in @Before/@After logic (-> e.g. the >next< test
> fails).
> -> this information can help a lot!
>
> before this part was moved to ds, it was possible to disable those
> log-entries. people did that ~frequently until they hit such an issue.
> once they spent hours in analyzing random side-effects across test-methods,
> they usually enabled it again (because they realized that it would have
> taken way less time to analyze the issue).
> some argued that they could enable it just on their ci-server or in case
> there are issues, however, it turned out that people forget about it...
> -> the config-option was dropped (esp. because 2 log-entries per
> test-method isn't a big deal).
> -> if we provide a config-option to disable such log-entries, you can do it
> - but on your own risk (to miss essential information)...
>
> regards,
> gerhard
>
>
>
> 2016-04-25 12:49 GMT+02:00 John D. Ament <jo...@apache.org>:
>
> > Could you explain what you consider to be a config option and why the
> > native logging API doesn't cover it?
> >
> > If someone wants an info message, they'll have it by default.  If they
> want
> > it off they can turn it off.
> >
> > The code right now forces you to see these info messages.
> >
> > John
> >
> > On Mon, Apr 25, 2016 at 5:18 AM Gerhard Petracek <gp...@apache.org>
> > wrote:
> >
> > > @john:
> > > -1 for disabling it per default (such information is essential if you
> > have
> > > to analyze e.g. random side-effects on ci-servers quickly)
> > > +1 for adding a config-option (which allows to disable it locally)
> > >
> > > regards,
> > > gerhard
> > >
> > >
> > >
> > > 2016-04-25 1:36 GMT+02:00 John D. Ament <jo...@apache.org>:
> > >
> > > > All,
> > > >
> > > > I was wondering, why is the log level overridden here?
> > > >
> > > >
> > >
> >
> https://github.com/apache/deltaspike/blob/master/deltaspike/modules/test-control/api/src/main/java/org/apache/deltaspike/testcontrol/api/junit/CdiTestSuiteRunner.java#L155
> > > >
> > > > I'd like to disable it since most people prefer silent logging when
> > > > nothings going on.
> > > >
> > > > John
> > > >
> > >
> >
>

Re: Why is log level overridden in cdi test runner?

Posted by Gerhard Petracek <ge...@gmail.com>.
@john:
please check if it's still an issue for you - see DELTASPIKE-1151

regards,
gerhard



2016-06-02 3:19 GMT+02:00 John D. Ament <jo...@gmail.com>:

> Gerhard,
>
> I still don't quite see the issue with letting the log level dictate what
> gets shown.  Do you consider the log level to be a valid config option
> here, assuming we document how to override (e.g. with logging.properties)?
>
> John
>
> On Tue, Apr 26, 2016 at 6:53 AM Gerhard Petracek <gp...@apache.org>
> wrote:
>
> > @john:
> >
> > we just force the level of one logger (used by us) to avoid that
> important
> > information (start/stop/failed messages) get skipped (due to a global
> > config).
> > e.g. some jpa-issues (esp. in combination with in-memory-dbs) can lead to
> > strange side-effects in @Before/@After logic (-> e.g. the >next< test
> > fails).
> > -> this information can help a lot!
> >
> > before this part was moved to ds, it was possible to disable those
> > log-entries. people did that ~frequently until they hit such an issue.
> > once they spent hours in analyzing random side-effects across
> test-methods,
> > they usually enabled it again (because they realized that it would have
> > taken way less time to analyze the issue).
> > some argued that they could enable it just on their ci-server or in case
> > there are issues, however, it turned out that people forget about it...
> > -> the config-option was dropped (esp. because 2 log-entries per
> > test-method isn't a big deal).
> > -> if we provide a config-option to disable such log-entries, you can do
> it
> > - but on your own risk (to miss essential information)...
> >
> > regards,
> > gerhard
> >
> >
> >
> > 2016-04-25 12:49 GMT+02:00 John D. Ament <jo...@apache.org>:
> >
> > > Could you explain what you consider to be a config option and why the
> > > native logging API doesn't cover it?
> > >
> > > If someone wants an info message, they'll have it by default.  If they
> > want
> > > it off they can turn it off.
> > >
> > > The code right now forces you to see these info messages.
> > >
> > > John
> > >
> > > On Mon, Apr 25, 2016 at 5:18 AM Gerhard Petracek <gpetracek@apache.org
> >
> > > wrote:
> > >
> > > > @john:
> > > > -1 for disabling it per default (such information is essential if you
> > > have
> > > > to analyze e.g. random side-effects on ci-servers quickly)
> > > > +1 for adding a config-option (which allows to disable it locally)
> > > >
> > > > regards,
> > > > gerhard
> > > >
> > > >
> > > >
> > > > 2016-04-25 1:36 GMT+02:00 John D. Ament <jo...@apache.org>:
> > > >
> > > > > All,
> > > > >
> > > > > I was wondering, why is the log level overridden here?
> > > > >
> > > > >
> > > >
> > >
> >
> https://github.com/apache/deltaspike/blob/master/deltaspike/modules/test-control/api/src/main/java/org/apache/deltaspike/testcontrol/api/junit/CdiTestSuiteRunner.java#L155
> > > > >
> > > > > I'd like to disable it since most people prefer silent logging when
> > > > > nothings going on.
> > > > >
> > > > > John
> > > > >
> > > >
> > >
> >
>