In practice the suffix is required. The deployment unit processors need to know whether they are interested in the deployment, and in the end that gets back to some DUP or other checking the suffix. The alternative would be DUPs speculatively digging into the deployment, checking for deployment descriptors or annotations and the like and that would be more expensive, likely buggy (e.g. false positives when some class in the classpath includes an annotation not relevant to the deployment) and could mess up some use cases where we want to defer classloading.

On Thu, Jan 4, 2018 at 10:44 PM, Jaikiran Pai <> wrote:
In context of this[1] forum thread, is runtime-name expected/mandated to
include even the packaging type suffix (.war, .ear etc) or can it be any
name? For example, for a deployment foo.war, is it valid to have it
deployed with a runtime-name "bar"? Or should it be bar.war?

What's happening in this case is that there are deployment unit
processors which identify the "type"[2] of the deployment based on the
deploymentUnit.getName() and in the absence of the suffix, end up not
recognizing the type of the deployment unit which then cascades into
issues like the one in that thread, where the WEB-INF/classes isn't
added as a resource root to the module of the deployment unit, since it
wasn't considered a WAR type deployment.




wildfly-dev mailing list

Brian Stansberry
Manager, Senior Principal Software Engineer
Red Hat