• May 21, 2022

Forward proxy_pass and add CORS headers in nginx

In the recent app that I develop, there is a situation like this: The API, created with Spring Boot . The Angular app calls the API but got a CORS error. I did a few searches online and found out that I need to add additional configuration in the code. The problem is since I…

Read More

[Java Concurrency] 03: Callable

In the previous article, you’ve already known about the Runnable interface. To execute a task, you can simply create a class implement Runnable and pass an instance of that class in a thread. Runnable instances don’t provide a return value, you may need a different solution if your use case requires capturing return values. Introducing…

Read More

[Java Concurrency] 02: Runnable

One of the methods to run tasks in multiple thead is to pass Runnable instance to thread and call that start() method. Runnable is a Functional interface that has only one method that returns void. If you prefer the lambda syntax, you can write the above code like so: However, for tasks with more than…

Read More