Updated names and paths for template
This commit is contained in:
@ -0,0 +1,29 @@
|
||||
package de.twomartens.templateservice;
|
||||
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.boot.SpringApplication;
|
||||
import org.springframework.boot.autoconfigure.SpringBootApplication;
|
||||
import org.springframework.scheduling.annotation.EnableScheduling;
|
||||
|
||||
import java.util.Optional;
|
||||
|
||||
@Slf4j
|
||||
@SpringBootApplication
|
||||
@EnableScheduling
|
||||
public class TemplateServiceApplication {
|
||||
|
||||
public static void main(String[] args) {
|
||||
log.info(">>> {}:{} <<<", getTitle(), getVersion());
|
||||
SpringApplication.run(TemplateServiceApplication.class, args);
|
||||
}
|
||||
|
||||
private static String getTitle() {
|
||||
return Optional.ofNullable(TemplateServiceApplication.class.getPackage().getImplementationTitle())
|
||||
.orElse("start");
|
||||
}
|
||||
|
||||
private static String getVersion() {
|
||||
return Optional.ofNullable(TemplateServiceApplication.class.getPackage().getImplementationVersion())
|
||||
.orElse("snapshot");
|
||||
}
|
||||
}
|
||||
15
template-server/src/main/resources/log4j2.xml
Normal file
15
template-server/src/main/resources/log4j2.xml
Normal file
@ -0,0 +1,15 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Configuration status="warn" monitorInterval="30">
|
||||
<Appenders>
|
||||
<Console name="console" target="SYSTEM_OUT">
|
||||
<PatternLayout pattern="%5p %d{HH:mm:ss.SSS} (%F:%L) [%X{REQTYPE}] %m%n%xEx{full}"
|
||||
alwaysWriteExceptions="true"/>
|
||||
</Console>
|
||||
</Appenders>
|
||||
<Loggers>
|
||||
<Root level="WARN">
|
||||
<AppenderRef ref="console"/>
|
||||
</Root>
|
||||
<Logger name="de.twomartens" level="TRACE" additivity="true"/>
|
||||
</Loggers>
|
||||
</Configuration>
|
||||
Reference in New Issue
Block a user