You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is the core Java component of the DataSketches library. It contains all of the sketching algorithms and can be accessed directly from user applications.
27
27
28
-
This component is also a dependency of other components of the library that create adaptors for target systems, such as the [Apache Pig adaptor](https://github.com/apache/datasketches-pig) and the [Apache Hive adaptor](https://github.com/apache/datasketches-hive).
28
+
This component is also a dependency of other components of the library that create adaptors for target systems, such as the [Apache Pig adaptor](https://github.com/apache/datasketches-pig), the [Apache Hive adaptor](https://github.com/apache/datasketches-hive), and others.
29
29
30
30
Note that we have a parallel core component for C++ and Python implementations of the same sketch algorithms,
[datasketches-cpp](https://github.com/apache/datasketches-cpp) and [datasketches-python](https://github.com/apache/datasketches-python)
32
32
33
33
Please visit the main [DataSketches website](https://datasketches.apache.org) for more information.
34
34
@@ -39,30 +39,29 @@ If you are interested in making contributions to this site please see our [Commu
39
39
## Maven Build Instructions
40
40
__NOTE:__ This component accesses resource files for testing. As a result, the directory elements of the full absolute path of the target installation directory must qualify as Java identifiers. In other words, the directory elements must not have any space characters (or non-Java identifier characters) in any of the path elements. This is required by the Oracle Java Specification in order to ensure location-independent access to resources: [See Oracle Location-Independent Access to Resources](https://docs.oracle.com/javase/8/docs/technotes/guides/lang/resources.html)
41
41
42
-
### A JDK8 with Hotspot or JDK11 with Hotspot is required to compile
43
-
This component depends on the [datasketches-memory](https://github.com/apache/datasketches-memory) component,
44
-
and, as a result, must be compiled with one of the above JDKs.
45
-
If your application only relies on the APIs of this component no special JVM arguments are required.
46
-
However, if your application also directly relies on the APIs of the *datasketches-memory* component,
47
-
you may need additional JVM arguments.
48
-
Please refer to the [datasketches-memory README](https://github.com/apache/datasketches-memory/blob/master/README.md) for details.
42
+
### JDK17 is required to compile
43
+
This component depends on the [datasketches-memory-4.1.X](https://github.com/apache/datasketches-memory/tree/4.1.X) component,
44
+
and, as a result, must be compiled with JDK17 and this dependency:
49
45
50
-
If your application uses Maven, you can also use the *pom.xml* of this component as an example of how to automatically
51
-
configure the JVM arguments for compilation and testing based on the version of the JDK.
46
+
```
47
+
<dependency>
48
+
<groupId>org.apache.datasketches</groupId>
49
+
<artifactId>datasketches-memory</artifactId>
50
+
<version>4.1.0</version>
51
+
</dependency>
52
+
```
53
+
54
+
If your application only relies on the APIs of datasketches-java no special JVM arguments are required.
55
+
However, if your application also directly relies on the APIs of the *datasketches-memory* component,
56
+
you may need the additional JVM argument **--enable-preview**.
52
57
53
58
### Recommended Build Tool
54
59
This DataSketches component is structured as a Maven project and Maven is the recommended Build Tool.
55
60
56
-
There are two types of tests: normal unit tests and tests run by the strict profile.
57
-
58
61
To run normal unit tests:
59
62
60
63
$ mvn clean test
61
64
62
-
To run the strict profile tests (only supported in Java 8):
63
-
64
-
$ mvn clean test -P strict
65
-
66
65
To install jars built from the downloaded source:
67
66
68
67
$ mvn clean install -DskipTests=true
@@ -80,74 +79,11 @@ This will create the following jars:
Building and running tests using JDK 8 should not be a problem.
91
-
92
-
However, with JDK 9+, and Eclipse versions up to and including 4.22.0 (2021-12), Eclipse fails to translate the required JPMS JVM arguments specified in the POM compiler or surefire plugins into the *.classpath* file, causing illegal reflection access errors
In Eclipse, open the project *Properties / Java Build Path / Module Dependencies ...*
125
-
126
-
* Select *java.base*
127
-
* Select *Configured details*
128
-
* Select *Expose Package...*
129
-
* Enter *Package* = java.nio
130
-
* Enter *Target module* = ALL-UNNAMED
131
-
* Select button: *opens*
132
-
* Hit *OK*
133
-
* Select *Expose Package...*
134
-
* Enter *Package* = jdk.internal.misc
135
-
* Enter *Target module* = ALL-UNNAMED
136
-
* Select button: *exports*
137
-
* Hit *OK*
138
-
* Select *Expose Package...*
139
-
* Enter *Package* = jdk.internal.ref
140
-
* Enter *Target module* = ALL-UNNAMED
141
-
* Select button: *exports*
142
-
* Hit *OK*
143
-
* Select *Expose Package...*
144
-
* Enter *Package* = sun.nio.ch
145
-
* Enter *Target module* = ALL-UNNAMED
146
-
* Select button: *opens*
147
-
* Hit *OK*
148
-
149
-
**NOTE:** If you execute *Maven/Update Project...* from Eclipse with the option *Update project configuration from pom.xml* checked, all of the above will be erased, and you will have to redo it.
0 commit comments