+ private ServiceType services = ServiceType.inmemory;
+ private InMemoryServicesProperties inmemory = new InMemoryServicesProperties();
+
+
+ @Getter
+ @Setter
+ public static class InMemoryServicesProperties
+ {
+ private ShardingStrategyType shardingStrategy = ShardingStrategyType.kafkalike;
+ private int numShards = 10;
+ private int[] ownedShards = { 2 };
+ private StorageStrategyType storageStrategy = StorageStrategyType.files;
+ private String storageDirectory = Paths.get(System.getProperty("java.io.tmpdir"),"chat", "backend").toString();
+ }
+
+ public enum ServiceType { inmemory }
+ public enum StorageStrategyType { files, mongodb }
+ public enum ShardingStrategyType { none, kafkalike }