Ranter
Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
Comments
-
Make a wrapper, and hand it over. Fuck the client with inexplicable and unrealistic requirements.
-
lotd79227ySo basically a catch-all route that builds table name from Uri segments and returns 200 aka everything is fine, move along
-
Froot75547yCopy paste the API but change so it answers 404 to everything even if it's fine.
I like to watch the world burn -
xyl0o1397y@ClemFrieckie i have to run next door and ask where to join this id. And just for the lulz no consistent naming scheme
-
ebroda1857ySo just why do it?
They Seem to have an API that works. So why replace the old one if the API is not allowed to change? :) -
@ClemFrieckie Active record style? Zero joins, just requery the next table using a where in or where exists clause.
I really dislike it, but it's quite popular in Ruby on Rails and Laravel — and for straightforward crud APIs where every endpoint refers to one table it usually works. Until you need to do complex statistical queries... -
Even as a student there is a time to stand up and fight! It's your time to shine tell them you can do better
-
whenever I get upset with the OScommerce1-mutant-frankenkrakken which I've inherited, I remind myself that someone has it worse.
Today, you are that someone.
Related Rants
Task:
- Replace a 4 year old PHP API.
Old API:
- PHP script writing PHP scripts to /var/www/ for every endpoint needed
- Answers everthing with 200 (not even 404)
DB:
- MySQL 5.6
- ~ 1000 Tables, NO FUCKING FK's
Documentation:
- "Wasn't worth the effort"
New API:
- Not allowed to behave any different
.
.
.
ðŸ˜
undefined
why?
api design
mysql
php