handle cross-origin request using preflight
remove dead code from PlannerServlet
fix handling of invalid request data