IDEA 12.0.4 on Mac OS: not resolving ${...} placeholders!
After I have installed 12.0.4, I noticed that none of the property placeholders in my Spring config XML file are being resolved anymore. The place-holders are not high-lighted in red, but hovering the cursor over them with the Coomand button pressed (Ctrl on Windows) does not enable the cross-ref link to the value in th eproperty file. Maven resource-filtered properties are not resolved either. WTH???
Anyone else seeing this - before I file a Jira issue?
Please sign in to leave a comment.
Where are your .properties-files located? Is the directory marked as source-root?
No, it is not a question of me screwing up. I have been using IntelliJ since version 2, and Spring since 2004. Everything was properly showing in 12.0.3 - until I installed the 12.0.4 today. I have some build-specific properties defined in Maven's settings.xml. They are resolved at build time via Maven's resource filtering. IntelliJ had no problem resolving the place-holders for those properties on the fly in the editor. Doesn't do it anymore. The placeholders with the property names such as "${my.property.value}" show up as a string, not a link to the actual value - either in the .properties filer or Maven's settings.xml. The properties files in question are pointed at via a file URI, not classpath: :
{code}
<ctx:property-placeholder location="file:${conf.location}/something.properties"/>
{code}
conf.location is defined in Maven's settings.xml. It is no longer resolving. Perhaps, that is the core reason why the rest of the placeholders that point to the properties in "something.properties" are not being resolved.
In case you are wondering why I am using "file:" instead of looking up in the classpath: this is an OSGi bundle configuration, and it needs to read from a shared externalized properties file, that's why it can't use classpath (each bundle in OSGi has its own classpath invisible to other bundles.)
This looks like a regression, please file a bug http://youtrack.jetbrains.com/issues/IDEA
Done.
http://youtrack.jetbrains.com/issue/IDEA-101476
Tried 12.1 EAP, and it is even worse! The XML parsing seems to be totally messed up! All my keyword highlighting is gone. It now only highlights the XML tags, and the rest shows as plain text, no colors, no distinct fonts, still no property place-holder resolving. What are you guys doing, for crying out loud??? Please stop. This thing is deteriorating before my eyes.
Gone are the days when IDEA EAP releases where actually suitable for serious daily work... (And I do rememberthose days - up until a few years back!) Now, every time I download and start an EAP version I get an exception that keeps popping up every few seconds... Are you outsourcing in India? :-)
Did you try invalidating caches? Exception stacktrace, please?
I clicked the Submit to Jetbrains button in the dialog, and wiped out the EAP installation.
wiped out EAP installation = File | Invalidate Caches & restart ?
I mean, I removed the EAP version and went back to the 12.0.4 release.
Please try Invalidate Caches to see if the exception still occurs constantly.
I will the next time I install an EAP release and see an exception. ;) Like I said, I went back to the GA version, and have deleted the EAP installation. I am more concerned with the XML parsing thing, property resolving etc. It's a huge issue. The ability of IDEA to resolve and cross-navigate the properties on the fly allows one to instantly see a) if the placeholder refers to an existing real property; b) the actual property value; c) where the property is defined. Not being able to do any of this is a huge blow to productivity. I now can't see if I have a misspelled/non-existing property key in a place-holder - until runtime, etc. I hope this is fixed and the patch is released ASAP. In the latest EAP, the whole XML file now looks almost like plain text, except for the XML tags being highlighted. No field name or value/string highlighting.
Please don't take this as negative criticism. I have been evangelizing IDEA for over 10 years, and many of my clients (large dev teams in each case) had switched to IntelliJ based on my recommendations. I still believe it is the best Java IDE - by far. However, I see that the releases have gotten somewhat sloppier in the past few years. Actually, many people have expressed the same sentiment. Hope you guys maintain the focus on top quality. That's what IDEA has been known for.
The plain text highlighting of XML is most probably a direct effect of the exception(s) happening.
I don't agree with your observation w/r to quality decrease in general for the last major releases, could you please share your thoughts in a new thread?
Also keep in mind this disclaimer from EAP download page:
It is important to distinguish EAP from traditional pre-release software. Please note that the quality of EAP versions may at times be way below even usual beta standards.
I've been rolling back EAP installations many times for the last 10 years as well, that's the risk ;-)