You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by Mirko Friedenhagen <mf...@gmail.com> on 2016/07/11 08:53:54 UTC

Maven 3.4.0 and documentation of gossip logging

Hello,

is someone already working on the documentation for this? I see
slf4j-gossip was chosen, so we may enjoy colors in the output but how
do you configure gossip? I only found how to influence the location of
configuration files, but the format of these seems not to be
documented.

Looking at e.g.
http://www.slf4j.org/api/org/slf4j/impl/SimpleLogger.html I see how to
configure stuff. Or take a look at
http://www.tinylog.org/configuration#level.

I checked out gossip but did not find anything equivalent to the
above. Is there a even possibility to influence single logger
thresholds via System properties? Are the default file names I see for
gossip the correct ones? I spent at least an hour but did not get my
usecase working (i.e. do not show downloads and print duration in
milliseconds).

One of the more wanted logging features with Maven (at least here) is
to quieten down Maven (i.e. only show WARN/ERROR) so non
build-engineers are seeing test errors/failures more easily.

And I am a bit afraid that 3.4.0 is doing too much (changed logger,
changed resolutions etc.)

I now just tried and set
MAVEN_OPTS="-Dcom.planet57.gossip.Log.threshold=WARN
-Dcom.planet57.gossip.Log.internalThreshold=WARN", but this did not
help. Before I had variations of
-Dcom.planet57.gossip.Gossip.LoggerImpl.threshold.org.apache.maven.cli.transfer.Slf4jMavenTransferListener=WARN
but none of these did work.



Regards Mirko

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


Re: Maven 3.4.0 and documentation of gossip logging

Posted by Jason Dillon <ja...@gmail.com>.
Gossip presently doesn’t allow you to set adhoc logging configuration via
system properties, but as you have discovered uses a configurable
properties file to allow a profile to be configured to adjust your logging
as needed.  I suppose that feature could be added, either to gossip proper
to as a customized source in the maven implementation.

For "backwards compatibility" I think gossip needs to add an option
for a relative timestamp (since creation of the loggers) and maybe an
easy way to set single log levels from the command line.

Likely easy enough to add, the basic renderer is here:

https://github.com/jdillon/gossip/blob/master/gossip-bootstrap/src/main/java/com/planet57/gossip/render/PatternRenderer.java

Though unsure how its “backwards compatible”.  If you want to use features
of another slf4j impl you are still free to switch it back to slf4j-simple
or something else and get a lot more control over logging with your
favorite backend.

—jason

Re: Maven 3.4.0 and documentation of gossip logging

Posted by Mirko Friedenhagen <mf...@gmail.com>.
Hello,

I now played a bit but did not succeed easily. I had to add a
gossip.configuration and add
-Dgossip.configuration=gossip.configuration to my MAVEN_OPTS, see:

https://gitlab.com/mfriedenhagen/gitlabstats/blob/master/gossip.configuration
(especially lines 9 and 13)
and
https://gitlab.com/mfriedenhagen/gitlabstats/blob/master/.gitlab-ci.yml#L2

For "backwards compatibility" I think gossip needs to add an option
for a relative timestamp (since creation of the loggers) and maybe an
easy way to set single log levels from the command line.

Regards
Mirko

Regards Mirko
--
http://illegalstateexception.blogspot.com/
https://github.com/mfriedenhagen/ (http://osrc.dfm.io/mfriedenhagen)
https://bitbucket.org/mfriedenhagen/


On Mon, Jul 11, 2016 at 11:26 AM, Michael Osipov <mi...@apache.org> wrote:
> Am 2016-07-11 um 10:53 schrieb Mirko Friedenhagen:
>>
>> Hello,
>>
>> is someone already working on the documentation for this? I see
>> slf4j-gossip was chosen, so we may enjoy colors in the output but how
>> do you configure gossip? I only found how to influence the location of
>> configuration files, but the format of these seems not to be
>> documented.
>>
>> Looking at e.g.
>> http://www.slf4j.org/api/org/slf4j/impl/SimpleLogger.html I see how to
>> configure stuff. Or take a look at
>> http://www.tinylog.org/configuration#level.
>>
>> I checked out gossip but did not find anything equivalent to the
>> above. Is there a even possibility to influence single logger
>> thresholds via System properties? Are the default file names I see for
>> gossip the correct ones? I spent at least an hour but did not get my
>> usecase working (i.e. do not show downloads and print duration in
>> milliseconds).
>>
>> One of the more wanted logging features with Maven (at least here) is
>> to quieten down Maven (i.e. only show WARN/ERROR) so non
>> build-engineers are seeing test errors/failures more easily.
>>
>> And I am a bit afraid that 3.4.0 is doing too much (changed logger,
>> changed resolutions etc.)
>>
>> I now just tried and set
>> MAVEN_OPTS="-Dcom.planet57.gossip.Log.threshold=WARN
>> -Dcom.planet57.gossip.Log.internalThreshold=WARN", but this did not
>> help. Before I had variations of
>>
>> -Dcom.planet57.gossip.Gossip.LoggerImpl.threshold.org.apache.maven.cli.transfer.Slf4jMavenTransferListener=WARN
>> but none of these did work.
>
>
> For that reason, I have created MNG-6044 four weeks ago.
>
> Michael
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
>

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


Re: Maven 3.4.0 and documentation of gossip logging

Posted by Michael Osipov <mi...@apache.org>.
Am 2016-07-11 um 10:53 schrieb Mirko Friedenhagen:
> Hello,
>
> is someone already working on the documentation for this? I see
> slf4j-gossip was chosen, so we may enjoy colors in the output but how
> do you configure gossip? I only found how to influence the location of
> configuration files, but the format of these seems not to be
> documented.
>
> Looking at e.g.
> http://www.slf4j.org/api/org/slf4j/impl/SimpleLogger.html I see how to
> configure stuff. Or take a look at
> http://www.tinylog.org/configuration#level.
>
> I checked out gossip but did not find anything equivalent to the
> above. Is there a even possibility to influence single logger
> thresholds via System properties? Are the default file names I see for
> gossip the correct ones? I spent at least an hour but did not get my
> usecase working (i.e. do not show downloads and print duration in
> milliseconds).
>
> One of the more wanted logging features with Maven (at least here) is
> to quieten down Maven (i.e. only show WARN/ERROR) so non
> build-engineers are seeing test errors/failures more easily.
>
> And I am a bit afraid that 3.4.0 is doing too much (changed logger,
> changed resolutions etc.)
>
> I now just tried and set
> MAVEN_OPTS="-Dcom.planet57.gossip.Log.threshold=WARN
> -Dcom.planet57.gossip.Log.internalThreshold=WARN", but this did not
> help. Before I had variations of
> -Dcom.planet57.gossip.Gossip.LoggerImpl.threshold.org.apache.maven.cli.transfer.Slf4jMavenTransferListener=WARN
> but none of these did work.

For that reason, I have created MNG-6044 four weeks ago.

Michael


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org