related issue : https://github.com/spring-projects/spring-boot/issues/35664

I fixed an issue that worked in boot 2.7 but has been happening since boot 3.x.

I think this issue was caused by the deletion of this line in this commit. (And while I'm not entirely certain, I think this might also be due to the effects of updating logback to version 1.4.x)

[Causes and actions]

Looking at the doConfigure(...) function in ch.qos.logback.core.joranGenericXMLConfigurator.java, it works like this.

        Model top = buildModelFromSaxEventList(recorder.getSaxEventList());
        if (top == null) {
            addError(ErrorCodes.EMPTY_MODEL_STACK);
            return;
        }
        sanityCheck(top);
        processModel(top);

In the current situation, the processModel is lagging behind, and buildModelFromSaxEventList(...) isn't loading the springProperty.

Hence, I've injected springProperty into the context using a SpringPropertyAction, which is a part of the flow executed by playSaxEvents(...).

(Referring to the previously mentioned commit, it appears that initialization was done via SpringPropertyAction in the past.)

Additional comments

I haven't given much thought to this revision, as I'm unaware of the historical context. However, this issue has prevented me from upgrading the current project to boot 3.x. It would be truly beneficial if this issue could be resolved.

I'm always using Spring-Boot well. Thank you for your efforts.

Comment From: philwebb

Thanks for the PR, but I don't think we can accept this change due to the reason documented in https://github.com/spring-projects/spring-boot/issues/35664#issuecomment-1571092176.