3 ms·
The classpath is one of my favorite things about the JVM. In my experience, it's a great way to unambiguously specify what to load. Just look at the horrible m
by jcromartie 16y ago
The classpath is one of my favorite things about the JVM. In my experience, it's a great way to unambiguously specify what to load.
Just look at the horrible mess that is ASP.NET assembly loading: you've got the bin/ directory, Temporary ASP.NET Files, and the Global Assembly Cache all competing when you load libraries.
- jacquesm 16y agoIt's great when it works as expected. Woe to you if your cron job happens to get started with a different CLASSPATH set compared to your regular log in (just one example).
- jbooth 16y agoYeah, but even when it's hard to work with, it's still waaaay easier than ld/gcc, IMO at least. I mean, try to resolve different versions of libraries in Java, it's not easy, but in C, it's hard. Gems and eggs and CPANs or whatever tend to have a lot of the same problems.. turns out it's a hard problem to solve. In Javaland, we at least have Maven :)
- jacquesm 16y agold -static is your friend. I've used that many times for stuff that I need to deploy across different releases of the same OS that as a rule have their devtools removed for security reasons. My development system is typically geared towards desktop use (ubuntu atm), the servers run either redhat, debian or some other flavor and the static trick gives you a slightly bigger executable but the upside is that it is simply drop in and go.
- jbooth 16y agoYou mean like mvn assembly? :) I agree on static linking being almost always worth it, of course.