maximumSince isn't the maximum

Please How to use code fences for code and logs.

What database are you persisting the data to? If it’s rrd4j it might be an artifact of how the data is compressed as it ages.

It takes some time for an update to actually get written out to the database so I would not expect that the call to maximumSince(now.minusDays(1)).state would include the value you just posted to the Item. However, enough time has passed after that call for the maximumSince(now.minusDays(7)) to include the most recent value. Would that explain the difference you see?