This really should be a simple question, and I apologize but I just can't seem to find the answer. From my understanding you can take in an object and have it use say a bean in Java EE to produce this Object/Entity into a database. Now the problem is the ID is going to be auto-generated so the client will not know this when first being created. How do I return with the @POST in Jax-RS what there now provided URI/ID location is so they know who they are provided that ID after being created. I have read and thought this was possible but maybe I am wrong, if someone could point me in the direction of my solution.
为什么不能发送响应中填充了id的json对象?
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.