fix some design bugs
Merge remote-tracking branch 'origin/develop' into mongodb