count records. Synchronous version.
int countSync(DatabaseClient client) => getKeysSync(client).length;