spring-hateoas icon indicating copy to clipboard operation
spring-hateoas copied to clipboard

#232: modified the AnnotationRelProvider so it can look on the controlle...

Open jstano opened this issue 11 years ago • 7 comments
trafficstars

...r for the @Relation annotation in addition to the entity

jstano avatar Aug 26 '14 16:08 jstano

Any chance you clearly describe the use case you'd like to see this change fix? Generally speaking, simple code changes without test cases are not gonna cut it anyway.

odrotbohm avatar Feb 10 '15 14:02 odrotbohm

I don't feel that putting spring-hateoas annotations on the entities, i.e. a backend class, is a good thing to do, since it couples the entity to the spring-hateoas library. By allowing the annotation to be put on the Controller, this keeps the application services layer clean and not dependent on the rest endpoint layer.

jstano avatar Feb 10 '15 14:02 jstano

Good point. Should we rather tweak ControllerRelProvider to consider @Relation, too, then?

odrotbohm avatar Feb 10 '15 14:02 odrotbohm

Yes, that is what we did in our forked branch.

jstano avatar Feb 10 '15 14:02 jstano

Would you mind updating the pull request accordingly?

odrotbohm avatar Feb 27 '15 15:02 odrotbohm

Will do.

jstano avatar Feb 27 '15 15:02 jstano

@jstano Please sign the Contributor License Agreement!

Click here to manually synchronize the status of this Pull Request.

See the FAQ for frequently asked questions.

pivotal-issuemaster avatar Dec 17 '18 18:12 pivotal-issuemaster