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 4124362
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T23:43:52+00:00 2026-05-20T23:43:52+00:00

I currently have a custom log manager that internally uses java.util.Formatter . The main

  • 0

I currently have a custom log manager that internally uses java.util.Formatter. The main issue is that it’s not very usable: everything in one file per application, no possibilities to add specific logs in a database, not able to send a mail, …

So I would like to be able to increase the capabilities our logging system. After a few tests, Log4J is exactly what I need right now. But I would like to avoid the pain to re-change this again in the future, so I plan to use slf4j on top of Log4J.

Even if I’m ready to make a big search/replace in all my codebase to use slf4j, I’m not ready to check each log statement and reformat it to use the {} format of slf4j.

So my question is: how can I use slf4j interface and tell it that internally it should use a java.util.Formatter instead of its default one, preferably in one place (meaning not in each class or package)?

Notes: all answers speaking about performances or stating that I shouldn’t use j.u.Formatter will be discarded: I need a pragmatic solution to my problem, not launching a debate.

  • 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-05-20T23:43:52+00:00Added an answer on May 20, 2026 at 11:43 pm

    There is patch http://bugzilla.slf4j.org/show_bug.cgi?id=116 which can be modified to suit your needs.
    The discussion present there can also give further clarity on using util.Formatter.

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

Sidebar

Related Questions

I have a ASP.Net 2.0 website that is currently using a custom MembershipProvider and
We have a custom navigation webpart that uses the PortalSiteMapProvider of MOSS to build
I have a custom built CRM that is 99% written in Classic ASP/VBScript. Currently
I currently have a custom session handler class which simply builds on php's session
Currently I have a custom tool which generates vanilla-SQL (only using standard SQL), from
I currently have an MS Access application that connects to a PostgreSQL database via
I'd like to have access to the bytecode that is currently running or about
Hey, I'm having an issue seperating packets using a custom binary protocol. Currently the
I have a test plan that runs fine under http, and the Cookie Manager
I have a list of custom objects that I am loading into an ActivityList

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.