WildFly Modules: Difference between revisions

From NovaOrdis Knowledge Base
Jump to navigation Jump to search
Line 41: Line 41:


Sub-deployments are named according to the following pattern: <tt>deployment.<my-ear-archive-name>.ear.<my-war-archive-name>.war</tt>.
Sub-deployments are named according to the following pattern: <tt>deployment.<my-ear-archive-name>.ear.<my-war-archive-name>.war</tt>.
<font color=red>Example + Playground</font>


=Writing a Custom WildFly Module=
=Writing a Custom WildFly Module=

Revision as of 19:37, 10 March 2016




Migrating from https://home.feodorov.com:9443/wiki/Wiki.jsp?page=JBossModules


External

Internal

Overview

A WildFly module (or JBoss module) is a packaged collection of classes and other resources, along with the specification of what is imported and exported by this module from and to other modules. Each API or service provided by WildFly is implemented as a module, which is loaded or unloaded on demand.

WildFly modules provide finely grained class isolation. They hide server implementation classes from the application and only load the classes the application needs. WildFly modules are peers that remain isolated unless explicitly defined as a dependency of another module. Visibility rules have sensible defaults and can be customized.

JEE deployments are also modules, which do not have access to application server modules' classes, unless an explicit dependency on those classes is defined.

For more details on class loading see WildFly class loading.

Deployment Module Names

Each JEE deployment triggers run-time initialization of corresponding module or set of modules.

A top-level deployment that does not have any other sub-deployments creates a single module named deployment.<my-archive-name>.war:<version>.

Example for a simple servlet deployment:

deployment.servlet-example.war:main

Sub-deployments are named according to the following pattern: deployment.<my-ear-archive-name>.ear.<my-war-archive-name>.war.

Writing a Custom WildFly Module

Writing a Custom WildFly Module

TODO

Next, continue migrating https://home.feodorov.com:9443/wiki/Wiki.jsp?page=JBossModules

Organizatorium

Upon the first use of the module, JBoss creates a <module-name>.jar.index file containing a list of packages? directories? .... .

Implicit module dependencies for deployments: https://docs.jboss.org/author/display/AS7/Implicit+module+dependencies+for+deployments