[kaffe] Running JOnAS (head, 4.6) on Kaffe (head, 1.1.6)

Dalibor Topic robilad at kaffe.org
Mon Sep 19 15:21:29 PDT 2005

  'There she blows! -- there she blows! A hump like a snow-hill! It is 
Moby Dick!'
   Captain Ahab in Melville's "Moby Dick"

Thanks to the great work of Andrew Haley from gcj, and other gcj 
hackers, JOnAS has been known to work increasingly well on gcj. I've 
decided to give it a try on Kaffe's pre2 release, and thanks to the help 
of Florent Benoit from JOnAS and CAROL projects, I've managed to set 
things up and get JOnAS to start up wth little tweaks here and there.

You'll need that latest JOnAS snapshot available from

after you extract the archive you'll need to change a few small things. 
In file conf/carol.properties change carol.protocols to


Some of the other carol protocols try to use sun specific facilities 
that do not exist on kaffe. The jeremie protocol works, though.

In file conf/jonas.properties, one needs to remove ear services from 
jonas.services, since they do not work yet, due to an odd issue with jar 
url connections. So one need to set jonas.services to

jonas.services    registry,jmx,jtm,db,dbm,security,resource,ejb,ws,web

Since kaffe does not support java.endorsed.dirs, one needs to set 
JAVA_OPTS environment variable to prepend the endorsed libraries on the 


Since there seems to be an interestig bug somewhere either in kaffe or 
in the class loading code that leads to lack of protection domains being 
applied to some files, you need to apply the attached patch dali.diff to 
Kaffe sources in ordr to make the accesscontrolcontext permit classes 
with empty protection domains to read files. I have not investigated the 
bug, so this is just a temporary workaround to let you fire up jonas 
with the war files actually being loaded ;)

Finally, set JAVA_HOME to whereever you installed Kaffe from CVS head 
with the attached patch applies, and from the jonas directory, run

bin/unix/jonas start

After a little while, you should get the jonas startup success message, 
and you should then be able to connect to the jonas instance at 
localhost port 9000.

If you are using links, you can enter the admin console and make sure 
that you are indeed running jonas on kaffe. then it looks a bit like


If you are using firefox, then the jonas console looks much prettier, 
with cute whale graphics and all that:


I've also played a bit with ofbiz, but that looks like would be a harder 
task to get set up properly. Anyway, if you are interested in running 
J2EE servers on Kaffe, or another free runtime, this should get you 
going. There are probably tons of bugs remaining, please report them to 
the GNU Classpath bug tracker, if you can, and send your patches over 
there, too.

dalibor topic
-------------- next part --------------
A non-text attachment was scrubbed...
Name: dali.diff
Type: text/x-patch
Size: 920 bytes
Desc: not available
Url : http://kaffe.org/pipermail/kaffe/attachments/20050920/fe59e272/attachment-0002.bin 

More information about the kaffe mailing list