Class DigestUserEntity

java.lang.Object
io.meeds.commons.digest.entity.DigestUserEntity

@Entity(name="DigestUser") public class DigestUserEntity extends Object
The work list of the digest sender job: one row per user having at least one digest frequency enabled, nobody else. The category lists are not stored here, they are read from the user settings.

Two writers share the row: the sender job, which moves a watermark with a guarded update, and the settings save, which rewrites the frequencies and the timezone from the row it read. @DynamicUpdate is what keeps them apart: without it Hibernate writes every column from the state the second writer loaded, and a watermark claimed in between would be undone, serving the same occurrence twice.

  • Constructor Details

    • DigestUserEntity

      public DigestUserEntity()