The Source for Java Technology Collaboration
User: Password:



Fernando Lozano

Fernando Lozano's Blog

If you use Linux, you should use JPackage

Posted by flozano on December 08, 2005 at 06:37 AM | Comments (17)

JPackage (www.jpackage.org) is an Open Source Software project that aims to provide popular Java applications and libraries in a manner that is compatible with Linux standards like the FHS and administrative best practices for the platform. But it goes well beyond simply packaging Java software as RPM packages used by most popular Linux distributions, it also provides ways to deal with conflicting Java VM and third-party library releases. It allows you to have at the same time one app that requires Java 5.0 and other that was certified to run only with 1.4.2 or even 1.3.1. It also allows you to have apps that require for example Hibernate 3.0 and other that works only with Hibernate 2.1 without requiring each app to have its own private copy of Hibernate libraries and their dependencies like Jakarta-commons and C3P0.

Major Linux distributions are already commited to JPackage, like Red Hat and Mandriva, and even Debian is using JPackage conventions and scripts for including F/OSS Java applications like RSSOwl and Eclipse in it's official download feeds.

In order to get a completely managed Java environment, JPackage even tells you how to repackage popular proprietary software like Sun JDK their way. Unfortunately they can't redistribute those packages because of license restrictions.

I manage a few Red Hat Enterprise Linux servers who already comes with JPackage RPMs for IBM JRE. It was very nice to be able to use their dependency information to deploy applications to our internal network and let yum take care of updates. It was also very nice to be able to use the alternatives system (from Debian) to switch the default Java from IBM JRE to GCJ when I was mantaining one app that made use of GCJ CNI. And I had no trouble deploying this update alongside others that required IBM JRE (or Sun JRE). JPackage makes sure each app runs on the JVM it needs.

Bottom line, the fact RHEL4 already uses JPackage made deploying and updating Java apps (both desktop and server-side) to a wide array of users and needs much easier than when I had to manually install, configure and customize Sun JRE and many vendors apps.

But now I need Java 5.0 for a new app and but I do not have it JPackage-enabled. Of course I could follow JPackage web site instructions on how to repackage Sun JRE 5.0 (or the new IBM Java Runtime 1.5.0) but it would be much better if they already provided JPackage-compatible RPMs. After all, I could use this time to do more important things for my employee.

Nothing prevents them to do so. The JPackage guys have already done all the hard work for Sun, IBM, BEA, Apache, JBoss and other Java vendors. Their work was already tested and validated by a number of users and corporations. And all major Java vendors already uses many F/OSS software as part of their products, so a few JPackage scripts should present no problem.

So, please, Java Vendors, make JPackage a standard part of your Linux packaging and support. You'll make your customers very glad.


Bookmark blog post: del.icio.us del.icio.us Digg Digg DZone DZone Furl Furl Reddit Reddit
Comments
Comments are listed in date ascending order (oldest first) | Post Comment

  • Fernando,
    Would JPackage work for both Linux and Solaris? If so, I would think that Sun would be much more interested.

    Just a thought...

    --JohnR

    Posted by: johnreynolds on December 08, 2005 at 07:40 AM

  • John,

    As Solaris does not use the RPM packaging format, the JPackage packages would not work out of the box on Solaris. Solaris uses a packaging format that no other operating system distribution uses, afaik.

    cheers,
    dalibor topic

    Posted by: robilad on December 08, 2005 at 08:00 AM

  • I guess it would be directly applicable to Java Desktop System, which uses RPM packages, but nothing prevents Sun to adapt JPackage to Solaris the same way Debian is adapting to their packaging system. And it would be a nice oportunity to foster collaboration between OpenSolaris developers and Linux developers.

    Anyway Sun, IBM and others already provide Linux RPM packages for Java software, so why don't do this right? After all the hard work was already done by JPackage.

    Posted by: flozano on December 08, 2005 at 11:44 AM

  • The JRockit 1.4.2 JDK has been available in JPackage format , java-1.42.-bea, for RHEL3 and RHEL4 on Red Hat Network for automatic download and installation since 2004. Updates to the JRockit 1.4.2 JDK and also the newly released JRockit 5.0 JDK are in the pipe to be released in the same way during the beginning of 2006.

    Other major Linux vendors, such as SuSE and Red Flag, have propriatary RPM formats for the JRockit JDK today, but are also on similar JPackage RPM paths as Red Hat.

    BEA is fully supporting the JPackage.org packaging format for the JRockit JDK and we are investigating how we can contribute more to this process, so let us see what the future brings...

    Robert Ottenhag, Software Engineer, Java Runtime Products Groups, BEA Systems, Inc.

    Posted by: robert_ottenhag on December 09, 2005 at 04:08 AM

  • Hi Robert, thanks for the info. I though the BEA packages from Red Hat were put there by Red Hat itself, like it did for IBM packages. Nice to know that at least one major Java vendor already supports JPackage. I may well start using JRockit instead of IBM Java. :-)

    Posted by: flozano on December 09, 2005 at 05:41 AM

  • Thanks for highlighting the JPackage project. I've been using it since 2002 and it's only gotten better. One question I have is why is the Blackdown JDK RPM still listed in the "non-free" section? I've been using Gentoo for the past year and I can download the Blacdown VM from portage just fine during emerge. (You can't do that with Sun's VM because of download restrictions. It must be done manually.) So if it can be done with Gentoo why the difference with JPackage?
    Anyway, we do need to keep pressuring Sun to adopt the JPackage format. Vote for Bug ID 4680244 (RPM does not follow LSB or filesystem hierachy)

    Posted by: gbarton on December 09, 2005 at 11:36 AM

  • The Blackdown JDK and JRE are non-free by the same reasons Sun, IBM and BEA. Blackdown is also a Sun licensee, and their Java implementation has to obey Sun license terms. Actually they licensed Sun Java before Sun itself provided Linux suport and they did most of the hard work behind Sun Java for Linux.

    I don't know if it's ok for licensees to change distribution terms, so either Blackdown or Gentoo may be violating Sun license. But anyway they cannot change rights to the source code so Blackdown JDK is not free software / open source software, and that's why it's non-free: the JPackage project cannot ship the sources for Blackdown Java.

    Posted by: flozano on December 09, 2005 at 12:45 PM

  • Is there a ready link for how to create a JPackage dist? Thanks

    Posted by: toren03 on December 10, 2005 at 10:39 PM

  • Hi toren03, I didn't understand what you wanted to know, but the JPackage web site URL is at the begining of the post and there you can find detailed info about the project, how to "bootstrap" repackaging a proprietary JVM or simply downloading their packages and installing the software that works with F/OSS JVMs.

    Posted by: flozano on December 13, 2005 at 10:14 AM

  • Hi Robert,

    I visited the BEA JRockit site today and found no downloads that were JPackage-compliant. I also found no info about BEA support for JPackage. Could you please give soime pointers?

    Posted by: flozano on December 14, 2005 at 06:34 AM

  • The JPackage compliant JRockit RPMs are only available from Red Hat if your machine is registered on Red Hat Network (which I think is free), and I think SuSE has something similar.

    BEA does currently not provide any RPMs for download from their own web site but relies on partners to do the distribution. We are investigating how this distribution can be made easier and more accessible but that is currently how it works.

    It is still possible to rebuild a JPackage compliant JRockit RPM using the instructions on the www.jpackage.org web site though.

    Posted by: robert_ottenhag on December 16, 2005 at 03:43 AM

  • Registration on RHN is not free, it's availabe only for customers that have an RHEL support contract. Same for SuSE / Novell. And it's not as good as having the updated directly from BEA, after all repackaging JVMs is not a big priority for Red Hat and SuSE.

    Posted by: flozano on December 29, 2005 at 08:55 PM

  • I just wanted to point out an excellent HOWTO for getting started with JPackage on Fedora using the Sun JVM:


    FedoraNEWS: JPackage Java for FC4

    Posted by: ahalsey on January 06, 2006 at 05:08 PM

  • Thans for the link, ahalsey. For those who speack portugese, there's also the nice article by Avi Alkalay http://avi.alkalay.net/linux/docs/java/JavaLinux.pdf

    Posted by: flozano on January 06, 2006 at 06:26 PM

  • Hi John, people on the JPackage mailing list reported it works fine on Solaris, you just have to install RPM first. Bootstrapping RPM to be able to use JPackage should not be that hard, as you won't deal with the myriad libraries and utilities native applications need as dependencies.

    Posted by: flozano on January 06, 2006 at 06:36 PM

  • Please, please, please do *NOT* use jpackage.

    I hate maven, but the maven repository is the current
    de-facto java repositoty.

    Posted by: peterkittreilly on June 20, 2007 at 08:26 AM

  • Peter, a maven repository (or osgi one) doesn't integrate with linux package management and linux configurations tools. The question isn't about a java repository, but about linux system administration standards and best practices. But of course Java packaging standard could and should emulate a few tricks from linux rpm.

    Posted by: flozano on June 20, 2007 at 09:49 AM





Powered by
Movable Type 3.01D
 Feed java.net RSS Feeds