logging-log4j2
logging-log4j2 copied to clipboard
Test MongoDB appender against Docker image
Right now (after #1589), we are using Embedded MongoDB to:
- download a MongoDB distribution on our system,
- run it with the correct parameters,
- test the MongoDB appender.
This procedure has some problems:
- we cannot run tests in parallel on a clean system (each test tries to download MongoDB at the same time),
- the MongoDB distribution depends on some system libraries that are not always present.
Therefore we should move the tests to use TestContainers or an equivalent solution and the official Docker mongo images.
@garydgregory, could you look into this?
@garydgregory, @ppkarwasz, I would prefer a uniform container-based testing across the code base. log4j-layout-template-json-test uses docker-maven-plugin behind a docker profile. I am in favor of adapting this to log4j-mongodb* modules.
If we will be going to Testontainers route, which is fine, I would appreciate it if we can migrate log4j-layout-template-json-test there too.