rally code implementation