code: protected void writeResponse(final HttpStatus httpStatus,
                                   final String httpBodyReason,
                                   final NextFilter nextFilter,
                                   final IoSession session,
                                   final HttpRequestMessage httpRequest) {
          // service context not found, create, for example, a HTTP 404 Not Found response
          HttpResponseMessage httpResponse = new HttpResponseMessage();
          httpResponse.setVersion(httpRequest.getVersion());
          httpResponse.setStatus(httpStatus);
          if (httpBodyReason != null) {
              httpResponse.setBodyReason(httpBodyReason);
          }
          nextFilter.filterWrite(session, new DefaultWriteRequestEx(httpResponse, new DefaultWriteFutureEx(session)));
      }
docs: Write a response back to the client (downstream) with a particular Http Status code.
  
  @param httpStatus the http status to write onto the response
  @param httpBodyReason the http status reason to write into the <em>body</em> of the message
  @param nextFilter the next filter to write the reply to
  @param session    the client session
  @param httpRequest the originating http request