If you pass a valid, but non-existent, UUID to the delete-session-stats command, it will wrongly claim that the non-existent session was deleted. The plugin should inform the command sender that no such session exists.
Two potential solutions:
Throw NoSuchElementException/IllegalArgumentException from the StatsStore implementation(s) and catch the exception in the command.
Modify the StatsStore interface to return a boolean; true for success, false for failure. This should be possible on the JDBI side of things by just checking for the number of affected rows after statement execution.
If you pass a valid, but non-existent, UUID to the
delete-session-stats
command, it will wrongly claim that the non-existent session was deleted. The plugin should inform the command sender that no such session exists.Two potential solutions: