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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T06:45:59+00:00 2026-06-13T06:45:59+00:00

private static final Logger LOGGER = LoggerFactory.getLogger(Updater.class); I am using SLF4J and Logback When

  • 0
private static final Logger LOGGER = LoggerFactory.getLogger(Updater.class);

I am using SLF4J and Logback

When I try to log statements

LOGGER.info("{}:{}:{}", one, two, three)

it says

cannot find symbol method info(java.lang.String,java.lang.String,java.lang.String,java.lang.String)

Is there not any way I can log more than two variables in a single info statement?

  • 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-13T06:46:01+00:00Added an answer on June 13, 2026 at 6:46 am

    You must upgrade SLF4J to 1.7 which includes Logger.info(java.lang.String, java.lang.Object...) varargs method. See Bug 31 – Varargs for Logger methods fixed after six years worth of discussion.

    Prior to 1.7 you must surround arguments with Object[] if you are using more than two:

    LOGGER.info("{}:{}:{}", new Object[] {one, two, three})
    

    See also

    • Is there a Java 1.5 varargs API for slf4j yet?
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

public class SequenceControlNumber extends SequenceGenerator { private static final Logger log = LoggerFactory.getLogger(SequenceGenerator.class); @Override
Is there any reason to do this: private static final Logger LOGGER = LoggerFactory.getLogger(Main.class);
Im using slf4j for tracing the information. My code is private static final Logger
public class CustomBlockFactory { private static final Logger logger = Logger.getLogger(TableListControllerFactory.class.getName()); public static AndroidTourController
public class SoapMessageProcessor { private EntityManager em; private static final Logger logger = Logger.getLogger(SoapMessageProcessor.class);
I am using Apache Common Logging in Desktop Application. private static final Log log
I've always used the following pattern to construct (SLF4J) loggers: private static final Logger
I have own connection pool: public final class ConnectionPool { private static final Logger
I first thought about using ITDs to define the private static final Logger logger
Given the following multiton: public class Multiton { private static final Multiton[] instances =

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.