Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Do not review #4291

Closed
wants to merge 2 commits into from
Closed

Conversation

res-life
Copy link
Collaborator

@res-life res-life commented Dec 4, 2021

This fixes #3932

Signed-off-by: Chong Gao res_life@163.com

@res-life
Copy link
Collaborator Author

res-life commented Dec 4, 2021

build

@sameerz sameerz added the build Related to CI / CD or cleanly building label Dec 4, 2021
@res-life
Copy link
Collaborator Author

res-life commented Dec 6, 2021

build

1 similar comment
@res-life
Copy link
Collaborator Author

res-life commented Dec 6, 2021

build

<dependency>
<groupId>com.nvidia</groupId>
<artifactId>rapids-4-spark_${scala.binary.version}</artifactId>
<artifactId>rapids-4-spark-sql_${scala.binary.version}</artifactId>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The integration tests must not depend on the rapids-4-spark-sql artifact. The whole point of having tests outside of the rapids-4-spark-sql project is to test against only the dist artifact jar (i.e.: what users will use), and pulling in this jar is like pulling in the aggregator jars -- it defeats the purpose of separating the tests into a different project and does not test against the artifact that will be shipped (i.e.: is not a true integration test).

@tgravescs
Copy link
Collaborator

can we please update the description of the approach taken?

@res-life
Copy link
Collaborator Author

res-life commented Dec 7, 2021

It's a draft PR. I added some comments to the issue.

@res-life
Copy link
Collaborator Author

res-life commented Dec 8, 2021

@gerashegalov @jlowe @tgravescs
It's only a draft, but please review the solution:

Dynamically generate a jar for compile, then install it into the local maven repository, the script is in the dist module.

The Integration-tests module depends on the dynamical jar.
The Integration-tests does not depends on the sql-plugin jar.

Copy link
Member

@jlowe jlowe left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why are we moving a bunch of unit tests into the integration tests module? That is what is causing all the grief. The original plan posted in #3932 was to move tests that require direct access to internal classes into the sql-plugin project as regular unit tests and the remaining tests that run at the Spark SQL/Dataframe API layer into integration tests. Integration tests must not depend on the sql-plugin jar (or any other internal artifact).

Comment on lines +73 to +75
<artifactId>spark-sql_${scala.binary.version}</artifactId>
<version>${spark.test.version}</version>
<scope>compile</scope>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The integration tests are still depending on the spark-sql artifact and it will appear in the classpath when the tests are run.

Copy link
Collaborator Author

@res-life res-life Dec 9, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I agree with must not depend on the rapids-4-spark-sql artifact, but we must depend on spark-sql to run the Scala test cases. When running the Python test cases the spark-sql artifact will appear in the classpath because of command "$SPARK_HOME/bin/pyspark". But for the Scala test cases is a different path, the class path is specified by "mvn test".
I'll move some unit tests to the rapids-4-spark-sql module, but generally the unit tests can also run in the integration test provided the case can be compiled.

Signed-off-by: Chong Gao <res_life@163.com>
@res-life
Copy link
Collaborator Author

res-life commented Dec 9, 2021

build

Signed-off-by: Chong Gao <res_life@163.com>
@res-life
Copy link
Collaborator Author

res-life commented Dec 9, 2021

build

@res-life res-life changed the title Fix aggregator jars are in the test classpath Do not review Dec 14, 2021
@res-life
Copy link
Collaborator Author

The #3932 is invalid, so close it.

@res-life res-life closed this Dec 15, 2021
@res-life res-life deleted the fix-dependency-agg branch December 15, 2021 10:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
build Related to CI / CD or cleanly building
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[BUG] Aggregator jars are in the test classpath
4 participants