Application packager

Project:JNode Builder
Category:feature request
Assigned:Fabien D

JNode need an application packager for easily testing real world java applications.

I want to make it as easy as the following steps :

  • put the jar of your application in a given directory
  • build jnode cdrom with usual ant script
  • boot jnode and test your application

For a first version, it will only support applications in a single jar and that doesn't need third parties libraries.
The packager will automatically :

  • Create an alias for the main method defined in the jar's manifest or, by default, will find it by scanning the jar.
  • Create a descriptor for the plugin descriptor for the jar
  • Create a jnode plugin and add it to the full plugin list (like if it were added to all/conf/full-plugin-list.xml but without actually modifying the file)

For more informations on the packager, look into package of jnode-builder sub-project.


I have commited the first version of the tool.
Here are the steps to test a third party application :

  • Check that you have a file named in the root of your jnode project. If you don't have, create one from the template file
  • Define the property user.applications.dir in the file (there is an example in
  • Each jar you will put in that directory will be packaged as a jnode plugin and added to the "all plugins" list
  • Build a JNode cdrom as usual
  • Boot and test your application !

To find the alias(es) for your application, you can both :

  • Look at the output of the console while building JNode and search for lines containing "added alias" (might not be displayed if nothing to build)
  • Search for alias definition in the plugin descriptor added to your application directory (example : myApplication.xml for a file named myApplication.jar)

Remark : I am actively using that tool right now.

Any comment is welcome.



I have not tried the jar builder yet, but you could use the alias command in JNode to find out what alias your application got from the builder.



Hi Fabien,

thanks for this tool. It makes it much more fun trying other applications. I have some further requests though, perhaps you could add them:

* Support for Steve's configure script
* Support for single class files (simply provide the classes to the runtime)
* Support for jar files without Manifest (throws a NPE at the moment)
* I don't have a usecase yet but perhaps support other files as ressources to the runtime (images, property files,...)


About the NPE :
I have fixed it but I have errors like "java.lang.ClassFormatError: Incompatible magic value 0 in class file jnt/Bench/Target" while the tool is trying to load some classes.

Such errors are happening with scimark and for art of illusion. It can still find the main class for the former but not for the latter, which contained a manifest that I removed.

About support for other resources :
Some third party applications doesn't support/expect to be packaged in a jnode plugin or need many jars and resource files. I have some use cases and need to extend the tool.


Do we need to do anything special to get a JNode command's syntax into the plugin descriptor? I assume that when the plugin is loaded it would trigger a "refresh" to load the syntaxes into the SyntaxManager in the normal way.


Title:jar packager» Application packager

I have extended the tool, here is the additional feature :
- Each sub directory of the directory defined by the property user.applications.dir is packaged as a plugin that will be automatically unzipped at startup.

Example : To package the robocode application.
In, I have "user.applications.dir = ${root.dir}/local/applications/".
I have put all the robocode files under the directory ${root.dir}/local/applications/robocode/

Before :
  content of ${root.dir}/local/applications/robocode :,, ...

After jnode's build :
  content of ${root.dir}/local/applications : robocode.xml,
  content of ${root.dir}/local/applications/robocode :,, robocode.jns, teamrumble.jns...

  Note the added jnode scripts : robocode.jns, teamrumble.jns ...
  They are used as an approximate replacement of the unix scripts (, ...) for jnode (the tool is searching for a line containing the java command and convert it to a jnode script)

When you will boot jnode, all files under ${root.dir}/local/applications/robocode will be in /jnode/robocode/.
To start robocode :

  • cd /jnode/robocode
  • run robocode.jns

Peter : all your features are implemented now (+ a big fix for the NPE) except support for Stephen's configuration script since I don't know what you mean/expect.
Stephen : The tool can't guess the syntax: that's to the user to add the syntax in the generated plugin descriptor.


What about JNLP for running/testing applications? This would be appropriate for at least some application types.


I plan to integrate netx with JNode then we will have JNLP support.


Hey Isantha

Just a suggestion ...
I you are planning to integrate Netx then one can also think of parallely getting Xito App Manager running on top of NetX.


I have just looked at Xito App Manager, it sounds like something interesting to have in JNode in the future.


As a software developer I am really so pleased to know that sound. JNode Builder needs an application packager for easily testing real world java applications. I assure that my skill would be ideal for that development. Thanks!