Everytime I run a class the whole module gets build
Answered
My project is quite big. It's a Maven project made of 4 main modules.
Almost everytime (I'm not able to determine how I manage that but sometimes it acts normal) I run a class from my module "back-office", Intellij build the whole module. Even when I execute a "maven clean install" right before. My module is big and takes 20 minutes to build so it's quite a problem...
I reset Intellij settings to default.
Any help is welcomed :)
Here's my run/debug configuration :

Please sign in to leave a comment.
Hello Gabriel,
Will you face the same issue if you run "Build | Build Module" before running?
Hello,
Yesterday, the problem didn't showed up once.
This morning, I changed something I my .m2/settings.xml causing maven to "do stuff" for 20 seconds. Then I tried to run my back-office again and it started building for ages just like before.
So I stopped it. And tried to run "Build | Build Module" before running. It lasted for one minute or so. Then I ran my back-office again and it build for 15 minutes long.
Does anyone understand the situation I face ?
Gabriel,
Is it possible to share logs folder zipped ("Help | Show Log in...") after restarting IDE and reproducing the issue?
Sorry for the delay. We have similar issue on YouTrack: https://youtrack.jetbrains.com/issue/IDEA-201109. Could you please attach full logs folder zipped to it after following this steps:
1. Restart IDE
2. Run "Build | Build Module"
3. Start Run configuration.
Thanks!
I could not attach the .zip here so I did it there : https://youtrack.jetbrains.com/issue/IDEA-201109
This last two weeks, I have noticed that this problem occurres everytime after I edit my .m2/settings.xml with notepad++. Maven (within Intellij) does some background work and then when I try to run my module it builds for 15 min.
But 1) In September and October I could edit this file without causing the issue.
2) I'm pretty sure that earlier this month, the issue occurres while I had not edited my .m2/settings.xml
Other people work on this project with Intellij too and don't face the problem.
Gabriel,
Do you use any antivirus software?
Could you please check the issue with clean installation of IDEA 2018.3?
I only use Windows Defender.
I already fully uninstalled it 10 days ago and it didn't change anything.
Today I realized that the '.idea" folder might be the cause as we don't commit it (it would explain why my teamworkers don't face the issue) and I suppose (I'm not sure) that when I unistalled Intellij, this folder remained. And so when I imported my project within the brand new installation it might have been already there.
I looked into .idea/runConfigurations and compare the 4 files describing my four runnable modules but I could find no differences.
Thanks for the support by the way
Gabriel,
Could you please try to reimport project from the scratch - copy project to other location, delete .idea folder and .iml files, import project as Maven. It should recreate .idea folder and it will show if it causes the issue.
Ok, I'll do that. I don't know why I haven't think of it yet...
I'll let you know, thanks !
Gabriel,
Thanks for getting involved!
I think that it worked. I haven't face the problem again. Thank you !
Gabriel,
You are welcome!