Improve ZooKeeper-relevent code quality (WORK-IN-PROGRESS, DON'T MERGE)

Variable naming and locations, code format, and other design issues,
etc