Jorge Castro
1 min readSep 3, 2020

RESTFUL is fine for anything basic but it falls short quickly.

For example, a table with products

* /product/123 (GET get product 123)

* /product/ (GET list products)

* /product/ (POST insert or update)

etc.

But what if the table product contains 1 million of products. If you allow to list 1 million of products then you are not only killing the performance of the database but also over-using the bandwidth of the database and it is trivial to do a DDOS.

So, how to deal with it? Pagination!. For example, to get the page 10

* /product/10 However it gets the product 10.

* /product/?page=10 and finally we are giving a turnaround and we are using the URL parameters, the same reason why we decided to use RESTFUL (no parameters).

And about GRAPHQL sheesh. It is over engineering and we are exposing our database to the world, hackers don't need to hack the database anymore, we are exposing it for free!.

Long story short, CRUD is half the story, the full name is CRUDL + count.

Sign up to discover human stories that deepen your understanding of the world.

Free

Distraction-free reading. No ads.

Organize your knowledge with lists and highlights.

Tell your story. Find your audience.

Membership

Read member-only stories

Support writers you read most

Earn money for your writing

Listen to audio narrations

Read offline with the Medium app

Responses (1)

Write a response