Fixes #136: replaces read model implementation by iterative approach instead of a recursion