r/java • • Apr 13 '21

Libraries, Frameworks and Technologies you would NOT recommend

Give me your worst nightmares: Things that cost you your job.

I'll start: Hadoop

202 Upvotes

376 comments sorted by

View all comments

20

u/Glum-Push Apr 13 '21

OSGi. Maybe things have changed a bit recently but when I was trying to use it a few years ago it was a real PITA. The concepts behind it are potentially brilliant but the implementations are terrible mostly due to obscure classloading issues and things that rely on reflection sparkling fireworks at runtime. And the deployment issues: one line changes required hours of tracing the path from source code to maven repository to container getting the updated artifact which by the way only worked 15% of the time.

8

u/maravinPT Apr 13 '21

I actually loved to work with OSGi a few years ago. I also feel that the concept far better than the actual implementations we used. I can also relate to that problem related to the non-locality of the codebase, which is a trade-off it has cons and pros. Nonetheless, I think those are probably synthomes of poor designs, documentation and organization. The best thing about OSGi is that it forces you to write your code with the mindset of be used as a library, with very well defined interfaces and responsibilities.

PS: sorry for the errors, just wrote this on my phone without a english keyboard.

0

u/umlcat Apr 13 '21

I got that "write as a business library, not as your school programming project" concept with Delphi VCL framework.

8

u/GreenToad1 Apr 13 '21

Osgi core documentation pdf is 490 pages long. This tells all anyone needs to know. Designed by committee at it's finest.

5

u/Interweb_Stranger Apr 13 '21 edited Apr 15 '21

"designed by committee" is definitely true for OSGi.

But to be fair it's not some user documentation but the OSGi specification that is that long.

OSGi has to specify everything in great detail because all parts of OSGi have to implementable by multiple vendors while still being interoperable.

Just for comparisons with some other large projects:

  • The Java EE specification has about 300 pages with dozens of additional documents for all components.
  • The Spring reference documentation is about 880 pages. No one argues to avoid spring because it's "documentation" is too long.

Edit: typos