minor changes
Remove some unnecessary mothod and other minor changes
Add methods in assigment model, implementing the core alogrithm
Implementing Alogorithm
move some methods to instance model and workergroup model. Implemented the
core part of the algorithm. need to do db optimization to speed.
fix minor bugs
minor changes, improve performance