Add system httpd support and native httpd CI job#8
Merged
Conversation
getModProxyClusterConfPath() returned a relative path, which copyLocalFile() then resolved against httpdHome, doubling the path. The SSL variant config silently went to a nested location while httpd kept serving plain HTTP on the MCMP port.
jajik
suggested changes
Jun 1, 2026
Replace ad-hoc confFile.getParent().getParent() navigation with httpdHome field, add requireHttpdHome() guard for fail-fast on pre-start access, fix RHEL8 JBCS layout support (httpd/sbin/httpd search path), remove misleading log and redundant method call, replace var with explicit types, and add SslCrlTest to CI matrix.
Guard public methods that dereference confFile (getConfDir, reload) with a dedicated requireConfFile() helper, matching the existing requireHttpdHome() pattern.
Support system-installed httpd via -Dhttpd.home (e.g. /usr) with externally-built mod_proxy_cluster modules via -Dhttpd.modules.path. A working directory under target/native-servers/httpd/work/ is created with generated httpd.conf, merged modules symlinks, and conf.d/ for the mod_proxy_cluster config template. Add native-httpd CI job on Ubuntu that installs apache2, builds mod_proxy_cluster from source via CMake, and runs the test suite. Update all CI actions to latest versions (checkout v6, setup-java v5, upload-artifact v7, action-junit-report v6). Document new properties and system httpd setup in README.
Ubuntu's apache2 has some modules (e.g. unixd_module) compiled in as built-in. Attempting to LoadModule a built-in module fails with a syntax error. Wrap all LoadModule directives in the generated httpd.conf with <IfModule !module_name> guards to skip modules that are already loaded or built-in.
When multiple test classes run sequentially (e.g. SslFailoverTest after SslCrlTest), stale ssl-data.conf files from the previous test remain in conf/extra/ and cause "Cannot define multiple Listeners" errors on the next httpd start. Delete and recreate the entire work directory at the beginning of each setupSystemHttpdWorkDir() call.
Remove IncludeOptional conf/extra/ssl-*.conf from the generated httpd.conf — the mod_proxy_cluster.conf template already includes it, causing ssl-data.conf to be parsed twice and triggering "Cannot define multiple Listeners on the same IP:port" on graceful restart. Also clean the entire work directory on each start to prevent stale SSL configs from prior test classes from persisting.
marekkopecky
approved these changes
Jun 2, 2026
Contributor
|
Thank you! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
target/native-servers/httpd/work/ is created with a generated httpd.conf, merged modules symlinks, and IfModule guards for cross-distro compatibility (Fedora vs Ubuntu built-in modules).
system httpd.
pre-start access, fixed RHEL8 JBCS layout support (httpd/sbin/httpd search path), added apache2 binary name support.