Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.

Bug 1115443

Summary: Natives fails to load after server reload when changing from java to native connector
Product: [JBoss] JBoss Enterprise Application Platform 6 Reporter: Martin Velas <mvelas>
Component: WebAssignee: Rémy Maucherat <rmaucher>
Status: CLOSED EOL QA Contact: Jan Stefl <jstefl>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 6.3.0CC: jstefl, myarboro, pslavice
Target Milestone: ---   
Target Release: EAP 6.4.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2019-08-19 12:45:47 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Martin Velas 2014-07-02 11:21:12 UTC
Description of problem:
Natives fails to load after server reload when changing from java to native connector.

Version-Release number of selected component (if applicable):
6.3.0.ER7

How reproducible:
allways

Steps to Reproduce:
1. install eap 6.3.0.ER7 with natives
2. Start the server with disabled natives (it is default state): ./bin/standalone.sh
3. using CLI enable the natives: /subsystem=web:write-attribute(name=native, value=true)
4. reload the server using CLI

Actual results:
Natives can not be loaded - see error message:
07:12:32,106 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-2) MSC000001: Failed to start service jboss.web.connector.http: org.jboss.msc.service.StartException in service jboss.web.connector.http: Failed to start service
	at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1936) [jboss-msc-1.1.5.Final-redhat-1.jar:1.1.5.Final-redhat-1]
	at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:895) [rt.jar:1.6.0_45]
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:918) [rt.jar:1.6.0_45]
	at java.lang.Thread.run(Thread.java:662) [rt.jar:1.6.0_45]
Caused by: java.lang.NoClassDefFoundError: Could not initialize class org.apache.tomcat.jni.OS
	at org.apache.tomcat.util.net.AprEndpoint.init(AprEndpoint.java:582)
	at org.apache.coyote.http11.Http11AprProtocol.init(Http11AprProtocol.java:104)
	at org.apache.catalina.connector.Connector.init(Connector.java:985)
	at org.jboss.as.web.WebConnectorService.start(WebConnectorService.java:318)
	at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1980) [jboss-msc-1.1.5.Final-redhat-1.jar:1.1.5.Final-redhat-1]
	at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1913) [jboss-msc-1.1.5.Final-redhat-1.jar:1.1.5.Final-redhat-1]
	... 3 more

Expected results:
natives are enabled, server and http connector starts properly.

Additional info:
When the server is shutdown and started again, the server is correctly started with the natives.

Comment 1 Martin Velas 2014-08-05 12:09:16 UTC
Issue is still valid for EAP 6.3.0.ER10.

Comment 2 Rémy Maucherat 2014-09-09 13:04:29 UTC
After looking at the code, it is a duplicate of 1115434 since the flag is only really set during bootstrap, which is the reason for both issues. Same for instance id and the default vhost actually. Looking at the code structure I am not sure how to fix it, at least moving init out of bootstrap could have unforeseen consequences.

Will see ...

Comment 3 Rémy Maucherat 2014-09-09 13:12:57 UTC
*** Bug 1115434 has been marked as a duplicate of this bug. ***

Comment 4 Rémy Maucherat 2014-10-10 11:38:23 UTC
Similar behavior on other items: welcome files, mime mappings, native, instanceid, default session timeout, default virtual server.

Still no idea if this can be fixed without causing serious problems, so nack for now.

Comment 5 Rémy Maucherat 2014-10-10 11:46:58 UTC
More precisely, all these configuration elements are only read from the config at boottime, where they are set in WebSubsystemAdd.performBoottime

Comment 6 Rémy Maucherat 2014-10-10 21:56:30 UTC
*** Bug 1151478 has been marked as a duplicate of this bug. ***

Comment 7 Radim Hatlapatka 2014-10-13 13:54:46 UTC
From attached debugger to see when WebSubsystemAdd.performBoottime is called, it behaves as if the reload-required is set on the subsystem, the WebSubsystemAdd.performBoottime is called.

Comment 10 Jan Stefl 2014-11-04 14:00:10 UTC
BZ-1115434 is closed as duplicate already.