title: Spring logging and application.properties
body: <p>the following question may seem stupid to many, since it should have a simple solution, but I am a beginner in the Spring framework, and I have been searching and testing many methods with no success. </p>
  
  <p>So, I need to implement logging for a Web Service based on Spring. Maven is used for dependencies, with the <code>spring-boot-starter-ws</code> dependency, and not the whole starter-web starter.</p>
  
  <p>I tried with log4j, by adding a dependency and config file, and it does produce a log file, but only for the initialization of the logger itself, and no logging about when the service is used, although log4j is in TRACE level.
  I also tried with logback, by adding the logback.xml file, and adding the starter-logging dependency, but that also creates empty log files with nothing on them.</p>
  
  <p>In the Spring boot documentation, the <code>application.properties</code> file is mentioned. So I created this in WEB-INF, and put the <code>logging.level.org.springframework</code> and the <code>logging.path</code> entries. But still no log file created at all.</p>
  
  <p>I don't want to log my own messages, I just want to log the events generated by Spring itself. And I also don't have a main method, only an Endpoint for the web service, if any of these might be relevant. So what I need is the simplest possible logging, possibly without adding too many dependencies or so, and retrieve the Spring messages into the log. Can someone tell me what am I doing wrong?</p>