Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

JBoss Modules outside of JBoss AS

I had first found a reference to JBoss Modules when I stumbled upon Ceylon language which uses JBoss Modules as its module system. Immediately I wanted to try this system in some toy project and maybe even embed it in a real project (I was writing a project with plugins support at that time), but I couldn't find any documentation on JBoss Modules as a standalone library. The only available documentation source seems to be the official wiki, but it looks abandoned and unsupported. I couldn't even find Javadocs for it (except, maybe, this, but it seems to be very old and not really related to JBoss Modules due to "osgi" presence in the link).

It seems that JBoss Modules are usable outside of JBoss AS because Ceylon language uses it, but lack of almost any documentation on the subject is disappointing.

So, here are my questions:

  1. Is it possible to use JBoss Modules as a standalone library at all? Are there any artifacts in some public Maven repository?
  2. If it is (and there are), is there any documentation on it? That wiki I have mentioned does not have, for example, any instructions on embedding JBoss Modules.
like image 721
Vladimir Matveev Avatar asked Oct 24 '13 14:10

Vladimir Matveev


2 Answers

If you'd like to try out JBoss Modules directly, you can grab the dependencies from the JBoss Nexus repository: https://repository.jboss.org/nexus/content/repositories/public/org/jboss/modules/jboss-modules/

Unfortunately, there isn't much documentation on JBoss Modules, but if you want to try it out, you probably don't want to be hand-writing modules.xml files yourself (maybe you like pain, I don't know.)

If you'd like to try out "Furnace" the modular container based on JBoss Modules and Maven that serves as the core module system for JBoss Forge, it give you the ability to write Maven projects that can be loaded directly as Modules. This is what we are using for our entire Forge 2 architecture.

You can find some docs on Furnace here:

https://github.com/forge/furnace#furnace https://github.com/forge/core#developing-an-addon

Note that Furnace Addons require a maven classifier, you can choose the classifier used if you want to. This is done via the Furnace Manager (which can be seen in the furnace docs above.)

like image 90
Lincoln Avatar answered Oct 21 '22 10:10

Lincoln


  1. Yes. Actually, JBoss is using it that way as well - so JBoss application server is actually running inside JBoss Modules system.
  2. I'm not aware of such documentation, but usually you shouldn't be embedding jboss modules, but running the applications with it. I'm not aware if you can embed it.

I actually got most information from this presentation in vimeo, Modular Class Loading with JBoss Modules. There seems to also be Zen of Modules video there.

like image 29
eis Avatar answered Oct 21 '22 12:10

eis