ticket:3 merging t3_middleware branch to master