Unresolvable Spring properties
piotrooo opened this issue · 10 comments
Detailed Description
IntelliJ reports an unresolvable property.
Context
Currently IntelliJ cannot suggest available properties. They works, but IntelliJ shows errors:
Auto-completion of the properties provided by a Spring module, could be a really good developer experience.
Possible Implementation
Metadata spring-configuration-metadata.json
should be generated instead of additional-spring-configuration-metadata.json
.
Your Environment
- Version used: 3.1.0
Hi @piotrooo
The property you want to use is logbook.minimum-status
, not logbook.status-at-least
, see relevant section in readme and the LogbookAutoConfiguration class.
Thanks for tip, that was missclick. But that in fact is a reason of this feature/fix. If my IDE suggest me correct values (based on e.g. LogbookProperties
) that kind of errors will disappear. It's gives a better developer experience.
Yes, I have suggestions from the other projects.
I using application.properties
, maybe this is a reason?
Yes, I still have this issue. It's super weird... All properties (from 3rd party libs and from the project) are working. There is only problem with logbook 😢
A little bit info about my setup:
- Java
openjdk version "17.0.7" 2023-04-18
OpenJDK Runtime Environment Temurin-17.0.7+7 (build 17.0.7+7)
OpenJDK 64-Bit Server VM Temurin-17.0.7+7 (build 17.0.7+7, mixed mode, sharing)
- Spring Boot 3.1.2
- Logbook 3.2.0
- Ubuntu 22.04.2 LTS
The only difference that I have noticed in comparison with other libs is file in a META-INF
additional-spring-configuration-metadata.json
for logbook and spring-configuration-metadata.json
for other libs.
Both additional-spring-configuration-metadata.json
and spring-configuration-metadata.json
should have worked. Maybe something to do with the annotationProcessor as described in 3.1. Configuring the Annotation Processor.
Alternatively, could you run a small experiment? Rename additional-spring-configuration-metadata.json
to spring-configuration-metadata.json
, run mvn install locally and try using the 3.4.0-SNAPSHOT
version. To verify if it's something to do with the metadata being defined in another type of the file
This should be resolved in the next release (3.5.0). Please re-open this issue if the problem is not fully addressed
I can confirm that fix solved the problem for me.