correction to make servlet more extensible and configurable