Where is Java’s CPAN?

by Jack Hughes on February 15, 2008

If you're new here, you may want to subscribe to my RSS feed. Not sure how to subscribe to a RSS feed? Read Subscribing to blogs the easy way. Thanks for visiting!

One of the most impressive things about modern scripting languages, and probably the biggest productivity booster, far bigger than the languages themselves, is the wide range of high quality libraries available through easy to use repositories.

Seems odd that Java doesn’t maintain a similar library repository.

Popularity: 16% [?]

Share and Enjoy:
  • del.icio.us
  • Twitter

Related posts:

  1. Popularity Contest Widget
  2. Inch forward a bit, a bit more…
  3. Give me a boost Boost
  4. Programmer middle age

{ 6 comments… read them below or add one }

Tarus February 15, 2008 at 5:21 PM

What about Maven? It allows one to manage Java libraries at a very high level. We use it to build OpenNMS.

Jack February 15, 2008 at 5:29 PM

@Tarus – Maven isn’t really like PEAR or CPAN. Maven is a clever build tool much like Ant & makefiles as I understand it.

PEAR and CPAN are closer to RPMs but for programming libraries. All of the dependencies are resolved for you much as RPM resolves package dependencies.

Just strikes me as odd. Because you would have thought that Java would have been a perfect candidate for a really good library repository. There are plenty of high quality libraries out there for Java after all.

The Open Sourcerer February 16, 2008 at 10:47 AM

Good point Jack,

I have been playing around with Tomcat and some JSP applications recently. The performance of the “whole” solution is great, but when you start to run multiple apps inside one Tomcat instance, there are constant library management problems. The shared (or common) space for libs gets cluttered with multiple variants of the same thing, the apps’ own lib file spaces end up containing multiple copies of the same version… It is all – seemingly down to the packager as to whether they decide to install their required libs in common or their own private space. It takes manual intervention to trawl and move stuff around to keep duplication down to a minimum.

A solution to this sounds like a very worthwhile objective.

Al

Jack February 17, 2008 at 9:02 PM

@Alan – we’ve recently had some fun with this too. A XML-RPC lib we use to connect to our payment provider was also used by another lib in our e-commerce system. Unfortunately, their version was newer than the one we use so they clashed. Not too big a problem in the end, because we were able to upgrade our code to use the later version of the library.

Seems odd that Java can’t handle two different version of the same library being used at the same time.

The Open Sourcerer February 17, 2008 at 9:27 PM

I came across something today that I hadn’t heard of before and “might” offer a solution of sorts.

I read about it here:http://www.redmonk.com/jgovernor/2008/02/05/osgi-and-the-rise-of-the-stackless-stack-just-in-time/

Al

Jack February 18, 2008 at 11:23 AM

@Alan – interesting article. If done properly, a Java CPAN allow the creation of a cut down Java engine with only the elements you want included?

Leave a Comment

Previous post:

Next post: