Redesign code and increase test coverage. Implemented application context to be readonly.