Better HN
topnewbestaskshowjobs
Log inSign up

sken

4 karma · joined Aug 25, 2012 (14y ago) · 3 submissions

Submissions

comment 8y ago · link · parent

But the client already had to consider what data it needed.

The only difference is that in a REST world it needed to make several calls to fetch all the data (often waiting for resource references in the nth response before being able to build the (n+1)th query) whereas now it can fetch them all in a single query.

So if anything it reduces the client complexity, as well as making it much easier to extend the API to support new client requirements without having to resort to REST-style versioning.

comment 11y ago · link · parent

Definitely, although there can also be refactoring benefits to look out for. In the article example it would be much easier to change the default popup window size (800x800) across the project if they're all using the same variable.

On the other hand, tools like CheckStyle can make people do some strange things when they take it too literally.

I once reviewed code that defined: static final int ONE_HUNDRED = 100;

comment 13y ago · link · parent

To be fair he's posting about it on an internet forum so he probably _could_ care less.