Skip to content

Conversation

@tomwhite
Copy link
Member

There are test failures running with Java 8 due to http://openjdk.java.net/jeps/180 which changed retrieval order for HashMap.

Here's how I tested this:

use-java8  
mvn clean install -DskipTests -Dmaven.javadoc.skip=true 
mvn test
mvn test -P hadoop-2

I also compiled the main code with Java 7 (target=1.6 bytecode), and compiled the tests with Java 8, and ran them with Java 8. The idea here is to simulate users who want to run Parquet with JRE 8.

use-java7
mvn clean install -DskipTests -Dmaven.javadoc.skip=true 
use-java8 
find . -name test-classes | grep target/test-classes | grep -v 'parquet-scrooge' | xargs rm -rf
mvn test -DtargetJavaVersion=1.8 -Dmaven.main.skip=true -Dscala.maven.test.skip=true

A couple of notes about this:

  • The targetJavaVersion property is used since other Hadoop projects use the same name.
  • I couldn’t get parquet-scrooge to compile with target=1.8, which is why I introduced scala.maven.test.skip (and updated scala-maven-plugin to the latest version which supports the property). Compiling with target=1.8 should be fixed in another JIRA as it looks pretty involved.

Copy link
Contributor

Choose a reason for hiding this comment

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

Is this needed to add the scala.maven.test.skip property, or is this related to other fixes?

Copy link
Member Author

Choose a reason for hiding this comment

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

It's needed for skip.

@rdblue
Copy link
Contributor

rdblue commented Oct 31, 2014

I've tested this as Tom suggested and everything passes. Strangely, I didn't skip the scala tests or remove test classes from parquet-scrooge and everything still passed. I tested the build target=1.6 with tests targeting 1.6 (in java7) and 1.8 (in java8). Those work without modification. I also tested build target=1.8 with tests targeting 1.8 in java8 and all of the tests pass.

I think this PR is safe to merge.

@tomwhite tomwhite changed the title PARQUET-121 - Allow Parquet to build with Java 8 PARQUET-121: Allow Parquet to build with Java 8 Nov 3, 2014
@asfgit asfgit closed this in f1da5e9 Nov 3, 2014
rdblue pushed a commit to rdblue/parquet-mr that referenced this pull request Feb 6, 2015
There are test failures running with Java 8 due to http://openjdk.java.net/jeps/180 which changed retrieval order for HashMap.

Here's how I tested this:

```bash
use-java8
mvn clean install -DskipTests -Dmaven.javadoc.skip=true
mvn test
mvn test -P hadoop-2
```

I also compiled the main code with Java 7 (target=1.6 bytecode), and compiled the tests with Java 8, and ran them with Java 8. The idea here is to simulate users who want to run Parquet with JRE 8.
```bash
use-java7
mvn clean install -DskipTests -Dmaven.javadoc.skip=true
use-java8
find . -name test-classes | grep target/test-classes | grep -v 'parquet-scrooge' | xargs rm -rf
mvn test -DtargetJavaVersion=1.8 -Dmaven.main.skip=true -Dscala.maven.test.skip=true
```
A couple of notes about this:
* The targetJavaVersion property is used since other Hadoop projects use the same name.
* I couldn’t get parquet-scrooge to compile with target=1.8, which is why I introduced scala.maven.test.skip (and updated scala-maven-plugin to the latest version which supports the property). Compiling with target=1.8 should be fixed in another JIRA as it looks pretty involved.

Author: Tom White <tom@cloudera.com>

Closes apache#77 from tomwhite/PARQUET-121-java8 and squashes the following commits:

8717e13 [Tom White] Fix tests to run under Java 8.
35ea670 [Tom White] PARQUET-121. Allow Parquet to build with Java 8.
rdblue pushed a commit to rdblue/parquet-mr that referenced this pull request Mar 9, 2015
There are test failures running with Java 8 due to http://openjdk.java.net/jeps/180 which changed retrieval order for HashMap.

Here's how I tested this:

```bash
use-java8
mvn clean install -DskipTests -Dmaven.javadoc.skip=true
mvn test
mvn test -P hadoop-2
```

I also compiled the main code with Java 7 (target=1.6 bytecode), and compiled the tests with Java 8, and ran them with Java 8. The idea here is to simulate users who want to run Parquet with JRE 8.
```bash
use-java7
mvn clean install -DskipTests -Dmaven.javadoc.skip=true
use-java8
find . -name test-classes | grep target/test-classes | grep -v 'parquet-scrooge' | xargs rm -rf
mvn test -DtargetJavaVersion=1.8 -Dmaven.main.skip=true -Dscala.maven.test.skip=true
```
A couple of notes about this:
* The targetJavaVersion property is used since other Hadoop projects use the same name.
* I couldn’t get parquet-scrooge to compile with target=1.8, which is why I introduced scala.maven.test.skip (and updated scala-maven-plugin to the latest version which supports the property). Compiling with target=1.8 should be fixed in another JIRA as it looks pretty involved.

Author: Tom White <tom@cloudera.com>

Closes apache#77 from tomwhite/PARQUET-121-java8 and squashes the following commits:

8717e13 [Tom White] Fix tests to run under Java 8.
35ea670 [Tom White] PARQUET-121. Allow Parquet to build with Java 8.
gszadovszky pushed a commit to gszadovszky/parquet-mr that referenced this pull request Aug 22, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants