Kogito log level

440 views
Skip to first unread message

francisco boato

unread,
Jul 8, 2022, 6:36:51 AM7/8/22
to Kogito development mailing list
Hello, I'm using kogito with spring boot, and I would like to know how can i change the log level, when running and compiling the application.  By default is set to DEBUG, so i get a lot of this
" DEBUG org.kie.dmn.backend.marshalling.v1_2.xstream.DiagramElementExtensionConverter - Tried to convert the extension element child ComponentsWidthsExtension, but no converter is registered for this child."
 a 

Matteo Mortari

unread,
Jul 8, 2022, 6:51:52 AM7/8/22
to Kogito development mailing list
Hi Francisco,

logging is usually configured at the user application level.

In Kogito, we use SLF4J but the actual logging being recorded and displayed depends on the logging backend chosen by the end-user/developer and depending on the configuration setup in the target application.
For instance is typical to chose Logback as the logging backend, you may have somewhere a xml configuration file similar to:
<logger name="org.kie" level="debug"/>

You need to adjust logging level to better suit your needs, such as info or warn.

If you can share a little reproducer we might also check if there's something going wrong, but again this is usually configured on a per-application basis

Hope this helps!
MM

--
You received this message because you are subscribed to the Google Groups "Kogito development mailing list" group.
To unsubscribe from this group and stop receiving emails from it, send an email to kogito-developm...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/kogito-development/86e3c32e-dcc4-4823-930a-5e03c5d99fd0n%40googlegroups.com.


--

francisco boato

unread,
Jul 8, 2022, 12:07:28 PM7/8/22
to Kogito development mailing list
Thanks for the response, but the log i would like to reduce is generated when executing the scesim test, its seems not to be affected by my application log level configuration (just to be clear, when i reduce the log level config of the app ... it works ... but only for the log generated when the app is running, not for the log generated on execution of the unit test)

Matteo Mortari

unread,
Jul 8, 2022, 12:39:53 PM7/8/22
to Kogito development mailing list
Hi Francisco,

> the log i would like to reduce is generated when executing the scesim test

My suggestion is to share a simple reproducer with the instruction/couple of screenshots that indicate your experienced issue, so that the Tooling team (of the SceSim Tool) can take a look.

Hope this helps!
MM

Message has been deleted
Message has been deleted
Message has been deleted

francisco boato

unread,
Jul 11, 2022, 7:10:21 AM7/11/22
to Kogito development mailing list
Hi Matteo,
In https://github.com/bodisava/prova-dmn there is a basic kogito project, when running mvn clean install, on the test section, there will be some lines of log with DEBUG level (attached the screenshot). 

I would like to know if there is a way of disabling the log generated during the test (at least the debug logs), because in a real application the amount of lines generated during test would be a lot.

debug_log_on_test.PNG

Gabriele Cardosi

unread,
Jul 11, 2022, 7:51:20 AM7/11/22
to Kogito development mailing list
Hi Francisco
it seems that at runtime the actual logger instance is 

that seems to ignore simplelogger.properties

I found the following ones:


TBH, I made some very quick tests (with the project you linked) without success, but maybe more "experiments" are needed...

Hope this could help somehow

m2c











--
You received this message because you are subscribed to the Google Groups "Kogito development mailing list" group.
To unsubscribe from this group and stop receiving emails from it, send an email to kogito-developm...@googlegroups.com.


--

GABRIELE CARDOSI

SENIOR SOFTWARE ENGINEERS, MW

Red Hat Ltd

gcar...@redhat.com    M: +39-3461717132    

francisco boato

unread,
Jul 11, 2022, 9:11:38 AM7/11/22
to Kogito development mailing list
I found a workaround for manage the log level on unit test .... by adding a "logback-test.xml" file on test/resources folder like this

<?xml version="1.0" encoding="UTF-8"?>
<configuration>
    <include resource="org/springframework/boot/logging/logback/base.xml" />
    <logger name="org.kie " level="warn" />
</configuration>

Matteo Mortari

unread,
Jul 11, 2022, 9:55:18 AM7/11/22
to Kogito development mailing list
Hi Francisco,
sounds consistent with this SO answer too: https://stackoverflow.com/a/35254610/893991

It could be that given SceSim is not a SpringBoot-based test (doesn't need to start the spring-boot-web infra etc) then the SB configuration are not picked up as indeed that is something pertaining to Spring Boot.

On other hand, Drools, Kogito, etc. rely on vanilla SLF4J.
Given org.springframework.boot:spring-boot-starter brings Logback as the default logging implementation in the classpath (instead of say Log4j or any other logging backend), Logback does not find its vanilla configuration files (those logback.xml).
Hence, in order to properly configure Logback when non-SB unit tests are running, the standard Logback configuration is needed.
That is the most realistic explanation I could think of so far.

Hope this clarifies, thanks also Gabriele for contributing to this conversation!
MM

Gabriele Cardosi

unread,
Jul 11, 2022, 12:52:10 PM7/11/22
to Kogito development mailing list
Hi Francisco,
glad you find a "solution".
By the way, that's interesting....

Thanks

Best
Gabriele

Reply all
Reply to author
Forward
0 new messages