This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const versionRegex = /version = '(\d+\.\d+\.\d+)'/; | |
| const gradleFile = 'build.gradle'; | |
| const gradleFileUpdater = { | |
| filename: gradleFile, | |
| updater: { | |
| readVersion: contents => { | |
| const match = contents.match(versionRegex); | |
| if (match && match[1]) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const versionRegex = /version = '(\d+\.\d+\.\d+)'/; | |
| const gradleFileUpdater = { | |
| filename: 'build.gradle', | |
| updater: { | |
| readVersion: contents => { | |
| const match = contents.match(versionRegex); | |
| if (match && match[1]) { | |
| return match[1]; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package ch.exq.triplog.server.util.json; | |
| import javax.xml.bind.annotation.adapters.XmlAdapter; | |
| import java.time.LocalDateTime; | |
| import java.time.format.DateTimeFormatter; | |
| public class JsonDateTimeAdapter extends XmlAdapter<String, LocalDateTime> { | |
| private static final DateTimeFormatter FORMATTER = DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm:ss"); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import javax.enterprise.inject.Produces; | |
| import javax.enterprise.inject.spi.InjectionPoint; | |
| import org.slf4j.Logger; | |
| import org.slf4j.LoggerFactory; | |
| public class LoggerProducer { | |
| @Produces | |
| public Logger produce(InjectionPoint injectionPoint) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public enum HttpHeader { | |
| AUTHORIZATION("Authorization"), | |
| AUTHENTICATION_TYPE_BASIC("Basic"), | |
| X_AUTH_TOKEN("X-AUTH-TOKEN"), | |
| WWW_Authenticate("WWW-Authenticate"), | |
| X_FORWARDED_FOR("X-Forwarded-For"), | |
| PROXY_CLIENT_IP("Proxy-Client-IP"), | |
| WL_PROXY_CLIENT_IP("WL-Proxy-Client-IP"), | |
| HTTP_CLIENT_IP("HTTP_CLIENT_IP"), | |
| HTTP_X_FORWARDED_FOR("HTTP_X_FORWARDED_FOR"); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import java.util.concurrent.ExecutionException; | |
| public interface FutureCallback<CallbackType, FutureType> { | |
| public CallbackType work(FutureProvider<FutureType> futureContainer) throws InterruptedException, | |
| ExecutionException; | |
| } |