blaze-persistence
blaze-persistence copied to clipboard
Custom id mapping leads to startup error
A mapping like
@EntityView(Link.class)
public interface LinkView extends Id {
@IdMapping("this")
@JsonIgnore
Id getId();
@EntityView(Link.class)
public interface Id {
String getName();
String getUrl();
}
}
Fails with
Caused by: java.lang.IllegalArgumentException: There are error(s) in entity views!
Invalid id attribute mapping for embeddable entity type 'com.daniel.test.domain.Link' at attribute id[com.daniel.test.view.LinkView.getId] for managed view type 'com.daniel.test.view.LinkView'!
Invalid id attribute mapping for embeddable entity type 'com.daniel.test.domain.Link' at attribute id[com.daniel.test.view.LinkUpdateView.getId] for managed view type 'com.daniel.test.view.LinkUpdateView'!
See here for details: https://github.com/Blazebit/blaze-persistence/issues/1442