Skip to content

Conversation

@janhoy
Copy link
Contributor

@janhoy janhoy commented Dec 17, 2025

https://issues.apache.org/jira/browse/SOLR-18036

This fix will conditionally s/solr.log.dir/solr.logs.dir/ in /var/solr/log4j2.xml, but only if

  • The file exists
  • The file contains the old pattern solr.log.dir

If these are not true, nothing happens.
If they are true but editing the file fails, e.g. due to read-only file system, a warning message is written to stderr.

@github-actions github-actions bot added the docker Docker image label Dec 17, 2025
@janhoy janhoy requested a review from dsmiley December 17, 2025 16:01
Copy link
Contributor

@dsmiley dsmiley left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good. Albeit I wonder if not installing log4j2.xml there in the first place would be no more work than this work-around/fix.

@janhoy
Copy link
Contributor Author

janhoy commented Dec 18, 2025

Looks good. Albeit I wonder if not installing log4j2.xml there in the first place would be no more work than this work-around/fix.

I think this auto-migration strategy can stay in place even if we remove the auto-copy part later. Will merge soon.

@janhoy janhoy changed the title Auto migrate log4j2.xml docker SOLR-18036 Auto migrate log4j2.xml docker Dec 19, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

docker Docker image

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants