Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

no-janino conditions #757

Open
guai opened this issue Dec 29, 2023 · 4 comments
Open

no-janino conditions #757

guai opened this issue Dec 29, 2023 · 4 comments

Comments

@guai
Copy link

guai commented Dec 29, 2023

Feature request:
pls make possible to write conditions without janino.
it should allow to use conditions with native image for example.

I suggest something like a predicate-like interface that user would implement and use like so:

<if predicateClass="org.example.MyCondition">

or it could be a static method

@danparisi
Copy link

I'd also be very happy to get this feature. Without it, running spring boot native images force you to remove if conditions from spring-logback file. More info here

@DarkAtra
Copy link

DarkAtra commented Sep 9, 2024

Hey @ceki, i'm reaching out to you because you initally recommended filing an issue for this feature in this comment.
We're currently in the process of migrating a few of our apps to native images and stumbled upon this issue. We're currently using Janino conditions to enable different types of sinks for our logs (kafka, tcp, file, console, ...) and also their format (JSON lines vs. formatted log lines). As you know, Janino is not compatible with GraalVM which makes this a blocker for our migration.

What do you think of the solution that guai proposed? Is this something that you would accept PRs for?

@ceki
Copy link
Member

ceki commented Sep 9, 2024

@DarkAtra I have responded in the original issue. Please let me know what you think.

Also, the next version of logback-tyler will support PropertiesConfigurator (new in logback 1,5,8) which allows setting logger levels from a properties file.

@DarkAtra
Copy link

DarkAtra commented Sep 9, 2024

@DarkAtra I have responded in the original issue. Please let me know what you think.

Also, the next version of logback-tyler will support PropertiesConfigurator (new in logback 1,5,8) which allows setting logger levels from a properties file.

This looks very promising, i'll try with one of our projects. Ty for the quick response!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants