feat: Introduced config switches to choose the used implementations
authorKai Moritz <kai@juplo.de>
Wed, 11 Jan 2023 18:09:53 +0000 (19:09 +0100)
committerKai Moritz <kai@juplo.de>
Sun, 15 Jan 2023 18:38:10 +0000 (19:38 +0100)
commitda026a0e3b259d2c2b76016bc0acee7cc8265db4
tree4c1dc7e22f764c40cad5f2ec4ff09bb27337318c
parent1c77d6f54595a9d25a7a8329cd6e10c785c51f50
feat: Introduced config switches to choose the used implementations

- Switched the existing `@Configuration`-classes into an auto-configuration.
- Added a `@ConditionalOnProperty`, that loades the default-configuration.
- Added an Auto-Configuration for the `MongoDbStorageStrategy`, which is
  inactive by default and can be switched on by the property
  `chat.backend.storage` to `mongodb`.
src/main/java/de/juplo/kafka/chat/backend/ChatBackendConfiguration.java
src/main/java/de/juplo/kafka/chat/backend/persistence/inmemory/InMemoryServicesConfiguration.java
src/main/java/de/juplo/kafka/chat/backend/persistence/storage/files/FilesStorageConfiguration.java
src/main/java/de/juplo/kafka/chat/backend/persistence/storage/mongodb/MongoDbStorageConfiguration.java [new file with mode: 0644]