r/programming • • Aug 15 '22

Event Driven Architecture — 5 Pitfalls to Avoid

https://medium.com/wix-engineering/event-driven-architecture-5-pitfalls-to-avoid-b3ebf885bdb1
57 Upvotes

46 comments sorted by

View all comments

Show parent comments

4

u/Zardotab Aug 15 '22 edited Aug 15 '22

A Buzzword Engine that empowers resumes, but not real projects. The vast majority of in-house things people claim microservices improve could be more easily done with stored procedures. Your apps probably already use an RDBMS so you don't have to hook in new communication layers to use stored procedures, and you get A.C.I.D. compliance without reinventing a database, something microservices can struggle with. If your product is cat videos, it may not matter if you lose a few pussies🐈, but for important products it matters.

Warning, rant ahead...

I get pissed when youngbies reinvent true and tried shit to chase fads. My git-off-my-lawn finger bigly twitches when I see that shit. Being a Bullshit Cop is not popular, but necessary. It's why companies like to fire old people: they know what's really going on. Sticking fads in your wares may attract new hires, but makes for shitty software.

7

u/[deleted] Aug 15 '22

ACID is dead. We use a NoSql B.A.S.Ed db with a native GraphQL layer on top. Our shit is literally on fire!

2

u/Zardotab Aug 15 '22 edited Aug 16 '22

See my edit above about cat videos.

Our shit is literally on fire!

Maybe not in a good way. [Edited.]

1

u/[deleted] Aug 15 '22

I should have added the /s

1

u/[deleted] Dec 15 '22

[removed] — view removed comment

1

u/[deleted] Dec 15 '22

Well said. The software engineering industry is very good at throwing out baby's with bathwater.

5

u/DrunkensteinsMonster Aug 15 '22

This is word salad. A stored procedure isn’t really like a microservice in any meaningful sense. People hate stored procedures because it takes something stateless and makes it stateful, isn’t easily versioned, and requires a database migration to update. All annoyances.

2

u/Zardotab Aug 15 '22 edited Aug 15 '22

This is word salad.

I reviewed my writing, and don't see where the problem is myself. I will make minor edits to hopefully improve it a tad.

People hate stored procedures because it takes something stateless and makes it stateful

Please elaborate, perhaps with a sample. Do note that stored procedures do not have to change data.

isn’t easily versioned,

Database objects are perfectly capable of being versioned. Any org big enough to use microservices should also be big enough to use RDBMS versioning tools. If you have schemas that change, you should version them.

0

u/DrunkensteinsMonster Aug 15 '22

Do note that stored procedures do not have to change data.

I know that. You might get more good faith responses if you didn’t talk to people like they are idiots.

3

u/Zardotab Aug 15 '22

Where did I write wrong? I have Asbergers, so sometimes I don't spot my own "non-social" sins.

Note that the person who called my writing "word salad" was rude, yet they got scored upward. Double standard?

3

u/DrunkensteinsMonster Aug 15 '22

That was me. It is word salad because stored procedures have no relation to microservices but you went on a rant about how instead of microservices you should use stored procs. You did not explain how there is any congruence between those two things, when most would say they are orthogonal. You can write a microservice that uses a stored proc, you can write a stored proc that is used in a non-microservice architecture.

3

u/Zardotab Aug 15 '22 edited Aug 15 '22

I've asked for a clear definition of "microservices" multiple times in the past, and get answers all over the place. Some emphasize independent versioning/deployability, others scaling, others independent sub-teams, others say it's about partitioning the database, others say it's about JSON-connected-services, etc.

Stored procedures handle roughly 3/4 of the answers supplied.

I'll add my own: it's about bullshitting to get more money via complexity-fueled job security.

Warren Buffett has often ranted about investment industry fads, and he has the results to show he knows what he's talking about. It appears IT is similarly infested with fads.

2

u/DrunkensteinsMonster Aug 15 '22

You’ve gone from “stored procedures can do anything a microservice can do” to “what is a microservice?” Not very convincing.

You still have not explained how it is true in any way, were you planning on doing that? Your assertions are literally all over the place, you are writing as if you are on some sort of stimulant.

2

u/Zardotab Aug 16 '22 edited Aug 16 '22

I didn't want to start off the conversation turning it into a debate over the definition of microservices because based on past experience such careens the discussion out of control into what's known as a Laynes Law traffic jam in some circles.

However, I will reiterate that stored procedures can do roughly 80% of the features/characteristics often attributed to microservices (for internal usage), and be simpler to implement. I'd be happy to explore a specific but typical scenario and compare M to SP solution(s). That's usually more fruitful than definition debates; I'm just the messenger. I've been in thousands of tech discussions/debates. Definition debates rarely get anywhere. Pick YOUR favorite working definition and show how M's are better than SP's for it.

I will agree that if your shop uses myriad brands of RDBMS, then SP's lose some of their simplicity because database connections to extra brands may have to be included in apps. But most shops have a preferred RDBMS brand.

And more RDBMS vendors are offering easy-to-set-up JSON interface adaptors so one doesn't have to connect to a database to use an SP service. JSON is slowly becoming the "new ODBC/JDBC".