diff --git a/src/main/java/org/sadtech/example/swagger/config/OpenApiConfig.java b/src/main/java/org/sadtech/example/swagger/config/OpenApiConfig.java new file mode 100644 index 0000000..c092668 --- /dev/null +++ b/src/main/java/org/sadtech/example/swagger/config/OpenApiConfig.java @@ -0,0 +1,23 @@ +package org.sadtech.example.swagger.config; + +import io.swagger.v3.oas.annotations.OpenAPIDefinition; +import io.swagger.v3.oas.annotations.info.Contact; +import io.swagger.v3.oas.annotations.info.Info; + +/** + * @author upagge 30.12.2020 + */ +@OpenAPIDefinition( + info = @Info( + title = "Loyalty System Api", + description = "Loyalty System", version = "1.0.0", + contact = @Contact( + name = "Struchkov Mark", + email = "mark@struchkov.dev", + url = "https://mark.struchkov.dev" + ) + ) +) +public class OpenApiConfig { + +} diff --git a/src/main/java/org/sadtech/example/swagger/config/SwaggerConfig.java b/src/main/java/org/sadtech/example/swagger/config/SwaggerConfig.java deleted file mode 100644 index 2e555e3..0000000 --- a/src/main/java/org/sadtech/example/swagger/config/SwaggerConfig.java +++ /dev/null @@ -1,31 +0,0 @@ -package org.sadtech.example.swagger.config; - -import io.swagger.v3.oas.models.OpenAPI; -import io.swagger.v3.oas.models.info.Contact; -import io.swagger.v3.oas.models.info.Info; -import org.springframework.context.annotation.Bean; -import org.springframework.context.annotation.Configuration; - -/** - * @author upagge 30.12.2020 - */ -@Configuration -public class SwaggerConfig { - - @Bean - public OpenAPI customOpenAPI() { - return new OpenAPI() - .info( - new Info() - .title("Loyalty System Api") - .version("1.0.0") - .contact( - new Contact() - .email("mark@struchkov.dev") - .url("https://mark.struchkov.dev") - .name("Struchkov Mark") - ) - ); - } - -} diff --git a/src/main/resources/application.properties b/src/main/resources/application.yml similarity index 100% rename from src/main/resources/application.properties rename to src/main/resources/application.yml