Skip to content

spring-configuration-metadata : when two properties have the same Object type F3 fails on the later ones #1031

@space88man

Description

@space88man

Describe the bug
When @ConfigurationProperties has more than one field of the same non-primitive type, F3 navigation fails on the later(lexicographic) ones.

To Reproduce
Editor -> application.yml -> press F3 on property

Observe:

  • app3, app3.service1.** - navigates with F3
  • app3.service2 - does not navigate
  • rename service2 to service0: now app3.service0 navigates but app3.service1 stops working

Sample
gh-sts4-sampleV2.zip
We add a primitive type field to app3, OTW it won't navigate see #1030

app3: value: true service1: host: 1.2.3.4 port: 5000 service2: host: 1.2.3.4 port: 5000 
@ConfigurationProperties(prefix = "app3") public class Settings3 { public static class Endpoint { private String host; private int port; public String getHost() { return host; } public void setHost(String host) { this.host = host; } public int getPort() { return port; } public void setPort(int port) { this.port = port; } } private Endpoint service1; private Endpoint service2; private boolean value; public Endpoint getService1() { return service1; } public void setService1(Endpoint service1) { this.service1 = service1; } public Endpoint getService2() { return service2; } public void setService2(Endpoint service2) { this.service2 = service2; } public boolean isValue() { return value; } public void setValue(boolean value) { this.value = value; } } 

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions