Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

intellij - spring is not being recognized (Unmapped Spring configuration)

I am using IntelliJ IDEA and all plugins for Spring are activated, but when I load my Maven project I have the following error:

Spring Configuration Check
Unmapped Spring configuration files found.
Please configure/setup Spring facet for modules

Any ideas what prevented it from being configured automatically?

like image 578
akaliza Avatar asked Feb 27 '14 08:02

akaliza


People also ask

Why Spring is not showing in IntelliJ?

Enable Spring support in IntelliJ IDEA This functionality is not available in IntelliJ IDEA Community Edition and IntelliJ IDEA Edu. Press Ctrl+Alt+S to open the IDE settings and select Plugins. Open the Installed tab, search for Spring and make sure that the checkboxes next to all relevant plugins are selected.

Can not see Spring Initializr in IntelliJ?

If you only have IntelliJ IDEA CE then you can still create Spring Boot applications. First generate your project directory using https://start.spring.io and then import into IntelliJ IDEA and off you go. Show activity on this post. Show activity on this post.

How do I enable Spring assistant in IntelliJ Community Edition?

You can't enable Spring support with IntelliJ community Edition, it only available with paying version (Ultimate). However, you can create the . xml file manually and CE version also supports it (a little bit).


2 Answers

You need to do the following:

  1. Go to the project structure dialog (either by clicking the warning or through file=>project structure
  2. select the modules item in the left hand list
  3. go through and right click on the modules with missing files and select Add=>Spring
  4. in the new tab click the + button
  5. you should now see a list of the xml files. Check the boxes next to them

It's not entirely clear to me what this achieves apart from getting rid of the warnings! If anyone could shed any light on that it'd be good.

like image 92
JonnyRaa Avatar answered Sep 17 '22 20:09

JonnyRaa


You need to check which configurations IntelliJ will use to provide inspections on wired beans.

Go to FileProject StructureProject SettingsModules.

Select your module and selected (or add) the Spring facet.
In the right area you can add or modify application contexts that are used by your module. Just check every configuartion you need in your context.

like image 29
Bart Avatar answered Sep 17 '22 20:09

Bart