public void execute(Request request, Response response) {
    try {
      ActionExtractor actionExtractor = new ActionExtractor(request.getPath());
      WebService.Action foundAction = getAction(actionExtractor);
      WebService.Action action = checkFound(foundAction, "Unknown url : %s", request.getPath());
      if (request instanceof ValidatingRequest validatingRequest) {
        validatingRequest.setAction(action);
        validatingRequest.setLocalConnector(this);
      }
      checkActionExtension(actionExtractor.getExtension());
      verifyRequest(action, request);
      preAction(action, request);
      action.handler().handle(request, response);
    } catch (IllegalArgumentException e) {
      sendErrors(request, response, e, 400, singletonList(e.getMessage()));
    } catch (BadConfigurationException e) {
      sendErrors(request, response, e, 400, e.errors(), e.scope());
    } catch (BadRequestException e) {
      sendErrors(request, response, e, 400, e.errors());
    } catch (ServerException e) {
      sendErrors(request, response, e, e.httpCode(), singletonList(e.getMessage()));
    } catch (Exception e) {
      sendErrors(request, response, e, 500, singletonList("An error has occurred. Please contact your administrator"));
    }
  }
@Test
  public void fail_when_start_in_not_called() {
    Request request = new TestRequest().setPath("/api/ping");
    DumbResponse response = new DumbResponse();
    WebServiceEngine underTest = new WebServiceEngine(new WebService[] {
      newPingWs(a -> {
      })}, new ActionInterceptor[] {});

    underTest.execute(request, response);

    assertThat(logTester.logs(Level.ERROR)).contains("Fail to process request /api/ping");
  }