Rrd4j only stores one datapoint

When one wants to call previuosState, they want the previous state of the Item. Consider this scenario. Item changes state which gets saved. Two minutes pass. Now I want to know what the state before the current state was even if it was the same. But I can’t know that. If I call previousState(true) it will skip the previous state of it was the same as the current state and go before the previous state. If I use previodState, when it returns the same state as the Item’s current state, I can’t know if that is the actual previous state or the current state saved in the past minute. It’s impossible to determine if the previous state was the same as the current state (i.e. received update to the same state). There is no way to tell if the value returned came from an update or just the usual every minute saved value.

It’s also impossible to determine how long it’s been since the last update you an item since there is no way to tell the difference between an update to the same state or one of the every minute saves.

Both are calls and useful use cases that are impossible with rrd4j.

1 Like