Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Example to showcase how to create a relationship between resources #23

Open
sbley opened this issue May 24, 2019 · 1 comment
Open

Example to showcase how to create a relationship between resources #23

sbley opened this issue May 24, 2019 · 1 comment

Comments

@sbley
Copy link

sbley commented May 24, 2019

The existing hypermedia example provides an overview on related resources (Employee, Manager), how to link them and evolve api.

In addition to that, I would like to see example code on how to create relationships and how to provide hypermedia links for that. Especially when it comes to many-to-many relationships.

Imagine the Employee works in different Projects, so these two resources are many-to-many.

How do we add hypermedia links to create these relationships and how are these POST/PUT requests modeled in the controllers? I would be grateful to see this in a spring-hateoas-example.

@nmwael
Copy link

nmwael commented Nov 27, 2019

Id be very interested in seeing cross service affordances between related resources.. For example how do you show that an employee can use the "resign" affordance on a specified project?

Right now im doing this by links but does not seem to be the correct way since links does not specify http method (put post etc) but affordances do, but does not support the relation text.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants