Fixes #868 Fixes #778 Fixes attributes passing wrong key to persistent meta Fixes blob compatibility with JDBC driver for persistent meta Fix stackoverflow from countEntities under certain circumstances Minor cleanup