public void log(String remoteAddress, ContainerRequest jerseyRequest, ContainerResponse jettyResponse) {
    WebsocketEvent event = new WebsocketEvent(remoteAddress, jerseyRequest, jettyResponse);

    if (getFilterChainDecision(event) == FilterReply.DENY) {
      return;
    }

    aai.appendLoopOnAppenders(event);
  }
@Test
  void testLogLineWithoutHeaders() throws InterruptedException {
    WebSocketSessionContext sessionContext = mock(WebSocketSessionContext.class);

    ListAppender<WebsocketEvent> listAppender = new ListAppender<>();
    WebsocketRequestLoggerFactory requestLoggerFactory = new WebsocketRequestLoggerFactory();
    requestLoggerFactory.appenders = List.of(new ListAppenderFactory<>(listAppender));

    WebsocketRequestLog requestLog = requestLoggerFactory.build("test-logger");
    ContainerRequest request = new ContainerRequest(null, URI.create("/v1/test"), "GET",
        new WebSocketSecurityContext(new ContextPrincipal(sessionContext)), new MapPropertiesDelegate(new HashMap<>()),
        null);
    ContainerResponse response = new ContainerResponse(request, Response.ok("My response body").build());

    requestLog.log("123.456.789.123", request, response);

    listAppender.waitForListSize(1);
    assertThat(listAppender.list.size()).isEqualTo(1);

    String loggedLine = new String(listAppender.outputStream.toByteArray());
    assertThat(loggedLine).matches(
        "123\\.456\\.789\\.123 \\- \\- \\[[0-9]{2}\\/[a-zA-Z]{3}\\/[0-9]{4}:[0-9]{2}:[0-9]{2}:[0-9]{2} (\\-|\\+)[0-9]{4}\\] \"GET \\/v1\\/test WS\" 200 \\- \"\\-\" \"\\-\"\n");
  }