[
https://issues.apache.org/jira/browse/OOZIE-1320?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Robert Kanter updated OOZIE-1320:
---------------------------------
Attachment: OOZIE-1320.patch
I copied the "maven-dependency-plugin" section from the core pom that was
writing the "mrapp-generated-classpath" file that is required for the Mini Yarn
Cluster to pick up the jars. To add the Main class, I unfortunately had to use
a "maven-antrun-plugin" task to append the path to that file because
"maven-dependency-plugin" only does jars. I applied these two changes to all
of the sharelib poms, even for the ones that don't contain any tests or Main
classes in case we add them later.
I verified that it works by applying the changes to CDH (where we have jars
available for those actions that compile against Hadoop 2) and the tests
passed. Unfortunately, they still fail in Apache trunk; though this is
expected.
> Tests for sharelib actions fail with ClassNotFoundException against Hadoop 2
> ----------------------------------------------------------------------------
>
> Key: OOZIE-1320
> URL: https://issues.apache.org/jira/browse/OOZIE-1320
> Project: Oozie
> Issue Type: Bug
> Components: tests
> Affects Versions: trunk
> Reporter: Robert Kanter
> Assignee: Robert Kanter
> Fix For: trunk
>
> Attachments: OOZIE-1320.patch
>
>
> The changes done to the sharelib actions in OOZIE-1311 have caused their
> tests to throw {{ClassNotFoundException}} on the Main class (e.g.
> {{TestSqoopActionExecutor}} throws {{ClassNotFoundException}} on
> {{SqoopMain}}) when run against Hadoop 2. This issue only affects the tests,
> not an actual deployment.
> Before OOZIE-1311, the Main classes were in the launcher jar. Now that they
> are not, in Hadoop 1, they get picked up by simply being in the classpath.
> In Hadoop 2, this doesn't work because its classpath by default only contains
> JARs. We need to modify the classpath to have the Main class to fix this.
> Note that even with a fix, many of the actions will still fail for other
> reasons because they were not compiled against Hadoop 2. (Though it should
> work if you have the proper JARs).
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira