Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8784017
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T20:58:36+00:00 2026-06-13T20:58:36+00:00

Idea is to make an ability to change logback configuration without redeploy. Slf4j and

  • 0

Idea is to make an ability to change logback configuration without redeploy.
Slf4j and logback are used in project. logback.xml file is in ear, but it reads some properties from property file, which is placed out of ear.
Something like that:

<configuration scan="true" scanPeriod="5 seconds">
<property file="${logconfig}"/>

<appender name="STDOUT" class="ch.qos.logback.core.ConsoleAppender"> 
    <encoder>
        <pattern>${logback.consolePattern}</pattern>
    </encoder>
</appender>
<root level="DEBUG">
    <appender-ref ref="STDOUT" />
</root>

</configuration>

Problem is that scan checks if logback.xml was changed (and file always the same). That’s why changing values in property file doesn’t changes configuration of logback. Changes are applied only after redeploy.

So what is the best way to have an ability to modify logback configuration without redeploy? Is there some mechanism that allow to realize it?

upd: changes would be made very rarely. but they should be applied as soon as possible. performance is also important.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-13T20:58:37+00:00Added an answer on June 13, 2026 at 8:58 pm

    After some comparing I think it would be easier and more comfortable to place logback.xml out of ear.
    It can be realized by specifying system property logback.configurationFile in server configuration.
    To make editing more convenient for people I plan to define some properties in the beginning of the file. Like that

    <property name="consolePattern" value="%d{HH:mm:ss.SSS} [%thread] %-5level %logger{36} - %msg%n"/>
    

    And then use them in configuration

    <pattern>${consolePattern}</pattern>
    

    It will handle problem with dynamic changes and it is almost userfriendly ))

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a idea to make table like this 1. something1 2. something2 3.
Is it a good or bad idea to make setters in java return this?
Suggest me, is it a good idea to make changes in default Joomla code
My idea is to make an application start automatically when a message from a
Idea: I want to make smth like real time electronic blackboard. Many users have
The idea is simple. Make a struct for Departments of a store, give it
I recently had an idea to create my own String class to make using
I want to make a edit profile form for my website. My idea is
I want to make some GUI mockup program for video player, so my idea
I'm using Access 2003 and doing a make table query. The idea is, I

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.