r/java • u/MrCookielove • Jan 22 '21
Java is more enjoyable than I first thought
I started my years off programming in c#, don’t ask why but I never ventured off. I learned Java this past week and I’m seriously impressed, I don’t think I’ve had a more enjoyable time programming in my life. Does anyone else share this experience??
Edit: Is there a better ide than eclipse for Java
271
Upvotes
1
u/supercargo Jan 23 '21
You seem to be missing my point, which is not a straw man at all. I’m not making a “this tool” vs “that tool” argument, so I don’t really care how you “count” usage of either tool either. Let me see if I can break it down a bit further.
Most non-trivial Java projects will depend on one or more libraries published in a Maven repository (typically central) using the Maven POM meta model
Typically those libraries will have transitive dependencies which must also be resolved in order to create build, test and run-time classpaths, which themselves have dependencies and so on
In the process of adding or changing dependencies and/or dependency versions in your own project you may find that some conflict arises. E.g. this could be a conflict between transitive dependencies of two libraries you depend on, rather than anything you did explicitly in your build tool of choice. This is sometimes known as “jar hell”
In order to reason about this situation you must understand how maven resolves dependencies regardless of what tool you use. (you may even experience this issue due to a “bug” in the way your tool uses maven metadata compared to the way Maven does so natively). You are inheriting the problem from your dependencies which are distributed using the maven model. Of course, the mechanism you use to solve the problem (e.g. locking down a version number) will depend on your own tool choice.
So all I’m saying is that the Maven model for artifact distribution (in specific, not just in concept) is a baggage that is carried by he majority of Java projects. As a consequence we are stuck with any shortcomings that model has, especially in situations which require actually understanding what our tools are doing and why. This will remain generally true unless/until maven-distributed artifacts are reduced to an uncommon curiosity.