1 package de.juplo.kafka;
3 import lombok.ToString;
4 import org.springframework.data.annotation.Id;
5 import org.springframework.data.mongodb.core.mapping.Document;
7 import java.util.HashMap;
11 @Document(collection = "statistics")
13 public class StatisticsDocument
17 public long offset = -1l;
18 public Map<String, Long> statistics;
20 public StatisticsDocument()
24 public StatisticsDocument(Integer partition)
26 this.id = Integer.toString(partition);
27 this.statistics = new HashMap<>();
30 public StatisticsDocument(Integer partition, Map<String, Long> statistics, long offset)
32 this.id = Integer.toString(partition);
33 this.statistics = statistics;