Can i send multiple objects in POST and PUT http endpoints. I have 50 objects which i need to insert or update in database. The recommendation from the technical fellow group here is to make 50 calls and insert/update individual elements. In this case how does my Front-end application perform?.
Asked
Active
Viewed 50 times
0
-
2Possible duplicate of [RESTful way to create multiple items in one request](http://stackoverflow.com/questions/411462/restful-way-to-create-multiple-items-in-one-request) – Tim Jun 02 '16 at 14:25
-
Your goal is to be more performant ? or you really want to send multiple objects in one call ? – EmCode Jun 02 '16 at 14:26
-
My goal is to be more performant but without suppressing the REST principles – arun thatham Jun 02 '16 at 14:31
1 Answers
0
Your technical fellow group IMHO is wrong, rest is not about sending one or many objects, from your description your application could be a classical RPC application, that sends objects and receives objects (encoded as json) and that someone called REST because uses HTTP. Rest is more about being stateless and links (HATEOAS) presented to the client in the response.
So send as much objects as you want, if you can.
Can you ? Just wondering if the actual problem is that there is no URL to send many objects to so they told you send one by one ;-)

Testo Testini
- 2,200
- 18
- 29