News for hackers. Stuff that matters.
Re:You do not need inheritance with OOP by mrkeen on Wednesday November 09, 2022 @06:41AM (#33530148)
No, nothing's changed. Spring still infects your whole codebase. Just look at the imports, or try to run your code via a different framework if you think I'm exaggerating.

It's proponents still make the same claims about it protecting you from coupling, not causing it.

Re:You do not need inheritance with OOP by coutego on Tuesday November 15, 2022 @08:18AM (#33608769)
Spring does not need to infect your codebase. You can use the container without importing anything from Spring in other than one class (the one bootstrapping the system).

If you want to use Spring classes in the implementation of your clases then yes, you will need to import them. But this is no different than any other library.

If you just use XML configuration files (or use @Configuration) you don't (shouldn't) use @Inject, @Autowire and all other abominations. Or at least you didn't need, last time I checked a couple years ago. All your code is clear, free of any Spring code (unless you use some of the libraries) and fully reusable, testable, etc.

Why everyone moved to annotations for "dependency injection" (that crap is NOT DI!!!!!), not only in Java, but Python, Typescript, etc. I just can't understand. It can't only be the convenience of doing so by saving some keystrokes, but I just can't get it. We solved the modularity beautifully with Spring (and other DI engines) and then we proceed to throw away the solution and recreate the problem again? Get off my lawn...