swagger-codegen-generators icon indicating copy to clipboard operation
swagger-codegen-generators copied to clipboard

Revert "added logback xml config file"

Open Artur- opened this issue 3 years ago • 2 comments

Libraries should not contain logging configuration. They interfere with application logging configurations.

This reverts commit 6a0629aaaa7b1aa90dd035db91252a760f1edd48.

Fixes #956

Artur- avatar Sep 10 '21 11:09 Artur-

How about this @HugoMario? If you try to use any Swagger version newer than 1.0.20 it eats all Spring Boot log output

Artur- avatar Oct 06 '21 12:10 Artur-

This has soon been broken now for a year. Can we remove the logback file? Does it break anything else if it is removed?

You can see the problem pretty clearly if you

  1. Open https://start.spring.io/
  2. Download
  3. Run mvn spring-boot:run and watch the output
  4. Stop Spring Boot and add the dependency
<dependency>
    <groupId>io.swagger.codegen.v3</groupId>
    <artifactId>swagger-codegen-generators</artifactId>
    <version>1.0.34</version>
</dependency>
  1. Run mvn spring-boot:run and watch the output

Without Swagger the output is

[INFO] --- spring-boot-maven-plugin:2.7.2:run (default-cli) @ demo ---
[INFO] Attaching agents: []

  .   ____          _            __ _ _
 /\\ / ___'_ __ _ _(_)_ __  __ _ \ \ \ \
( ( )\___ | '_ | '_| | '_ \/ _` | \ \ \ \
 \\/  ___)| |_)| | | | | || (_| |  ) ) ) )
  '  |____| .__|_| |_|_| |_\__, | / / / /
 =========|_|==============|___/=/_/_/_/
 :: Spring Boot ::                (v2.7.2)

2022-08-10 09:05:58.355  INFO 96007 --- [           main] com.example.demo.DemoApplication         : Starting DemoApplication using Java 17.0.1 on hostname.com with PID 96007 (/directory/demo/target/classes started by user in /directory/demo)
2022-08-10 09:05:58.356  INFO 96007 --- [           main] com.example.demo.DemoApplication         : No active profile set, falling back to 1 default profile: "default"
2022-08-10 09:05:58.559  INFO 96007 --- [           main] com.example.demo.DemoApplication         : Started DemoApplication in 0.337 seconds (JVM running for 0.462)
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------

With Swagger it is

[INFO] --- spring-boot-maven-plugin:2.7.2:run (default-cli) @ demo ---
[INFO] Attaching agents: []

  .   ____          _            __ _ _
 /\\ / ___'_ __ _ _(_)_ __  __ _ \ \ \ \
( ( )\___ | '_ | '_| | '_ \/ _` | \ \ \ \
 \\/  ___)| |_)| | | | | || (_| |  ) ) ) )
  '  |____| .__|_| |_|_| |_\__, | / / / /
 =========|_|==============|___/=/_/_/_/
 :: Spring Boot ::                (v2.7.2)

[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------

Artur- avatar Aug 10 '22 06:08 Artur-