Skip to content

Convert String to Money Thymeleaf

I am having a problem converting input String to money. I am creating a spring boot application with thymeleaf. I have a web page where user inputs the data and there is a particular field where he inputs the String and it needs to be converted to type joda.money as in my pojo class that field has money data …

How starter-web prevent spring-boot exit?

When using spring-boot-starter-web, The spring-boot application won’t exit after startup. And with Jetbrain IDEA, There is an icon show spring-boot start up finished: But if I using : Or Can let spring-boot keep running but the IDEA icon will loading forever, So that must be different way compare with s…

How to Use @JsonProperty With Lombok?

Suppose we have a json response that we want to map it to our java class. I had a data class that mapped access_token field in the json to accessToken field in the code. I used to use @JsonProperty annotation on getters and setters. Then I decided to use Lombok annotations @Getter and @Setter. Since I do not …

Properly set UTF-8 encoding to a FileHandler in Java

I initialize my FileHandler as follows: and add it to my Logger like this: If i remove the setEncoding on my FileHandler, its sill is wrong. But strangely, if i add the exact same Encoding to my ConsoleHandler, it stops working too. (But without the explicit set, it works at least in my IntelliJ-Console). Int…