[
https://issues.apache.org/jira/browse/SQOOP-2652?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14990020#comment-14990020
]
Jarek Jarcec Cecho commented on SQOOP-2652:
-------------------------------------------
I've run the precommit hook on my local development box and I now understand
what is happening:
# testng runs all various methods that are annotated with {{@Before*}}
({{@BeforeTest}}, {{@BeforeSuite}}, ...). The whole order of execution is not
important - what is relevant here is that the {{@Before}} method on Kafka and
Hive test case is called *after* {{@Before}} method in my S3 test case.
# My newly added S3 test case in this stage calls {{Assume}} statement that
returns {{false}}.
# Since {{Assume}} returned {{false}}, testng stops test execution here - all
remaining {{@Before}} methods are *not* called and all test methods are skipped.
# Testng however calls all various methods that are annotated with {{@After}}
# The {{@After}} method implementation for Kafka and Hive always assumes that
the corresponding {{@Before}} method always run and hence throws NPE as some of
the variables that it expects haven't been initialized.
I do see two issues that needs to be fixed:
# Our tear down methods ({{@After}}) should be smart enough to not throw
{{NullPointerException}} in case that the initialization didn't happen. This is
covered by SQOOP-2659.
# The S3 test case needs to be changed to not stop test execution for all
integration tests if the S3 parameters are not present.
> Sqoop2: Add test case for S3 incremental import to HDFS
> -------------------------------------------------------
>
> Key: SQOOP-2652
> URL: https://issues.apache.org/jira/browse/SQOOP-2652
> Project: Sqoop
> Issue Type: Bug
> Affects Versions: 1.99.6
> Reporter: Jarek Jarcec Cecho
> Assignee: Jarek Jarcec Cecho
> Fix For: 1.99.7
>
> Attachments: SQOOP-2652.patch, SQOOP-2652.patch
>
>
> I've added support for S3 import back in SQOOP-2524. I would like to extend
> that work to add explicit test case for incremental import.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)