eliminated context factory issue and better parameterized