<instructions>Your goal is to analyze the following comment and estimate how highly it will be upvoted by the Hacker News community.</instructions><comment><author>robzhu</author><text>You might want to check out GraphQL: &lt;a href=&quot;http:&amp;#x2F;&amp;#x2F;graphql.org&amp;#x2F;&quot; rel=&quot;nofollow&quot;&gt;http:&amp;#x2F;&amp;#x2F;graphql.org&amp;#x2F;&lt;/a&gt;. One of its killer features is the ability for clients to specify exactly the data it needs and obtain it in a single request&amp;#x2F;response.</text><parent_chain><item><author>PaulHoule</author><text>This misses the elephant in the room.&lt;p&gt;The REST-inspired API that requires 10,000 API calls to do something that could be done in 1.  This is a disaster from a simple performance perspective.&lt;p&gt;There is no simple way to build transactions on top of REST so if you need to do something that involves updating more than one data record you really are best off updating them all in one API call.&lt;p&gt;When you are writing a web front end this is all the more acute because choreographing a complex interaction with a server is a PITA with asynchronous communications.&lt;p&gt;If Fielding&amp;#x27;s thesis went in the trash and got replaced with &amp;quot;one click,  one API call,  update the UI&amp;quot; we&amp;#x27;d hear a lot less carping about how awful the web platform is.&lt;p&gt;Careful reading of the http spec is a road to hell anyway because 80% of it is dark corners that aren&amp;#x27;t really used or implemented.</text></item></parent_chain></comment><story><title>REST Anti-patterns</title><url>http://marcelo-cure.blogspot.com/2016/09/rest-anti-patterns.html</url></story>
<instructions>Your goal is to analyze the following comment and estimate how highly it will be upvoted by the Hacker News community.</instructions><comment><author>drj077</author><text>How I&amp;#x27;ve addressed the transaction issue in the past is to expose it specifically as a transaction. For instance, POST &amp;#x2F;posts&amp;#x2F;transactions would contain a list of transformations to &amp;#x2F;posts and will receive a transaction id as a response. The id can be polled for success (&amp;#x2F;posts&amp;#x2F;transactions&amp;#x2F;:uuid) or results can be pushed to a browser. It is more work to be able to roll that back if one fails, but that&amp;#x27;s a coding issue not so much an API one.&lt;p&gt;I&amp;#x27;d love some feedback on this approach. How do other people allow efficient mass changes?</text><parent_chain><item><author>PaulHoule</author><text>This misses the elephant in the room.&lt;p&gt;The REST-inspired API that requires 10,000 API calls to do something that could be done in 1.  This is a disaster from a simple performance perspective.&lt;p&gt;There is no simple way to build transactions on top of REST so if you need to do something that involves updating more than one data record you really are best off updating them all in one API call.&lt;p&gt;When you are writing a web front end this is all the more acute because choreographing a complex interaction with a server is a PITA with asynchronous communications.&lt;p&gt;If Fielding&amp;#x27;s thesis went in the trash and got replaced with &amp;quot;one click,  one API call,  update the UI&amp;quot; we&amp;#x27;d hear a lot less carping about how awful the web platform is.&lt;p&gt;Careful reading of the http spec is a road to hell anyway because 80% of it is dark corners that aren&amp;#x27;t really used or implemented.</text></item></parent_chain></comment><story><title>REST Anti-patterns</title><url>http://marcelo-cure.blogspot.com/2016/09/rest-anti-patterns.html</url></story>