Interface NioLifecycleListener

All Known Implementing Classes:
BootNioLifecycleHandler

public interface NioLifecycleListener
Version:
1.0
Author:
Changski Tie Zheng Zhang 张铁铮, 魏泽北, 杜旺财, 杜富贵
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    afterLogging(String logContent, io.netty.handler.codec.http.HttpHeaders httpHeaders, io.netty.handler.codec.http.HttpMethod httpMethod, String httpRequestUri, String httpPostRequestBody, ServiceContext context, long queuingTime, long processTime, long responseTime, long responseContentLength, Throwable ioEx)
    step4
    void
    afterProcess(RequestProcessor processor, io.netty.channel.ChannelHandlerContext ctx, io.netty.handler.codec.http.HttpHeaders httpRequestHeaders, io.netty.handler.codec.http.HttpMethod httptMethod, String httpRequestPath, Map<String,List<String>> queryParams, String httpPostRequestBody, ServiceContext context)
    step1
    beforeLogging(String originallLogContent, io.netty.handler.codec.http.HttpHeaders httpHeaders, io.netty.handler.codec.http.HttpMethod httpMethod, String httpRequestUri, String httpPostRequestBody, ServiceContext context, long queuingTime, long processTime, long responseTime, long responseContentLength, Throwable ioEx)
    step3
    beforeSendingError(String errorContent)
    step2
    boolean
    beofreProcess(RequestProcessor processor, io.netty.handler.codec.http.HttpHeaders httpRequestHeaders, String httpRequestPath, ServiceContext context)
    step0 - do any validation checks before processing
  • Method Details

    • beofreProcess

      boolean beofreProcess(RequestProcessor processor, io.netty.handler.codec.http.HttpHeaders httpRequestHeaders, String httpRequestPath, ServiceContext context) throws Exception
      step0 - do any validation checks before processing
      Parameters:
      processor -
      httpRequestHeaders -
      httpRequestPath -
      context -
      Returns:
      true if good to process request, otherwise false
      Throws:
      Exception
    • afterProcess

      void afterProcess(RequestProcessor processor, io.netty.channel.ChannelHandlerContext ctx, io.netty.handler.codec.http.HttpHeaders httpRequestHeaders, io.netty.handler.codec.http.HttpMethod httptMethod, String httpRequestPath, Map<String,List<String>> queryParams, String httpPostRequestBody, ServiceContext context)
      step1
      Parameters:
      processor -
      ctx -
      httpRequestHeaders -
      httptMethod -
      httpRequestPath -
      queryParams -
      httpPostRequestBody -
      context -
    • beforeSendingError

      String beforeSendingError(String errorContent)
      step2
      Parameters:
      errorContent -
      Returns:
    • beforeLogging

      String beforeLogging(String originallLogContent, io.netty.handler.codec.http.HttpHeaders httpHeaders, io.netty.handler.codec.http.HttpMethod httpMethod, String httpRequestUri, String httpPostRequestBody, ServiceContext context, long queuingTime, long processTime, long responseTime, long responseContentLength, Throwable ioEx)
      step3
      Parameters:
      originallLogContent -
      httpHeaders -
      httpMethod -
      httpRequestUri -
      httpPostRequestBody -
      context -
      queuingTime -
      processTime -
      responseTime -
      responseContentLength -
      ioEx -
      Returns:
    • afterLogging

      void afterLogging(String logContent, io.netty.handler.codec.http.HttpHeaders httpHeaders, io.netty.handler.codec.http.HttpMethod httpMethod, String httpRequestUri, String httpPostRequestBody, ServiceContext context, long queuingTime, long processTime, long responseTime, long responseContentLength, Throwable ioEx) throws Exception
      step4
      Parameters:
      logContent -
      httpHeaders -
      httpMethod -
      httpRequestUri -
      httpPostRequestBody -
      context -
      queuingTime -
      processTime -
      responseTime -
      responseContentLength -
      ioEx -
      Throws:
      Exception