replace servlet with context listener