Buggy code:
class WebSubsystemAdd extends AbstractBoottimeAddStepHandler { static final WebSubsystemAdd INSTANCE = new WebSubsystemAdd ( ) ; private static final String TEMP_DIR = "jboss.server.temp.dir" ; private WebSubsystemAdd ( ) { } @ Override protected void populateModel ( ModelNode operation , ModelNode model ) throws OperationFailedException { } @ Override protected void performBoottime ( OperationContext context , ModelNode baseOperation , ModelNode model , ServiceVerificationHandler verificationHandler , List < ServiceController < ? > > newControllers ) throws OperationFailedException { ModelNode fullModel = Tools . readModel ( context . readResource ( EMPTY_ADDRESS ) ) ; final ModelNode config = resolveConfiguration ( context , fullModel . get ( CONFIGURATION ) ) ; final String defaultVirtualServer = DEFAULT_VIRTUAL_SERVER . resolveModelAttribute ( context , fullModel ) . asString ( ) ; final boolean useNative = NATIVE . resolveModelAttribute ( context , fullModel ) . asBoolean ( ) ; final ModelNode instanceIdModel = INSTANCE_ID . resolveModelAttribute ( context , fullModel ) ; final String instanceId = ( instanceIdModel . isDefined ( ) ) ? instanceIdModel . asString ( ) : null ; context . addStep ( new AbstractDeploymentChainStep ( ) { @ Override protected void execute ( DeploymentProcessorTarget processorTarget ) { final SharedWebMetaDataBuilder sharedWebBuilder = new SharedWebMetaDataBuilder ( config . clone ( ) ) ; final SharedTldsMetaDataBuilder sharedTldsBuilder = new SharedTldsMetaDataBuilder ( config . clone ( ) ) ; <START_BUG> processorTarget . addDeploymentProcessor ( SUBSYSTEM_NAME , STRUCTURE , STRUCTURE_REGISTER_JBOSS_XML_PARSER , new org . jboss . as . server . deployment . jbossallxml . JBossAllXmlParserRegisteringProcessor < org . jboss . metadata . web . jboss . JBossWebMetaData > ( WebJBossAllParser . ROOT_ELEMENT , WebJBossAllParser . ATTACHMENT_KEY , new WebJBossAllParser ( ) ) ) ; <END_BUG> processorTarget . addDeploymentProcessor ( SUBSYSTEM_NAME , STRUCTURE , STRUCTURE_WAR_DEPLOYMENT_INIT , new WarDeploymentInitializingProcessor ( ) ) ; processorTarget . addDeploymentProcessor ( SUBSYSTEM_NAME , STRUCTURE , STRUCTURE_WAR , new org . jboss . as . web . deployment . WarStructureDeploymentProcessor ( sharedWebBuilder . create ( ) , sharedTldsBuilder ) ) ; processorTarget . addDeploymentProcessor ( SUBSYSTEM_NAME , PARSE , PARSE_WEB_DEPLOYMENT , new WebParsingDeploymentProcessor ( ) ) ; processorTarget . addDeploymentProcessor ( SUBSYSTEM_NAME , PARSE , PARSE_WEB_DEPLOYMENT_FRAGMENT , new WebFragmentParsingDeploymentProcessor ( ) ) ; processorTarget . addDeploymentProcessor ( SUBSYSTEM_NAME , PARSE , PARSE_JBOSS_WEB_DEPLOYMENT , new JBossWebParsingDeploymentProcessor ( ) ) ; processorTarget . addDeploymentProcessor ( SUBSYSTEM_NAME , PARSE , PARSE_TLD_DEPLOYMENT , new TldParsingDeploymentProcessor ( ) ) ; processorTarget . addDeploymentProcessor ( SUBSYSTEM_NAME , PARSE , PARSE_ANNOTATION_WAR , new WarAnnotationDeploymentProcessor ( ) ) ; processorTarget . addDeploymentProcessor ( SUBSYSTEM_NAME , PARSE , PARSE_WEB_COMPONENTS , new WebComponentProcessor ( ) ) ; processorTarget . addDeploymentProcessor ( SUBSYSTEM_NAME , PARSE , PARSE_EAR_CONTEXT_ROOT , new EarContextRootProcessor ( ) ) ; processorTarget . addDeploymentProcessor ( SUBSYSTEM_NAME , PARSE , PARSE_WEB_MERGE_METADATA , new WarMetaDataProcessor ( ) ) ; processorTarget . addDeploymentProcessor ( SUBSYSTEM_NAME , PARSE , PARSE_WEB_INITIALIZE_IN_ORDER , new WebInitializeInOrderProcessor ( defaultVirtualServer ) ) ; processorTarget . addDeploymentProcessor ( SUBSYSTEM_NAME , DEPENDENCIES , DEPENDENCIES_WAR_MODULE , new WarClassloadingDependencyProcessor ( ) ) ; processorTarget . addDeploymentProcessor ( SUBSYSTEM_NAME , INSTALL , INSTALL_SERVLET_INIT_DEPLOYMENT , new ServletContainerInitializerDeploymentProcessor ( ) ) ; processorTarget . addDeploymentProcessor ( SUBSYSTEM_NAME , INSTALL , INSTALL_WAR_DEPLOYMENT , new WarDeploymentProcessor ( defaultVirtualServer ) ) ; } } , RUNTIME ) ; final ServiceTarget target = context . getServiceTarget ( ) ; final WebServerService service = new WebServerService ( defaultVirtualServer , useNative , instanceId , WebSubsystemAdd . TEMP_DIR ) ; newControllers . add ( target . addService ( JBOSS_WEB , service ) . addDependency ( SERVICE_NAME , PathManager . class , service . getPathManagerInjector ( ) ) . addDependency ( OPTIONAL , JBOSS . append ( "mbean" , "server" ) , MBeanServer . class , service . getMbeanServer ( ) ) . setInitialMode ( ON_DEMAND ) . install ( ) ) ; final DistributedCacheManagerFactory factory = new DistributedCacheManagerFactoryService ( ) . getValue ( ) ; if ( factory != null ) { final InjectedValue < WebServer > server = new InjectedValue < WebServer > ( ) ; newControllers . add ( target . addService ( JVM_ROUTE_REGISTRY_ENTRY_PROVIDER_SERVICE_NAME , new JvmRouteRegistryEntryProviderService ( server ) ) . addDependency ( JBOSS_WEB , WebServer . class , server ) . setInitialMode ( ON_DEMAND ) . install ( ) ) ; newControllers . addAll ( factory . installServices ( target ) ) ; } } @ Override protected boolean requiresRuntimeVerification ( ) { } private ModelNode resolveConfiguration ( OperationContext context , ModelNode model ) throws OperationFailedException { } }

Fix:
processorTarget . addDeploymentProcessor ( SUBSYSTEM_NAME , STRUCTURE , STRUCTURE_REGISTER_JBOSS_ALL_XML_PARSER , new org . jboss . as . server . deployment . jbossallxml . JBossAllXmlParserRegisteringProcessor < org . jboss . metadata . web . jboss . JBossWebMetaData > ( WebJBossAllParser . ROOT_ELEMENT , WebJBossAllParser . ATTACHMENT_KEY , new WebJBossAllParser ( ) ) ) ;