[
https://issues.apache.org/jira/browse/FELIX-6815?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18053345#comment-18053345
]
Georg Henzler commented on FELIX-6815:
--------------------------------------
[~cziegeler] What about just removing the fallback to http://localhost:8080
that was introduced with FELIX-6635 - then defaultBaseUrl stays null until that
service becomes available. We could then check at
https://github.com/apache/felix-dev/blob/866c7e7bb0f50719916b6c42a3c0be65ac96a1b5/healthcheck/generalchecks/src/main/java/org/apache/felix/hc/generalchecks/HttpRequestsCheck.java#L400
if it is null and then return WARN that a relative URL cannot be evaluated
while the HttpService is not available. For many setups that would remain like
this for a very short time and then fix itself (once the HttpService becomes
available), but for the case a setup does not deploy an HttpService at all,
this would still make sense (in theory it is possible to run Felix without
HttpService to monitor some external absolute URL).
> HttpRequestsCheck may initialise with the wrong defaultBaseUrl during
> activation
> --------------------------------------------------------------------------------
>
> Key: FELIX-6815
> URL: https://issues.apache.org/jira/browse/FELIX-6815
> Project: Felix
> Issue Type: Improvement
> Components: Health Checks
> Affects Versions: healthcheck.generalchecks 3.0.8
> Reporter: Georg Henzler
> Assignee: Georg Henzler
> Priority: Major
>
> FELIX-6635 introduced the default value of http://localhost:8080 which is
> sometimes set incorrectly during startup due to a race condition if the http
> service isn't there yet while HttpRequestsCheck is activated, see
> https://github.com/apache/felix-dev/commit/866c7e7bb0f50719916b6c42a3c0be65ac96a1b5
--
This message was sent by Atlassian Jira
(v8.20.10#820010)