Skip to content
Permalink
Browse files
Minor changes to Readme files.
  • Loading branch information
leerho committed Jul 25, 2021
1 parent c4b6a66 commit 771429eb10c4025de2dc3e71fb5069f0ef002389
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 12 deletions.
@@ -119,7 +119,7 @@ This will create the following Jars:
### Toolchains

This project makes use of Maven toolchains to ensure that the correct Java compiler version is used when compiling source files.
Ensure that your local environment has been configured according to the [toolchain documentation](docs/maven-toolchains.md).
Ensure that your local environment has been configured according to the [Maven toolchain configuration](docs/maven-toolchains.md).

### Dependencies

@@ -2,27 +2,27 @@

From the [maven-toolchain-plugin documentation](https://maven.apache.org/plugins/maven-toolchains-plugin/usage.html):

> A Toolchain is an object that Maven plugins can use to retrieve preconfigured tools (including location and
other information).
> A Toolchain is an object that Maven plugins can use to retrieve preconfigured tools (including location and other information).
With the jdk toolchain, for example, instead of being stuck with the JDK used to run Maven, all plugins
can use the same other JDK instance without hardcoding absolute paths into the pom.xml and without configuring
every plugin that require a path to JDK tools.
can use the same or other JDK instances without hardcoding absolute paths into the pom.xml and without configuring
every plugin that require a path to JDK tools.
>
##### Motivation
### Motivation

Toolchains are used in different maven modules to ensure that the correct Java compiler version is used when compiling source files. This is because `datasketches-memory` uses some JDK version-specific APIs, which require different JDKs to compile correctly.

##### Toolchain template
### Toolchain template

Your local environment requires toolchain entries for Java 8, 9 and 11 to build this project. These can be found in a reference `toolchains.xml` template in the `tools` directory.
Any maven commands used during development can be supplemented with: `--toolchains tools/toolchains.xml`, without permanently modifying a local `~/.m2/toolchains.xml` file (recommended).

Alternatively, the toolchain template can be copied to your local maven `toolchains.xml` e.g. `~/.m2/toolchains.xml`. If there is already a locally configured `toolchains.xml` file, the requisite entries should be merged into the existing file if they do not already exist.

##### Environment variables
### Environment variables

The `dataSketches-memory` component is pure Java and requires the following JDKs to compile:

- JDK8/Hotspot
- JDK9/Hotspot
- JDK11/Hotspot
@@ -41,7 +41,13 @@ For example, if you are using [SDKMAN!](https://sdkman.io/), your environment mi
- JAVA9_HOME: `/Users/me/.sdkman/candidates/java/9.0.4-open`
- JAVA11_HOME: `/Users/me/.sdkman/candidates/java/11.0.10.hs-adpt`

##### Eclipse configuration
#### For MacOS or Linux variants
Users can discover what JDKs have been loaded into their enviornment by using the following command:

- /usr/libexec/java_home -V


### Eclipse configuration

If you are an Eclipse user, you may need further configuration for your IDE to use the appropriate JDK for each module - see the [eclipse IDE setup](eclipse.md).

@@ -4,7 +4,7 @@ This project is a multi-module Maven project. A multi-module Maven project consi
(the `datasketches-memory-root` project), together with a set of submodules. The aggregator's configuration is inherited
by each submodule, thus reducing duplication.

`datasketches-memory` makes use of some features of the Java platform, namely `Unsafe`, which have evolved in
`datasketches-memory` makes use of some features of the Java platform, for example, `Unsafe`, which have evolved in
Java versions 9 and above. Therefore, a multi-module project allows us to add support for later versions of
Java by using independent Maven modules to target platform-specific APIs. For example, to deallocate references
a `sun.misc.Cleaner` will be used in Java8, but the `jdk.internal.ref.Cleaner` is used in Java 9.
@@ -15,7 +15,6 @@ This project has been divided into the following submodules:
* datasketches-memory-java8-tests
* datasketches-memory-java9 (Java9 equivalent of some platform specific classes in datasketches-memory-java8)
* datasketches-memory-java11 (Java11 equivalent of some platform specific classes in datasketches-memory-java8)
* datasketches-memory-java11-tests
* datasketches-memory (JAR assembly, does not contain source files)
* datasketches-memory-resources (Runs test suite against assembled JAR)

@@ -1,4 +1,4 @@
# Multi-release JAR
# Multi-Release JAR

The `datasketches-memory` module assembles a JAR for release that consists of multiple Java-release-specific versions
of class files to coexist in a single archive (the MR-JAR).

0 comments on commit 771429e

Please sign in to comment.