title: Spring Boot disable Spring Batch info level logging
body: <p>I have a Spring Boot application which runs a Spring Batch job at regular intervals from a Quartz Scheduler.  Every time the job runs information about it is always logged as shown below:</p>
  
  <pre><code>Sep 16, 2019 5:01:56 PM org.springframework.batch.core.launch.support.SimpleJobLauncher$1 run
  INFO: Job: [SimpleJob: [name=testJob]] launched with the following parameters: [{jobRunTime=1568649716469}]
  Sep 16, 2019 5:01:56 PM org.springframework.batch.core.job.SimpleStepHandler handleStep
  INFO: Executing step: [publishRequests]
  Sep 16, 2019 5:01:56 PM org.springframework.batch.core.launch.support.SimpleJobLauncher$1 run
  INFO: Job: [SimpleJob: [name=testJob]] completed with the following parameters: [{jobRunTime=1568649716469}] and the following status: [COMPLETED]
  </code></pre>
  
  <p>How can I prevent this from being logged?  I am using slf4j  with log4j2 for logging.  I tried adding this line to my logging properties file so only error messages are logged but this did not work:</p>
  
  <pre><code>logging.level.org.springframework.batch=ERROR
  </code></pre>
  
  <p>I am using Spring Boot 2.1.2 with Spring Batch 4.1.1.</p>
  
  <p>Here are the dependencies in my log file:</p>
  
  <pre><code>            &lt;dependency&gt;
                  &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
                  &lt;artifactId&gt;spring-boot-starter&lt;/artifactId&gt;
                  &lt;version&gt;${spring-boot.version}&lt;/version&gt;
                  &lt;exclusions&gt;
                      &lt;exclusion&gt;
                          &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
                          &lt;artifactId&gt;spring-boot-starter-logging&lt;/artifactId&gt;
                      &lt;/exclusion&gt;
                  &lt;/exclusions&gt;
              &lt;/dependency&gt;
  
              &lt;dependency&gt;
                  &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
                  &lt;artifactId&gt;spring-boot-starter-log4j2&lt;/artifactId&gt;
                  &lt;version&gt;${spring-boot.version}&lt;/version&gt;
              &lt;/dependency&gt;
  
              &lt;dependency&gt;
                  &lt;groupId&gt;org.slf4j&lt;/groupId&gt;
                  &lt;artifactId&gt;slf4j-api&lt;/artifactId&gt;
                  &lt;version&gt;${slf4j.version}&lt;/version&gt;
              &lt;/dependency&gt;
  
              &lt;dependency&gt;
                  &lt;groupId&gt;org.slf4j&lt;/groupId&gt;
                  &lt;artifactId&gt;slf4j-jcl&lt;/artifactId&gt;
                  &lt;version&gt;${slf4j.version}&lt;/version&gt;
                  &lt;exclusions&gt;
                      &lt;exclusion&gt;
                          &lt;groupId&gt;commons-logging&lt;/groupId&gt;
                          &lt;artifactId&gt;commons-logging&lt;/artifactId&gt;
                      &lt;/exclusion&gt;
                  &lt;/exclusions&gt;
              &lt;/dependency&gt;
  </code></pre>
  
  <p>I use the following properties for my logging in a log file called logging.properties:</p>
  
  <pre><code>
      handlers= java.util.logging.FileHandler
  
      .level= INFO
  
      java.util.logging.FileHandler.pattern = myApp.log
      java.util.logging.FileHandler.limit = 10000000
      java.util.logging.FileHandler.count = 20
      java.util.logging.FileHandler.formatter = java.util.logging.SimpleFormatter
  
      java.util.logging.ConsoleHandler.level = SEVERE
      java.util.logging.ConsoleHandler.formatter = java.util.logging.SimpleFormatter
  
  
      java.util.logging.SimpleFormatter.format=[%1$tc] %4$s %2$s: %5$s %n
  
      logging.level.org.springframework.batch=ERROR
  
  </code></pre>