some rework
some intergration changes