java.lang.Object
io.netty.channel.ChannelHandlerAdapter
io.netty.channel.ChannelInboundHandlerAdapter
io.netty.channel.SimpleChannelInboundHandler<io.netty.handler.codec.http.HttpRequest>
org.apache.hadoop.hdfs.server.datanode.web.webhdfs.WebHdfsHandler
All Implemented Interfaces:
io.netty.channel.ChannelHandler, io.netty.channel.ChannelInboundHandler

public class WebHdfsHandler extends io.netty.channel.SimpleChannelInboundHandler<io.netty.handler.codec.http.HttpRequest>
  • Nested Class Summary

    Nested classes/interfaces inherited from interface io.netty.channel.ChannelHandler

    io.netty.channel.ChannelHandler.Sharable
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final String
     
    static final String
     
    static final EnumSet<org.apache.hadoop.fs.CreateFlag>
     
    static final String
     
    static final int
     
  • Constructor Summary

    Constructors
    Constructor
    Description
    WebHdfsHandler(org.apache.hadoop.conf.Configuration conf, org.apache.hadoop.conf.Configuration confForCreate)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    channelRead0(io.netty.channel.ChannelHandlerContext ctx, io.netty.handler.codec.http.HttpRequest req)
     
    void
    exceptionCaught(io.netty.channel.ChannelHandlerContext ctx, Throwable cause)
     
    void
    handle(io.netty.channel.ChannelHandlerContext ctx, io.netty.handler.codec.http.HttpRequest req)
     

    Methods inherited from class io.netty.channel.SimpleChannelInboundHandler

    acceptInboundMessage, channelRead

    Methods inherited from class io.netty.channel.ChannelInboundHandlerAdapter

    channelActive, channelInactive, channelReadComplete, channelRegistered, channelUnregistered, channelWritabilityChanged, userEventTriggered

    Methods inherited from class io.netty.channel.ChannelHandlerAdapter

    ensureNotSharable, handlerAdded, handlerRemoved, isSharable

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface io.netty.channel.ChannelHandler

    handlerAdded, handlerRemoved
  • Field Details

    • WEBHDFS_PREFIX

      public static final String WEBHDFS_PREFIX
      See Also:
    • WEBHDFS_PREFIX_LENGTH

      public static final int WEBHDFS_PREFIX_LENGTH
    • APPLICATION_OCTET_STREAM

      public static final String APPLICATION_OCTET_STREAM
      See Also:
    • APPLICATION_JSON_UTF8

      public static final String APPLICATION_JSON_UTF8
      See Also:
    • EMPTY_CREATE_FLAG

      public static final EnumSet<org.apache.hadoop.fs.CreateFlag> EMPTY_CREATE_FLAG
  • Constructor Details

    • WebHdfsHandler

      public WebHdfsHandler(org.apache.hadoop.conf.Configuration conf, org.apache.hadoop.conf.Configuration confForCreate) throws IOException
      Throws:
      IOException
  • Method Details

    • channelRead0

      public void channelRead0(io.netty.channel.ChannelHandlerContext ctx, io.netty.handler.codec.http.HttpRequest req) throws Exception
      Specified by:
      channelRead0 in class io.netty.channel.SimpleChannelInboundHandler<io.netty.handler.codec.http.HttpRequest>
      Throws:
      Exception
    • handle

      public void handle(io.netty.channel.ChannelHandlerContext ctx, io.netty.handler.codec.http.HttpRequest req) throws IOException, URISyntaxException
      Throws:
      IOException
      URISyntaxException
    • exceptionCaught

      public void exceptionCaught(io.netty.channel.ChannelHandlerContext ctx, Throwable cause)
      Specified by:
      exceptionCaught in interface io.netty.channel.ChannelHandler
      Specified by:
      exceptionCaught in interface io.netty.channel.ChannelInboundHandler
      Overrides:
      exceptionCaught in class io.netty.channel.ChannelInboundHandlerAdapter