[server] Check store id validity in a few RPC.
[server] Improve db connection pool.
Remove unused code.
[server] return NULL if username is empty in check_repo_permission
[client] Fix a bug in merge.

Reproduce sequence (only for version 0 repo):
1. Both client and server change the same file;
2. Client syncs and do a real merge and fails with conflict;
3. The 30-second auto syncing timer kicks in, sync state [initializing] -> [merging];
4. Merge returns "Already up to date".
5. Afterwards, every sync of this repo will stuck in "Already up to date".
Merge branch '3.0'
update msi/deb version to 3.0.4