Intellij Lombok Run Error Method Not Found

Java Maven Project Lombok Intellij

This kind of error happens to me recently when I am working with microservices Spring Boot Java application. When I use git, I usually gitignore the “.idea” configuration so when I switch between different branches meanwhile the “.idea” doesn’t change because it is being ignored, then the IntelliJ does not configure the project correctly.

The solution is simply by removing the “.idea” folder, the “.iml”, IntelliJ project configuration. And reopen the project from IntelliJ. And the “target” folder, which is your java maven project build folder, some sort of caching mechanism.

Then you can open the terminal and CD to your project and simply run maven rebuild commands like the following.

All you need to do right now is to clean the project and then package your maven java project.

mvnw clean package

Now, try to run your project using the green triangle button that is usually used for running your maven project on the IntelliJ IDEA. That’s it, I hope this simple solution I discover works for you, because I have been searching on google so many times and these bugs still persist. Turns out it’s not on my project but the IntelliJ run configuration because the wrong “target” cache folder is the culprit.

If this solution still doesn’t work, you can check from stack overflow developer community about this topic here: Can't compile project when I'm using Lombok under IntelliJ IDEA.

Lombok is cool java library to make your POJO, DTO class simpler by annotating Lombok annotation so you don’t have to write your own getter, setter or constructor because if you have lots of POJOs it’s going to be mundane task, and your codes just looks ugly.

Popular posts from this blog

STOP following those self-help content, START doing your immediate tasks and responsibilities

ERROR 1348 Column Password Is Not Updatable When Updating MySQL Root Password

Spring Kafka - How to use ReplyingKafkaTemplate send and reply synchronously

How To Create Spring Boot Project Using Netbeans

ASUS Battery Health Charging Software To Make Your Battery Life Longer