apache / logging-log4j2

Apache Log4j 2 is a versatile, feature-rich, efficient logging API and backend for Java.
https://logging.apache.org/log4j/2.x/
Apache License 2.0
3.35k stars 1.59k forks source link

Test MongoDB appender against Docker image #2229

Open ppkarwasz opened 7 months ago

ppkarwasz commented 7 months ago

Right now (after #1589), we are using Embedded MongoDB to:

This procedure has some problems:

  1. we cannot run tests in parallel on a clean system (each test tries to download MongoDB at the same time),
  2. 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.

ppkarwasz commented 7 months ago

@garydgregory, could you look into this?

vy commented 7 months ago

@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.