org.apache.hadoop.hdfs.server.namenode.web.resources

## Class NamenodeWebHdfsMethods

- java.lang.Object
- - org.apache.hadoop.hdfs.server.namenode.web.resources.NamenodeWebHdfsMethods

-     public class NamenodeWebHdfsMethods
      extends Object

  Web-hdfs NameNode implementation.

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static org.slf4j.Logger` | `LOG`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `NamenodeWebHdfsMethods(javax.servlet.http.HttpServletRequest request)`

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `protected static org.apache.hadoop.hdfs.protocol.DatanodeInfo` | `bestNode(org.apache.hadoop.hdfs.protocol.DatanodeInfo[] nodes, HashSet<org.apache.hadoop.net.Node> excludes)` Choose the datanode to redirect the request.
    `void` | `cancelDelegationToken(org.apache.hadoop.security.token.Token<org.apache.hadoop.hdfs.security.token.delegation.DelegationTokenIdentifier> token)`
    `protected javax.ws.rs.core.Response` | `delete(org.apache.hadoop.security.UserGroupInformation ugi, org.apache.hadoop.hdfs.web.resources.DelegationParam delegation, org.apache.hadoop.hdfs.web.resources.UserParam username, org.apache.hadoop.hdfs.web.resources.DoAsParam doAsUser, String fullpath, org.apache.hadoop.hdfs.web.resources.DeleteOpParam op, org.apache.hadoop.hdfs.web.resources.RecursiveParam recursive, org.apache.hadoop.hdfs.web.resources.SnapshotNameParam snapshotName)`
    `javax.ws.rs.core.Response` | `delete(org.apache.hadoop.security.UserGroupInformation ugi, org.apache.hadoop.hdfs.web.resources.DelegationParam delegation, org.apache.hadoop.hdfs.web.resources.UserParam username, org.apache.hadoop.hdfs.web.resources.DoAsParam doAsUser, UriFsPathParam path, org.apache.hadoop.hdfs.web.resources.DeleteOpParam op, org.apache.hadoop.hdfs.web.resources.RecursiveParam recursive, org.apache.hadoop.hdfs.web.resources.SnapshotNameParam snapshotName)` Handle HTTP DELETE request.
    `javax.ws.rs.core.Response` | `deleteRoot(org.apache.hadoop.security.UserGroupInformation ugi, org.apache.hadoop.hdfs.web.resources.DelegationParam delegation, org.apache.hadoop.hdfs.web.resources.UserParam username, org.apache.hadoop.hdfs.web.resources.DoAsParam doAsUser, org.apache.hadoop.hdfs.web.resources.DeleteOpParam op, org.apache.hadoop.hdfs.web.resources.RecursiveParam recursive, org.apache.hadoop.hdfs.web.resources.SnapshotNameParam snapshotName)` Handle HTTP DELETE request for the root.
    `org.apache.hadoop.security.token.Token<? extends org.apache.hadoop.security.token.TokenIdentifier>` | `generateDelegationToken(org.apache.hadoop.security.UserGroupInformation ugi, String renewer)`
    `protected javax.ws.rs.core.Response` | `get(org.apache.hadoop.security.UserGroupInformation ugi, org.apache.hadoop.hdfs.web.resources.DelegationParam delegation, org.apache.hadoop.hdfs.web.resources.UserParam username, org.apache.hadoop.hdfs.web.resources.DoAsParam doAsUser, String fullpath, org.apache.hadoop.hdfs.web.resources.GetOpParam op, org.apache.hadoop.hdfs.web.resources.OffsetParam offset, org.apache.hadoop.hdfs.web.resources.LengthParam length, org.apache.hadoop.hdfs.web.resources.RenewerParam renewer, org.apache.hadoop.hdfs.web.resources.BufferSizeParam bufferSize, List<org.apache.hadoop.hdfs.web.resources.XAttrNameParam> xattrNames, org.apache.hadoop.hdfs.web.resources.XAttrEncodingParam xattrEncoding, org.apache.hadoop.hdfs.web.resources.ExcludeDatanodesParam excludeDatanodes, org.apache.hadoop.hdfs.web.resources.FsActionParam fsAction, org.apache.hadoop.hdfs.web.resources.SnapshotNameParam snapshotName, org.apache.hadoop.hdfs.web.resources.OldSnapshotNameParam oldSnapshotName, TokenKindParam tokenKind, TokenServiceParam tokenService, org.apache.hadoop.hdfs.web.resources.NoRedirectParam noredirectParam, org.apache.hadoop.hdfs.web.resources.StartAfterParam startAfter)`
    `javax.ws.rs.core.Response` | `get(org.apache.hadoop.security.UserGroupInformation ugi, org.apache.hadoop.hdfs.web.resources.DelegationParam delegation, org.apache.hadoop.hdfs.web.resources.UserParam username, org.apache.hadoop.hdfs.web.resources.DoAsParam doAsUser, UriFsPathParam path, org.apache.hadoop.hdfs.web.resources.GetOpParam op, org.apache.hadoop.hdfs.web.resources.OffsetParam offset, org.apache.hadoop.hdfs.web.resources.LengthParam length, org.apache.hadoop.hdfs.web.resources.RenewerParam renewer, org.apache.hadoop.hdfs.web.resources.BufferSizeParam bufferSize, List<org.apache.hadoop.hdfs.web.resources.XAttrNameParam> xattrNames, org.apache.hadoop.hdfs.web.resources.XAttrEncodingParam xattrEncoding, org.apache.hadoop.hdfs.web.resources.ExcludeDatanodesParam excludeDatanodes, org.apache.hadoop.hdfs.web.resources.FsActionParam fsAction, org.apache.hadoop.hdfs.web.resources.SnapshotNameParam snapshotName, org.apache.hadoop.hdfs.web.resources.OldSnapshotNameParam oldSnapshotName, TokenKindParam tokenKind, TokenServiceParam tokenService, org.apache.hadoop.hdfs.web.resources.NoRedirectParam noredirect, org.apache.hadoop.hdfs.web.resources.StartAfterParam startAfter)` Handle HTTP GET request.
    `protected javax.servlet.ServletContext` | `getContext()`
    `String` | `getParent(String path)` Returns the parent of a path in the same way as Path#getParent.
    `protected String` | `getRemoteAddr()`
    `javax.ws.rs.core.Response` | `getRoot(org.apache.hadoop.security.UserGroupInformation ugi, org.apache.hadoop.hdfs.web.resources.DelegationParam delegation, org.apache.hadoop.hdfs.web.resources.UserParam username, org.apache.hadoop.hdfs.web.resources.DoAsParam doAsUser, org.apache.hadoop.hdfs.web.resources.GetOpParam op, org.apache.hadoop.hdfs.web.resources.OffsetParam offset, org.apache.hadoop.hdfs.web.resources.LengthParam length, org.apache.hadoop.hdfs.web.resources.RenewerParam renewer, org.apache.hadoop.hdfs.web.resources.BufferSizeParam bufferSize, List<org.apache.hadoop.hdfs.web.resources.XAttrNameParam> xattrNames, org.apache.hadoop.hdfs.web.resources.XAttrEncodingParam xattrEncoding, org.apache.hadoop.hdfs.web.resources.ExcludeDatanodesParam excludeDatanodes, org.apache.hadoop.hdfs.web.resources.FsActionParam fsAction, org.apache.hadoop.hdfs.web.resources.SnapshotNameParam snapshotName, org.apache.hadoop.hdfs.web.resources.OldSnapshotNameParam oldSnapshotName, TokenKindParam tokenKind, TokenServiceParam tokenService, org.apache.hadoop.hdfs.web.resources.NoRedirectParam noredirect, org.apache.hadoop.hdfs.web.resources.StartAfterParam startAfter)` Handle HTTP GET request for the root.
    `protected org.apache.hadoop.hdfs.protocol.ClientProtocol` | `getRpcClientProtocol()`
    `protected String` | `getScheme()`
    `protected void` | `init(org.apache.hadoop.security.UserGroupInformation ugi, org.apache.hadoop.hdfs.web.resources.DelegationParam delegation, org.apache.hadoop.hdfs.web.resources.UserParam username, org.apache.hadoop.hdfs.web.resources.DoAsParam doAsUser, UriFsPathParam path, org.apache.hadoop.hdfs.web.resources.HttpOpParam<?> op, org.apache.hadoop.hdfs.web.resources.Param<?,?>... parameters)`
    `protected javax.ws.rs.core.Response` | `post(org.apache.hadoop.security.UserGroupInformation ugi, org.apache.hadoop.hdfs.web.resources.DelegationParam delegation, org.apache.hadoop.hdfs.web.resources.UserParam username, org.apache.hadoop.hdfs.web.resources.DoAsParam doAsUser, String fullpath, org.apache.hadoop.hdfs.web.resources.PostOpParam op, org.apache.hadoop.hdfs.web.resources.ConcatSourcesParam concatSrcs, org.apache.hadoop.hdfs.web.resources.BufferSizeParam bufferSize, org.apache.hadoop.hdfs.web.resources.ExcludeDatanodesParam excludeDatanodes, org.apache.hadoop.hdfs.web.resources.NewLengthParam newLength, org.apache.hadoop.hdfs.web.resources.NoRedirectParam noredirectParam)`
    `javax.ws.rs.core.Response` | `post(org.apache.hadoop.security.UserGroupInformation ugi, org.apache.hadoop.hdfs.web.resources.DelegationParam delegation, org.apache.hadoop.hdfs.web.resources.UserParam username, org.apache.hadoop.hdfs.web.resources.DoAsParam doAsUser, UriFsPathParam path, org.apache.hadoop.hdfs.web.resources.PostOpParam op, org.apache.hadoop.hdfs.web.resources.ConcatSourcesParam concatSrcs, org.apache.hadoop.hdfs.web.resources.BufferSizeParam bufferSize, org.apache.hadoop.hdfs.web.resources.ExcludeDatanodesParam excludeDatanodes, org.apache.hadoop.hdfs.web.resources.NewLengthParam newLength, org.apache.hadoop.hdfs.web.resources.NoRedirectParam noredirect)` Handle HTTP POST request.
    `javax.ws.rs.core.Response` | `postRoot(org.apache.hadoop.security.UserGroupInformation ugi, org.apache.hadoop.hdfs.web.resources.DelegationParam delegation, org.apache.hadoop.hdfs.web.resources.UserParam username, org.apache.hadoop.hdfs.web.resources.DoAsParam doAsUser, org.apache.hadoop.hdfs.web.resources.PostOpParam op, org.apache.hadoop.hdfs.web.resources.ConcatSourcesParam concatSrcs, org.apache.hadoop.hdfs.web.resources.BufferSizeParam bufferSize, org.apache.hadoop.hdfs.web.resources.ExcludeDatanodesParam excludeDatanodes, org.apache.hadoop.hdfs.web.resources.NewLengthParam newLength, org.apache.hadoop.hdfs.web.resources.NoRedirectParam noredirect)` Handle HTTP POST request for the root.
    `protected javax.ws.rs.core.Response` | `put(org.apache.hadoop.security.UserGroupInformation ugi, org.apache.hadoop.hdfs.web.resources.DelegationParam delegation, org.apache.hadoop.hdfs.web.resources.UserParam username, org.apache.hadoop.hdfs.web.resources.DoAsParam doAsUser, String fullpath, org.apache.hadoop.hdfs.web.resources.PutOpParam op, org.apache.hadoop.hdfs.web.resources.DestinationParam destination, org.apache.hadoop.hdfs.web.resources.OwnerParam owner, org.apache.hadoop.hdfs.web.resources.GroupParam group, org.apache.hadoop.hdfs.web.resources.PermissionParam permission, org.apache.hadoop.hdfs.web.resources.UnmaskedPermissionParam unmaskedPermission, org.apache.hadoop.hdfs.web.resources.OverwriteParam overwrite, org.apache.hadoop.hdfs.web.resources.BufferSizeParam bufferSize, org.apache.hadoop.hdfs.web.resources.ReplicationParam replication, org.apache.hadoop.hdfs.web.resources.BlockSizeParam blockSize, org.apache.hadoop.hdfs.web.resources.ModificationTimeParam modificationTime, org.apache.hadoop.hdfs.web.resources.AccessTimeParam accessTime, org.apache.hadoop.hdfs.web.resources.RenameOptionSetParam renameOptions, org.apache.hadoop.hdfs.web.resources.CreateParentParam createParent, org.apache.hadoop.hdfs.web.resources.TokenArgumentParam delegationTokenArgument, org.apache.hadoop.hdfs.web.resources.AclPermissionParam aclPermission, org.apache.hadoop.hdfs.web.resources.XAttrNameParam xattrName, org.apache.hadoop.hdfs.web.resources.XAttrValueParam xattrValue, org.apache.hadoop.hdfs.web.resources.XAttrSetFlagParam xattrSetFlag, org.apache.hadoop.hdfs.web.resources.SnapshotNameParam snapshotName, org.apache.hadoop.hdfs.web.resources.OldSnapshotNameParam oldSnapshotName, org.apache.hadoop.hdfs.web.resources.ExcludeDatanodesParam exclDatanodes, org.apache.hadoop.hdfs.web.resources.CreateFlagParam createFlagParam, org.apache.hadoop.hdfs.web.resources.NoRedirectParam noredirectParam, org.apache.hadoop.hdfs.web.resources.StoragePolicyParam policyName, org.apache.hadoop.hdfs.web.resources.ECPolicyParam ecpolicy, org.apache.hadoop.hdfs.web.resources.NameSpaceQuotaParam namespaceQuota, org.apache.hadoop.hdfs.web.resources.StorageSpaceQuotaParam storagespaceQuota, org.apache.hadoop.hdfs.web.resources.StorageTypeParam storageType)`
    `javax.ws.rs.core.Response` | `put(org.apache.hadoop.security.UserGroupInformation ugi, org.apache.hadoop.hdfs.web.resources.DelegationParam delegation, org.apache.hadoop.hdfs.web.resources.UserParam username, org.apache.hadoop.hdfs.web.resources.DoAsParam doAsUser, UriFsPathParam path, org.apache.hadoop.hdfs.web.resources.PutOpParam op, org.apache.hadoop.hdfs.web.resources.DestinationParam destination, org.apache.hadoop.hdfs.web.resources.OwnerParam owner, org.apache.hadoop.hdfs.web.resources.GroupParam group, org.apache.hadoop.hdfs.web.resources.PermissionParam permission, org.apache.hadoop.hdfs.web.resources.UnmaskedPermissionParam unmaskedPermission, org.apache.hadoop.hdfs.web.resources.OverwriteParam overwrite, org.apache.hadoop.hdfs.web.resources.BufferSizeParam bufferSize, org.apache.hadoop.hdfs.web.resources.ReplicationParam replication, org.apache.hadoop.hdfs.web.resources.BlockSizeParam blockSize, org.apache.hadoop.hdfs.web.resources.ModificationTimeParam modificationTime, org.apache.hadoop.hdfs.web.resources.AccessTimeParam accessTime, org.apache.hadoop.hdfs.web.resources.RenameOptionSetParam renameOptions, org.apache.hadoop.hdfs.web.resources.CreateParentParam createParent, org.apache.hadoop.hdfs.web.resources.TokenArgumentParam delegationTokenArgument, org.apache.hadoop.hdfs.web.resources.AclPermissionParam aclPermission, org.apache.hadoop.hdfs.web.resources.XAttrNameParam xattrName, org.apache.hadoop.hdfs.web.resources.XAttrValueParam xattrValue, org.apache.hadoop.hdfs.web.resources.XAttrSetFlagParam xattrSetFlag, org.apache.hadoop.hdfs.web.resources.SnapshotNameParam snapshotName, org.apache.hadoop.hdfs.web.resources.OldSnapshotNameParam oldSnapshotName, org.apache.hadoop.hdfs.web.resources.ExcludeDatanodesParam excludeDatanodes, org.apache.hadoop.hdfs.web.resources.CreateFlagParam createFlagParam, org.apache.hadoop.hdfs.web.resources.NoRedirectParam noredirect, org.apache.hadoop.hdfs.web.resources.StoragePolicyParam policyName, org.apache.hadoop.hdfs.web.resources.ECPolicyParam ecpolicy, org.apache.hadoop.hdfs.web.resources.NameSpaceQuotaParam namespaceQuota, org.apache.hadoop.hdfs.web.resources.StorageSpaceQuotaParam storagespaceQuota, org.apache.hadoop.hdfs.web.resources.StorageTypeParam storageType)` Handle HTTP PUT request.
    `javax.ws.rs.core.Response` | `putRoot(org.apache.hadoop.security.UserGroupInformation ugi, org.apache.hadoop.hdfs.web.resources.DelegationParam delegation, org.apache.hadoop.hdfs.web.resources.UserParam username, org.apache.hadoop.hdfs.web.resources.DoAsParam doAsUser, org.apache.hadoop.hdfs.web.resources.PutOpParam op, org.apache.hadoop.hdfs.web.resources.DestinationParam destination, org.apache.hadoop.hdfs.web.resources.OwnerParam owner, org.apache.hadoop.hdfs.web.resources.GroupParam group, org.apache.hadoop.hdfs.web.resources.PermissionParam permission, org.apache.hadoop.hdfs.web.resources.UnmaskedPermissionParam unmaskedPermission, org.apache.hadoop.hdfs.web.resources.OverwriteParam overwrite, org.apache.hadoop.hdfs.web.resources.BufferSizeParam bufferSize, org.apache.hadoop.hdfs.web.resources.ReplicationParam replication, org.apache.hadoop.hdfs.web.resources.BlockSizeParam blockSize, org.apache.hadoop.hdfs.web.resources.ModificationTimeParam modificationTime, org.apache.hadoop.hdfs.web.resources.AccessTimeParam accessTime, org.apache.hadoop.hdfs.web.resources.RenameOptionSetParam renameOptions, org.apache.hadoop.hdfs.web.resources.CreateParentParam createParent, org.apache.hadoop.hdfs.web.resources.TokenArgumentParam delegationTokenArgument, org.apache.hadoop.hdfs.web.resources.AclPermissionParam aclPermission, org.apache.hadoop.hdfs.web.resources.XAttrNameParam xattrName, org.apache.hadoop.hdfs.web.resources.XAttrValueParam xattrValue, org.apache.hadoop.hdfs.web.resources.XAttrSetFlagParam xattrSetFlag, org.apache.hadoop.hdfs.web.resources.SnapshotNameParam snapshotName, org.apache.hadoop.hdfs.web.resources.OldSnapshotNameParam oldSnapshotName, org.apache.hadoop.hdfs.web.resources.ExcludeDatanodesParam excludeDatanodes, org.apache.hadoop.hdfs.web.resources.CreateFlagParam createFlagParam, org.apache.hadoop.hdfs.web.resources.NoRedirectParam noredirect, org.apache.hadoop.hdfs.web.resources.StoragePolicyParam policyName, org.apache.hadoop.hdfs.web.resources.ECPolicyParam ecpolicy, org.apache.hadoop.hdfs.web.resources.NameSpaceQuotaParam namespaceQuota, org.apache.hadoop.hdfs.web.resources.StorageSpaceQuotaParam storagespaceQuota, org.apache.hadoop.hdfs.web.resources.StorageTypeParam storageType)` Handle HTTP PUT request for the root.
    `protected void` | `queueExternalCall(org.apache.hadoop.ipc.ExternalCall call)`
    `long` | `renewDelegationToken(org.apache.hadoop.security.token.Token<org.apache.hadoop.hdfs.security.token.delegation.DelegationTokenIdentifier> token)`
    `protected void` | `validateOpParams(org.apache.hadoop.hdfs.web.resources.HttpOpParam<?> op, org.apache.hadoop.hdfs.web.resources.Param... params)` Validate all required params.

    - ### Methods inherited from class java.lang.Object

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

- - ### Field Detail

    - #### LOG

          public static final org.slf4j.Logger LOG

  - ### Constructor Detail

    - #### NamenodeWebHdfsMethods

          public NamenodeWebHdfsMethods(@Context
                                        javax.servlet.http.HttpServletRequest request)

  - ### Method Detail

    - #### init

          protected void init(org.apache.hadoop.security.UserGroupInformation ugi,
                              org.apache.hadoop.hdfs.web.resources.DelegationParam delegation,
                              org.apache.hadoop.hdfs.web.resources.UserParam username,
                              org.apache.hadoop.hdfs.web.resources.DoAsParam doAsUser,
                              UriFsPathParam path,
                              org.apache.hadoop.hdfs.web.resources.HttpOpParam<?> op,
                              org.apache.hadoop.hdfs.web.resources.Param<?,?>... parameters)

    - #### getRpcClientProtocol

          protected org.apache.hadoop.hdfs.protocol.ClientProtocol getRpcClientProtocol()
                                                                                 throws IOException

      Throws:
        `IOException`

    - #### getScheme

          protected String getScheme()

    - #### getContext

          protected javax.servlet.ServletContext getContext()

    - #### getRemoteAddr

          protected String getRemoteAddr()

    - #### queueExternalCall

          protected void queueExternalCall(org.apache.hadoop.ipc.ExternalCall call)
                                    throws IOException,
                                           InterruptedException

      Throws:
        `IOException`
        `InterruptedException`

    - #### bestNode

          protected static org.apache.hadoop.hdfs.protocol.DatanodeInfo bestNode(org.apache.hadoop.hdfs.protocol.DatanodeInfo[] nodes,
                                                                                 HashSet<org.apache.hadoop.net.Node> excludes)
                                                                          throws IOException

      Choose the datanode to redirect the request. Note that the nodes have been sorted based on availability and network distances, thus it is sufficient to return the first element of the node here.
      Throws:
        `IOException`

    - #### renewDelegationToken

          public long renewDelegationToken(org.apache.hadoop.security.token.Token<org.apache.hadoop.hdfs.security.token.delegation.DelegationTokenIdentifier> token)
                                    throws IOException

      Throws:
        `IOException`

    - #### cancelDelegationToken

          public void cancelDelegationToken(org.apache.hadoop.security.token.Token<org.apache.hadoop.hdfs.security.token.delegation.DelegationTokenIdentifier> token)
                                     throws IOException

      Throws:
        `IOException`

    - #### generateDelegationToken

          public org.apache.hadoop.security.token.Token<? extends org.apache.hadoop.security.token.TokenIdentifier> generateDelegationToken(org.apache.hadoop.security.UserGroupInformation ugi,
                                                                                                                                            String renewer)
                                                                                                                                     throws IOException

      Throws:
        `IOException`

    - #### putRoot

          public javax.ws.rs.core.Response putRoot(@Context
                                                   org.apache.hadoop.security.UserGroupInformation ugi,
                                                   org.apache.hadoop.hdfs.web.resources.DelegationParam delegation,
                                                   org.apache.hadoop.hdfs.web.resources.UserParam username,
                                                   org.apache.hadoop.hdfs.web.resources.DoAsParam doAsUser,
                                                   org.apache.hadoop.hdfs.web.resources.PutOpParam op,
                                                   org.apache.hadoop.hdfs.web.resources.DestinationParam destination,
                                                   org.apache.hadoop.hdfs.web.resources.OwnerParam owner,
                                                   org.apache.hadoop.hdfs.web.resources.GroupParam group,
                                                   org.apache.hadoop.hdfs.web.resources.PermissionParam permission,
                                                   org.apache.hadoop.hdfs.web.resources.UnmaskedPermissionParam unmaskedPermission,
                                                   org.apache.hadoop.hdfs.web.resources.OverwriteParam overwrite,
                                                   org.apache.hadoop.hdfs.web.resources.BufferSizeParam bufferSize,
                                                   org.apache.hadoop.hdfs.web.resources.ReplicationParam replication,
                                                   org.apache.hadoop.hdfs.web.resources.BlockSizeParam blockSize,
                                                   org.apache.hadoop.hdfs.web.resources.ModificationTimeParam modificationTime,
                                                   org.apache.hadoop.hdfs.web.resources.AccessTimeParam accessTime,
                                                   org.apache.hadoop.hdfs.web.resources.RenameOptionSetParam renameOptions,
                                                   org.apache.hadoop.hdfs.web.resources.CreateParentParam createParent,
                                                   org.apache.hadoop.hdfs.web.resources.TokenArgumentParam delegationTokenArgument,
                                                   org.apache.hadoop.hdfs.web.resources.AclPermissionParam aclPermission,
                                                   org.apache.hadoop.hdfs.web.resources.XAttrNameParam xattrName,
                                                   org.apache.hadoop.hdfs.web.resources.XAttrValueParam xattrValue,
                                                   org.apache.hadoop.hdfs.web.resources.XAttrSetFlagParam xattrSetFlag,
                                                   org.apache.hadoop.hdfs.web.resources.SnapshotNameParam snapshotName,
                                                   org.apache.hadoop.hdfs.web.resources.OldSnapshotNameParam oldSnapshotName,
                                                   org.apache.hadoop.hdfs.web.resources.ExcludeDatanodesParam excludeDatanodes,
                                                   org.apache.hadoop.hdfs.web.resources.CreateFlagParam createFlagParam,
                                                   org.apache.hadoop.hdfs.web.resources.NoRedirectParam noredirect,
                                                   org.apache.hadoop.hdfs.web.resources.StoragePolicyParam policyName,
                                                   org.apache.hadoop.hdfs.web.resources.ECPolicyParam ecpolicy,
                                                   org.apache.hadoop.hdfs.web.resources.NameSpaceQuotaParam namespaceQuota,
                                                   org.apache.hadoop.hdfs.web.resources.StorageSpaceQuotaParam storagespaceQuota,
                                                   org.apache.hadoop.hdfs.web.resources.StorageTypeParam storageType)
                                            throws IOException,
                                                   InterruptedException

      Handle HTTP PUT request for the root.
      Throws:
        `IOException`
        `InterruptedException`

    - #### validateOpParams

          protected void validateOpParams(org.apache.hadoop.hdfs.web.resources.HttpOpParam<?> op,
                                          org.apache.hadoop.hdfs.web.resources.Param... params)

      Validate all required params.

    - #### put

          public javax.ws.rs.core.Response put(@Context
                                               org.apache.hadoop.security.UserGroupInformation ugi,
                                               org.apache.hadoop.hdfs.web.resources.DelegationParam delegation,
                                               org.apache.hadoop.hdfs.web.resources.UserParam username,
                                               org.apache.hadoop.hdfs.web.resources.DoAsParam doAsUser,
                                               UriFsPathParam path,
                                               org.apache.hadoop.hdfs.web.resources.PutOpParam op,
                                               org.apache.hadoop.hdfs.web.resources.DestinationParam destination,
                                               org.apache.hadoop.hdfs.web.resources.OwnerParam owner,
                                               org.apache.hadoop.hdfs.web.resources.GroupParam group,
                                               org.apache.hadoop.hdfs.web.resources.PermissionParam permission,
                                               org.apache.hadoop.hdfs.web.resources.UnmaskedPermissionParam unmaskedPermission,
                                               org.apache.hadoop.hdfs.web.resources.OverwriteParam overwrite,
                                               org.apache.hadoop.hdfs.web.resources.BufferSizeParam bufferSize,
                                               org.apache.hadoop.hdfs.web.resources.ReplicationParam replication,
                                               org.apache.hadoop.hdfs.web.resources.BlockSizeParam blockSize,
                                               org.apache.hadoop.hdfs.web.resources.ModificationTimeParam modificationTime,
                                               org.apache.hadoop.hdfs.web.resources.AccessTimeParam accessTime,
                                               org.apache.hadoop.hdfs.web.resources.RenameOptionSetParam renameOptions,
                                               org.apache.hadoop.hdfs.web.resources.CreateParentParam createParent,
                                               org.apache.hadoop.hdfs.web.resources.TokenArgumentParam delegationTokenArgument,
                                               org.apache.hadoop.hdfs.web.resources.AclPermissionParam aclPermission,
                                               org.apache.hadoop.hdfs.web.resources.XAttrNameParam xattrName,
                                               org.apache.hadoop.hdfs.web.resources.XAttrValueParam xattrValue,
                                               org.apache.hadoop.hdfs.web.resources.XAttrSetFlagParam xattrSetFlag,
                                               org.apache.hadoop.hdfs.web.resources.SnapshotNameParam snapshotName,
                                               org.apache.hadoop.hdfs.web.resources.OldSnapshotNameParam oldSnapshotName,
                                               org.apache.hadoop.hdfs.web.resources.ExcludeDatanodesParam excludeDatanodes,
                                               org.apache.hadoop.hdfs.web.resources.CreateFlagParam createFlagParam,
                                               org.apache.hadoop.hdfs.web.resources.NoRedirectParam noredirect,
                                               org.apache.hadoop.hdfs.web.resources.StoragePolicyParam policyName,
                                               org.apache.hadoop.hdfs.web.resources.ECPolicyParam ecpolicy,
                                               org.apache.hadoop.hdfs.web.resources.NameSpaceQuotaParam namespaceQuota,
                                               org.apache.hadoop.hdfs.web.resources.StorageSpaceQuotaParam storagespaceQuota,
                                               org.apache.hadoop.hdfs.web.resources.StorageTypeParam storageType)
                                        throws IOException,
                                               InterruptedException

      Handle HTTP PUT request.
      Throws:
        `IOException`
        `InterruptedException`

    - #### put

          protected javax.ws.rs.core.Response put(org.apache.hadoop.security.UserGroupInformation ugi,
                                                  org.apache.hadoop.hdfs.web.resources.DelegationParam delegation,
                                                  org.apache.hadoop.hdfs.web.resources.UserParam username,
                                                  org.apache.hadoop.hdfs.web.resources.DoAsParam doAsUser,
                                                  String fullpath,
                                                  org.apache.hadoop.hdfs.web.resources.PutOpParam op,
                                                  org.apache.hadoop.hdfs.web.resources.DestinationParam destination,
                                                  org.apache.hadoop.hdfs.web.resources.OwnerParam owner,
                                                  org.apache.hadoop.hdfs.web.resources.GroupParam group,
                                                  org.apache.hadoop.hdfs.web.resources.PermissionParam permission,
                                                  org.apache.hadoop.hdfs.web.resources.UnmaskedPermissionParam unmaskedPermission,
                                                  org.apache.hadoop.hdfs.web.resources.OverwriteParam overwrite,
                                                  org.apache.hadoop.hdfs.web.resources.BufferSizeParam bufferSize,
                                                  org.apache.hadoop.hdfs.web.resources.ReplicationParam replication,
                                                  org.apache.hadoop.hdfs.web.resources.BlockSizeParam blockSize,
                                                  org.apache.hadoop.hdfs.web.resources.ModificationTimeParam modificationTime,
                                                  org.apache.hadoop.hdfs.web.resources.AccessTimeParam accessTime,
                                                  org.apache.hadoop.hdfs.web.resources.RenameOptionSetParam renameOptions,
                                                  org.apache.hadoop.hdfs.web.resources.CreateParentParam createParent,
                                                  org.apache.hadoop.hdfs.web.resources.TokenArgumentParam delegationTokenArgument,
                                                  org.apache.hadoop.hdfs.web.resources.AclPermissionParam aclPermission,
                                                  org.apache.hadoop.hdfs.web.resources.XAttrNameParam xattrName,
                                                  org.apache.hadoop.hdfs.web.resources.XAttrValueParam xattrValue,
                                                  org.apache.hadoop.hdfs.web.resources.XAttrSetFlagParam xattrSetFlag,
                                                  org.apache.hadoop.hdfs.web.resources.SnapshotNameParam snapshotName,
                                                  org.apache.hadoop.hdfs.web.resources.OldSnapshotNameParam oldSnapshotName,
                                                  org.apache.hadoop.hdfs.web.resources.ExcludeDatanodesParam exclDatanodes,
                                                  org.apache.hadoop.hdfs.web.resources.CreateFlagParam createFlagParam,
                                                  org.apache.hadoop.hdfs.web.resources.NoRedirectParam noredirectParam,
                                                  org.apache.hadoop.hdfs.web.resources.StoragePolicyParam policyName,
                                                  org.apache.hadoop.hdfs.web.resources.ECPolicyParam ecpolicy,
                                                  org.apache.hadoop.hdfs.web.resources.NameSpaceQuotaParam namespaceQuota,
                                                  org.apache.hadoop.hdfs.web.resources.StorageSpaceQuotaParam storagespaceQuota,
                                                  org.apache.hadoop.hdfs.web.resources.StorageTypeParam storageType)
                                           throws IOException,
                                                  URISyntaxException

      Throws:
        `IOException`
        `URISyntaxException`

    - #### postRoot

          public javax.ws.rs.core.Response postRoot(@Context
                                                    org.apache.hadoop.security.UserGroupInformation ugi,
                                                    org.apache.hadoop.hdfs.web.resources.DelegationParam delegation,
                                                    org.apache.hadoop.hdfs.web.resources.UserParam username,
                                                    org.apache.hadoop.hdfs.web.resources.DoAsParam doAsUser,
                                                    org.apache.hadoop.hdfs.web.resources.PostOpParam op,
                                                    org.apache.hadoop.hdfs.web.resources.ConcatSourcesParam concatSrcs,
                                                    org.apache.hadoop.hdfs.web.resources.BufferSizeParam bufferSize,
                                                    org.apache.hadoop.hdfs.web.resources.ExcludeDatanodesParam excludeDatanodes,
                                                    org.apache.hadoop.hdfs.web.resources.NewLengthParam newLength,
                                                    org.apache.hadoop.hdfs.web.resources.NoRedirectParam noredirect)
                                             throws IOException,
                                                    InterruptedException

      Handle HTTP POST request for the root.
      Throws:
        `IOException`
        `InterruptedException`

    - #### post

          public javax.ws.rs.core.Response post(@Context
                                                org.apache.hadoop.security.UserGroupInformation ugi,
                                                org.apache.hadoop.hdfs.web.resources.DelegationParam delegation,
                                                org.apache.hadoop.hdfs.web.resources.UserParam username,
                                                org.apache.hadoop.hdfs.web.resources.DoAsParam doAsUser,
                                                UriFsPathParam path,
                                                org.apache.hadoop.hdfs.web.resources.PostOpParam op,
                                                org.apache.hadoop.hdfs.web.resources.ConcatSourcesParam concatSrcs,
                                                org.apache.hadoop.hdfs.web.resources.BufferSizeParam bufferSize,
                                                org.apache.hadoop.hdfs.web.resources.ExcludeDatanodesParam excludeDatanodes,
                                                org.apache.hadoop.hdfs.web.resources.NewLengthParam newLength,
                                                org.apache.hadoop.hdfs.web.resources.NoRedirectParam noredirect)
                                         throws IOException,
                                                InterruptedException

      Handle HTTP POST request.
      Throws:
        `IOException`
        `InterruptedException`

    - #### post

          protected javax.ws.rs.core.Response post(org.apache.hadoop.security.UserGroupInformation ugi,
                                                   org.apache.hadoop.hdfs.web.resources.DelegationParam delegation,
                                                   org.apache.hadoop.hdfs.web.resources.UserParam username,
                                                   org.apache.hadoop.hdfs.web.resources.DoAsParam doAsUser,
                                                   String fullpath,
                                                   org.apache.hadoop.hdfs.web.resources.PostOpParam op,
                                                   org.apache.hadoop.hdfs.web.resources.ConcatSourcesParam concatSrcs,
                                                   org.apache.hadoop.hdfs.web.resources.BufferSizeParam bufferSize,
                                                   org.apache.hadoop.hdfs.web.resources.ExcludeDatanodesParam excludeDatanodes,
                                                   org.apache.hadoop.hdfs.web.resources.NewLengthParam newLength,
                                                   org.apache.hadoop.hdfs.web.resources.NoRedirectParam noredirectParam)
                                            throws IOException,
                                                   URISyntaxException

      Throws:
        `IOException`
        `URISyntaxException`

    - #### getRoot

          public javax.ws.rs.core.Response getRoot(@Context
                                                   org.apache.hadoop.security.UserGroupInformation ugi,
                                                   org.apache.hadoop.hdfs.web.resources.DelegationParam delegation,
                                                   org.apache.hadoop.hdfs.web.resources.UserParam username,
                                                   org.apache.hadoop.hdfs.web.resources.DoAsParam doAsUser,
                                                   org.apache.hadoop.hdfs.web.resources.GetOpParam op,
                                                   org.apache.hadoop.hdfs.web.resources.OffsetParam offset,
                                                   org.apache.hadoop.hdfs.web.resources.LengthParam length,
                                                   org.apache.hadoop.hdfs.web.resources.RenewerParam renewer,
                                                   org.apache.hadoop.hdfs.web.resources.BufferSizeParam bufferSize,
                                                   List<org.apache.hadoop.hdfs.web.resources.XAttrNameParam> xattrNames,
                                                   org.apache.hadoop.hdfs.web.resources.XAttrEncodingParam xattrEncoding,
                                                   org.apache.hadoop.hdfs.web.resources.ExcludeDatanodesParam excludeDatanodes,
                                                   org.apache.hadoop.hdfs.web.resources.FsActionParam fsAction,
                                                   org.apache.hadoop.hdfs.web.resources.SnapshotNameParam snapshotName,
                                                   org.apache.hadoop.hdfs.web.resources.OldSnapshotNameParam oldSnapshotName,
                                                   TokenKindParam tokenKind,
                                                   TokenServiceParam tokenService,
                                                   org.apache.hadoop.hdfs.web.resources.NoRedirectParam noredirect,
                                                   org.apache.hadoop.hdfs.web.resources.StartAfterParam startAfter)
                                            throws IOException,
                                                   InterruptedException

      Handle HTTP GET request for the root.
      Throws:
        `IOException`
        `InterruptedException`

    - #### get

          public javax.ws.rs.core.Response get(@Context
                                               org.apache.hadoop.security.UserGroupInformation ugi,
                                               org.apache.hadoop.hdfs.web.resources.DelegationParam delegation,
                                               org.apache.hadoop.hdfs.web.resources.UserParam username,
                                               org.apache.hadoop.hdfs.web.resources.DoAsParam doAsUser,
                                               UriFsPathParam path,
                                               org.apache.hadoop.hdfs.web.resources.GetOpParam op,
                                               org.apache.hadoop.hdfs.web.resources.OffsetParam offset,
                                               org.apache.hadoop.hdfs.web.resources.LengthParam length,
                                               org.apache.hadoop.hdfs.web.resources.RenewerParam renewer,
                                               org.apache.hadoop.hdfs.web.resources.BufferSizeParam bufferSize,
                                               List<org.apache.hadoop.hdfs.web.resources.XAttrNameParam> xattrNames,
                                               org.apache.hadoop.hdfs.web.resources.XAttrEncodingParam xattrEncoding,
                                               org.apache.hadoop.hdfs.web.resources.ExcludeDatanodesParam excludeDatanodes,
                                               org.apache.hadoop.hdfs.web.resources.FsActionParam fsAction,
                                               org.apache.hadoop.hdfs.web.resources.SnapshotNameParam snapshotName,
                                               org.apache.hadoop.hdfs.web.resources.OldSnapshotNameParam oldSnapshotName,
                                               TokenKindParam tokenKind,
                                               TokenServiceParam tokenService,
                                               org.apache.hadoop.hdfs.web.resources.NoRedirectParam noredirect,
                                               org.apache.hadoop.hdfs.web.resources.StartAfterParam startAfter)
                                        throws IOException,
                                               InterruptedException

      Handle HTTP GET request.
      Throws:
        `IOException`
        `InterruptedException`

    - #### get

          protected javax.ws.rs.core.Response get(org.apache.hadoop.security.UserGroupInformation ugi,
                                                  org.apache.hadoop.hdfs.web.resources.DelegationParam delegation,
                                                  org.apache.hadoop.hdfs.web.resources.UserParam username,
                                                  org.apache.hadoop.hdfs.web.resources.DoAsParam doAsUser,
                                                  String fullpath,
                                                  org.apache.hadoop.hdfs.web.resources.GetOpParam op,
                                                  org.apache.hadoop.hdfs.web.resources.OffsetParam offset,
                                                  org.apache.hadoop.hdfs.web.resources.LengthParam length,
                                                  org.apache.hadoop.hdfs.web.resources.RenewerParam renewer,
                                                  org.apache.hadoop.hdfs.web.resources.BufferSizeParam bufferSize,
                                                  List<org.apache.hadoop.hdfs.web.resources.XAttrNameParam> xattrNames,
                                                  org.apache.hadoop.hdfs.web.resources.XAttrEncodingParam xattrEncoding,
                                                  org.apache.hadoop.hdfs.web.resources.ExcludeDatanodesParam excludeDatanodes,
                                                  org.apache.hadoop.hdfs.web.resources.FsActionParam fsAction,
                                                  org.apache.hadoop.hdfs.web.resources.SnapshotNameParam snapshotName,
                                                  org.apache.hadoop.hdfs.web.resources.OldSnapshotNameParam oldSnapshotName,
                                                  TokenKindParam tokenKind,
                                                  TokenServiceParam tokenService,
                                                  org.apache.hadoop.hdfs.web.resources.NoRedirectParam noredirectParam,
                                                  org.apache.hadoop.hdfs.web.resources.StartAfterParam startAfter)
                                           throws IOException,
                                                  URISyntaxException

      Throws:
        `IOException`
        `URISyntaxException`

    - #### getParent

          public String getParent(String path)

      Returns the parent of a path in the same way as Path#getParent.
      Returns:
        the parent of a path or null if at root

    - #### deleteRoot

          public javax.ws.rs.core.Response deleteRoot(@Context
                                                      org.apache.hadoop.security.UserGroupInformation ugi,
                                                      org.apache.hadoop.hdfs.web.resources.DelegationParam delegation,
                                                      org.apache.hadoop.hdfs.web.resources.UserParam username,
                                                      org.apache.hadoop.hdfs.web.resources.DoAsParam doAsUser,
                                                      org.apache.hadoop.hdfs.web.resources.DeleteOpParam op,
                                                      org.apache.hadoop.hdfs.web.resources.RecursiveParam recursive,
                                                      org.apache.hadoop.hdfs.web.resources.SnapshotNameParam snapshotName)
                                               throws IOException,
                                                      InterruptedException

      Handle HTTP DELETE request for the root.
      Throws:
        `IOException`
        `InterruptedException`

    - #### delete

          public javax.ws.rs.core.Response delete(@Context
                                                  org.apache.hadoop.security.UserGroupInformation ugi,
                                                  org.apache.hadoop.hdfs.web.resources.DelegationParam delegation,
                                                  org.apache.hadoop.hdfs.web.resources.UserParam username,
                                                  org.apache.hadoop.hdfs.web.resources.DoAsParam doAsUser,
                                                  UriFsPathParam path,
                                                  org.apache.hadoop.hdfs.web.resources.DeleteOpParam op,
                                                  org.apache.hadoop.hdfs.web.resources.RecursiveParam recursive,
                                                  org.apache.hadoop.hdfs.web.resources.SnapshotNameParam snapshotName)
                                           throws IOException,
                                                  InterruptedException

      Handle HTTP DELETE request.
      Throws:
        `IOException`
        `InterruptedException`

    - #### delete

          protected javax.ws.rs.core.Response delete(org.apache.hadoop.security.UserGroupInformation ugi,
                                                     org.apache.hadoop.hdfs.web.resources.DelegationParam delegation,
                                                     org.apache.hadoop.hdfs.web.resources.UserParam username,
                                                     org.apache.hadoop.hdfs.web.resources.DoAsParam doAsUser,
                                                     String fullpath,
                                                     org.apache.hadoop.hdfs.web.resources.DeleteOpParam op,
                                                     org.apache.hadoop.hdfs.web.resources.RecursiveParam recursive,
                                                     org.apache.hadoop.hdfs.web.resources.SnapshotNameParam snapshotName)
                                              throws IOException

      Throws:
        `IOException`

Copyright © 2008–2022 Apache Software Foundation. All rights reserved.