Mark Baker is another blogger I would read with greater frequency if he had an RSS feed. Here he identifies himself as an extremist. Mark, I have a question for you.
Perhaps the most cherished axiom of the REST architecture is that GET must not have side effects. This is even codified in the standard. Now a Google query is darn near the canonical example of a HTTP GET, right? To do such a query via a POST would be, well, a Gaffe of the first order, no? Of such a magnitude that the only appropriate course of action is to gather together a fellowship of like-minded Hobbits, Dwarves, Elves and men and go on a quest to educate the world.
Now it turns out that the Google API has a limit of a 1,000 queries per day. This means that the 1,001st query will not have the same result as the 1,000th query. The query itself has a (GASP!) side effect. It is most decidedly not idempotent. So what do you do? Call back the Hobbits and recode to use POST, or do you make the pragmatic decision to slightly bend the rules a bit?
Inquiring minds want to know.
P.S. Thanks go out to Nelson Minar for bringing this question to my attention.
12:09:06 PM Comment
|