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
-
Depends on the use case honestly. When they literally want to pull your complete database for reasons occasionally, there is not a point in creating an API for that.
But you will always run into the issue where you cannot apply migrations which alter the table structures as your client wrote direct SQL queries which will break quite easily then. That is abstracted by the api layer, if implemented properly. 9999/1000 times it is not a good idea to give someone read access to your database, as yes, that's what your API is for and hopefully exposes only the required data. But, there is always that one edge case where it might be a good idea to do it.
Does your client specify why they want read access? -
yes, without you get no accountability (logs) when something goes wrong and it could cost your company a lot of money to fix a fuck up.
And besides working on a codebase that doesn't consume api's is no fun if something has to change. Without apis you're inflexible and probably not able to deploy your apps on distributed cloud servers. And it's basically begging to get hacked.
so yo may want to look in to the latest and greatest what api technology has to offer: GraphQl www.graphql.com www.prisma.io -
japzio76435y@EngineerCoding actually both are internal services for 2 separate products. I could understand if these are (micro)services on the same application.
-
The problem is when one of 2 apps doesn't have any APIs. And client still want an integration.
-
japzio76435y@NoToJavaScript legacy app? Probably that would be the exception temporarily but there should a plan to move that our from the old tech.
-
@japzio I think you underestimate the number of business running on 1990ish tech.
I know a big manufacturing company who still uses BAAN v5 -
@japzio no microservice should delegate it's right/ownership of his data scope !! It's a simple and easy way to couple the two services at the data level and fucking forever your hoped consistency.
So a big NO NO!!
Now inside a MapReduce system simple pulling from App/Service/Microservice to reverse inside a data warehouse or lake, why not.
Related Rants
Is granting read access to a client app a good practice? Intefrations should be done through APIs, jms and the like, right? My opinion is it should be a no no to do the integration on the database layer bypassing the app even if both apps are internal service which are completely different products. opinions are much appreciated.
question
database
integration
security
api design