hadoop-hdfs-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Vinayakumar B (JIRA)" <j...@apache.org>
Subject [jira] [Comment Edited] (HDFS-8231) StackTrace displayed at client while QuotaByStorageType exceeds
Date Fri, 24 Apr 2015 06:08:40 GMT

    [ https://issues.apache.org/jira/browse/HDFS-8231?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14510493#comment-14510493
] 

Vinayakumar B edited comment on HDFS-8231 at 4/24/15 6:08 AM:
--------------------------------------------------------------

bq. I think the correct fix is to extend QuotaByStorageTypeExceededException from DSQuotaExceededException.
As StorageType is only applicable for the disk usage,
Oops. This wont work. ;), Though logically this is correct, but it will not avoid logging
stacktrace. Because {{RemoteException#unwrapRemoteException(..)}} compares just the classnames,
not {{instanceof}}.
Along with the above fix suggested by [~cnauroth], Still I recommend to extend {{QuotaByStorageTypeExceededException}}
from {{DSQuotaExceededException}} and remove call to {{super.getMessage()}} in {{QuotaByStorageTypeExceededException#getMessage()}}
to get the correct message.

{{QuotaByStorageTypeExceededException}} should be added to Terse exception list to avoid traces
at NameNode side. Changes to be done at {{NameNodeRPCServer}} constructor at following point.
{code}// Set terse exception whose stack trace won't be logged
    clientRpcServer.addTerseExceptions(SafeModeException.class,
        FileNotFoundException.class,
        HadoopIllegalArgumentException.class,
        FileAlreadyExistsException.class,
        InvalidPathException.class,
        ParentNotDirectoryException.class,
        UnresolvedLinkException.class,
        AlreadyBeingCreatedException.class,
        QuotaExceededException.class,
        RecoveryInProgressException.class,
        AccessControlException.class,
        InvalidToken.class,
        LeaseExpiredException.class,
        NSQuotaExceededException.class,
        DSQuotaExceededException.class,
        AclException.class,
        FSLimitException.PathComponentTooLongException.class,
        FSLimitException.MaxDirectoryItemsExceededException.class,
        UnresolvedPathException.class);{code}


was (Author: vinayrpet):
bq. I think the correct fix is to extend QuotaByStorageTypeExceededException from DSQuotaExceededException.
As StorageType is only applicable for the disk usage,
Oops. This wont work. ;), Though logically this is correct, but it will not avoid logging
stacktrace. Because {{RemoteException#unwrapRemoteException(..)}} compares just the classnames,
not {{instanceof}}.
Along with the above fix suggested by [~cnauroth], Still I recommend to extend {{QuotaByStorageTypeExceededException}}
from {{DSQuotaExceededException}} and remove call to {{super.getMessage()}} in {{QuotaByStorageTypeExceededException#toString()}}
to get the correct message.

{{QuotaByStorageTypeExceededException}} should be added to Terse exception list to avoid traces
at NameNode side. Changes to be done at {{NameNodeRPCServer}} constructor at following point.
{code}// Set terse exception whose stack trace won't be logged
    clientRpcServer.addTerseExceptions(SafeModeException.class,
        FileNotFoundException.class,
        HadoopIllegalArgumentException.class,
        FileAlreadyExistsException.class,
        InvalidPathException.class,
        ParentNotDirectoryException.class,
        UnresolvedLinkException.class,
        AlreadyBeingCreatedException.class,
        QuotaExceededException.class,
        RecoveryInProgressException.class,
        AccessControlException.class,
        InvalidToken.class,
        LeaseExpiredException.class,
        NSQuotaExceededException.class,
        DSQuotaExceededException.class,
        AclException.class,
        FSLimitException.PathComponentTooLongException.class,
        FSLimitException.MaxDirectoryItemsExceededException.class,
        UnresolvedPathException.class);{code}

> StackTrace displayed at client while QuotaByStorageType exceeds
> ---------------------------------------------------------------
>
>                 Key: HDFS-8231
>                 URL: https://issues.apache.org/jira/browse/HDFS-8231
>             Project: Hadoop HDFS
>          Issue Type: Improvement
>          Components: hdfs-client
>            Reporter: J.Andreina
>            Assignee: J.Andreina
>            Priority: Minor
>         Attachments: HDFS-8231.00.patch, HDFS-8231.1.patch
>
>
> StackTrace displayed at client while QuotaByStorageType exceeds.
> With reference to HDFS-2360, feel better to fix this issue.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message