How to turn debug log on in Intellij Idea console for ignite core module?

classic Classic list List threaded Threaded
5 messages Options
Ray
Reply | Threaded
Open this post in threaded view
|

How to turn debug log on in Intellij Idea console for ignite core module?

Ray
I tried change .level=INFO to FINE in config/java.util.logging.properties
file and disable quite mode using -DIGNITE_QUIET=false, but it still didn't
work and there's no DEBUG or TRACE level log in the console.
Please advice me how to turn debug log on in Intellij Idea console for
ignite core module.



--
Sent from: http://apache-ignite-developers.2346864.n4.nabble.com/
Reply | Threaded
Open this post in threaded view
|

Re: How to turn debug log on in Intellij Idea console for ignite core module?

Mmuzaf
Hello, Ray!

I usually update this one configuration file for running test in DEBUG mode:
ignite\modules\core\src\test\config\log4j-test.xml

I've uncommented line for DEBUG only specific package, because debug whole
module produces too much output. e.g.:

<category name="org.apache.ignite.internal.processors.cache.distributed.dht.preloader">
    <level value="DEBUG"/>
</category>

Is it what are you looking for?

ср, 23 мая 2018 г. в 16:08, Ray <[hidden email]>:

> I tried change .level=INFO to FINE in config/java.util.logging.properties
> file and disable quite mode using -DIGNITE_QUIET=false, but it still didn't
> work and there's no DEBUG or TRACE level log in the console.
> Please advice me how to turn debug log on in Intellij Idea console for
> ignite core module.
>
>
>
> --
> Sent from: http://apache-ignite-developers.2346864.n4.nabble.com/
>
Ray
Reply | Threaded
Open this post in threaded view
|

Re: How to turn debug log on in Intellij Idea console for ignite core module?

Ray
Thanks for the reply.

But your approach seems only to be working for tests in Ignite core module.
What I'm looking for is a way to open DEBUG mode when starting an Ignite
node from
modules/core/src/main/java/org/apache/ignite/startup/cmdline/CommandLineStartup.java.



--
Sent from: http://apache-ignite-developers.2346864.n4.nabble.com/
Reply | Threaded
Open this post in threaded view
|

Re: How to turn debug log on in Intellij Idea console for ignite core module?

Mmuzaf
Hi Ray,

Have you found the solution? This is interesting question for me too.

Breafly search leads me to this file:
\ignite\config\ignite-log4j.xml

as it described here:
https://ignite.apache.org/releases/latest/javadoc/org/apache/ignite/logger/log4j/Log4JLogger.html

with (and other DEBUG options):

<!-- Uncomment to enable logging to console. -->
<!--
    <appender-ref ref="CONSOLE"/>
-->



ср, 23 мая 2018 г. в 17:34, Ray <[hidden email]>:

> Thanks for the reply.
>
> But your approach seems only to be working for tests in Ignite core module.
> What I'm looking for is a way to open DEBUG mode when starting an Ignite
> node from
>
> modules/core/src/main/java/org/apache/ignite/startup/cmdline/CommandLineStartup.java.
>
>
>
> --
> Sent from: http://apache-ignite-developers.2346864.n4.nabble.com/
>
Ray
Reply | Threaded
Open this post in threaded view
|

Re: How to turn debug log on in Intellij Idea console for ignite core module?

Ray
Not yet.

I tried your way, but seems it's not working.
The default logger is JavaLogger when I started Ignite node from
CommandLineStartup.
And the ignite core module does not contain Log4JLogger so it will not load
\ignite\config\ignite-log4j.xml.

I tried adding the ignite-log4j module into ignite core module but Intellij
says it contains module cycles.
Because ignite-log4j module also depends on ignite-core module.

I also tried comment the scope for log4j in pom but still no luck.
        <dependency>
            <groupId>log4j</groupId>
            <artifactId>log4j</artifactId>
           
        </dependency>




--
Sent from: http://apache-ignite-developers.2346864.n4.nabble.com/