falcon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Praveen Adlakha (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (FALCON-2227) Intitutive error handling in Falcon Client
Date Tue, 20 Dec 2016 10:27:58 GMT

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

Praveen Adlakha commented on FALCON-2227:
-----------------------------------------


While we are at it please remove the OUT.get().println statements we are printing the error
twice that way

{code}
$ bin/falcon extension -submit -extensionName abcd -jobName test -file ../test.xml
Hadoop home is set, adding libraries from '/usr/hdp/2.2.0.0-2041/hadoop/bin/hadoop classpath'
into falcon classpath
Listening for transport dt_socket at address: 5007
SLF4J: Class path contains multiple SLF4J bindings.
SLF4J: Found binding in [jar:file:/usr/local/falcon/falcon-0.11-SNAPSHOT/client/lib/slf4j-log4j12-1.7.5.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: Found binding in [jar:file:/usr/local/falcon/falcon-0.11-SNAPSHOT/client/lib/falcon-shell-0.11-SNAPSHOT.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: Found binding in [jar:file:/usr/hdp/2.2.0.0-2041/hadoop/lib/slf4j-log4j12-1.7.5.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation.
SLF4J: Actual binding is of type [org.slf4j.impl.Log4jLoggerFactory]
Error in building the extension
ERROR: Failed to prepare entities for the given extension
{code}



> Intitutive error handling in Falcon Client 
> -------------------------------------------
>
>                 Key: FALCON-2227
>                 URL: https://issues.apache.org/jira/browse/FALCON-2227
>             Project: Falcon
>          Issue Type: Sub-task
>          Components: extensions
>            Reporter: Praveen Adlakha
>
> In submitting extensions we are catching some error and not throwing it:
> {code}
> catch (Exception e) {
>                 OUT.get().println("Error in building the extension");
>                 throw new FalconCLIException("Failed to prepare entities for the given
extension");
>             }
>             if (entities == null || entities.isEmpty()) {
>                 OUT.get().println("No entities got built");
>                 throw new FalconCLIException("Failed to prepare entities for the given
extension");
>             }
> {code}
> Its pretty intuitive to know the error.Please wrap the exception.



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

Mime
View raw message