From d3de6e01812adf0ede3cc7e0103a5b8eb24cf4ae Mon Sep 17 00:00:00 2001 From: Alexey Agapov Date: Fri, 1 Nov 2024 10:43:11 +0100 Subject: [PATCH 1/2] 5.5 GA Java Client --- docs/modules/clients/pages/java.adoc | 34 ++++++++++------------------ 1 file changed, 12 insertions(+), 22 deletions(-) diff --git a/docs/modules/clients/pages/java.adoc b/docs/modules/clients/pages/java.adoc index 14af5cf1d..461be4501 100644 --- a/docs/modules/clients/pages/java.adoc +++ b/docs/modules/clients/pages/java.adoc @@ -1,4 +1,4 @@ -= Java Client +client= Java Client :page-api-reference: https://docs.hazelcast.org/docs/{page-latest-supported-java-client}/javadoc :page-toclevels: 1 :page-aliases: security:native-client-security.adoc @@ -9,7 +9,7 @@ Hazelcast provides a {java-client} which you can use to connect to a Hazelcast cluster. `hazelcast-.jar` is bundled in the Hazelcast standard package, so just add `hazelcast-.jar` to your classpath and you can start using this client as if you are using the Hazelcast API. -If you are interested in using a standalone or lightweight Java client, you can try the {java-client-new}. This client is currently available as Beta functionality but can interact with a Hazelcast cluster without being a full member. Please note that the {java-client-new} doesn't have full feature parity with the {java-client} yet and is not recommended for production environments. For more info, see xref:java#java-client-standalone-beta[]. +If you are interested in using a standalone or lightweight Java client, you can try the {java-client-new}. This client can interact with a Hazelcast cluster without being a full member. Please note that while the {java-client-new} provides full feature parity with the {java-client} in terms of functionality, there are some differences that should be considered before deciding to use it in production environments. For more info, see xref:java#java-client-standalone[]. NOTE: Where there are specific differences between {java-client} and {java-client-new}, this documentation will specify the appropriate client. Otherwise you can assume that generic references to client refer to both versions of the Java client. @@ -17,13 +17,15 @@ NOTE: Where there are specific differences between {java-client} and {java-clien Both clients enable you to use the Hazelcast API, with this page explaining any differences or technical details that affect usage. This page should be read alongside the respective Javadoc-generated API documentation available from within your IDE and the following links: +// TODO: do we still have separate JavaDocs for the two clients? + * https://docs.hazelcast.org/docs/{page-latest-supported-java-client}/javadoc[Hazelcast {java-client} API documentation] * https://docs.hazelcast.org/hazelcast-java-client/{page-latest-supported-java-client-new}/javadoc[Hazelcast {java-client-new} API documentation] == Get started * xref:java#get-started-with-java-client-and-embedded-server[] -* xref:java#get-started-with-java-client-standalone-beta[] +* xref:java#get-started-with-java-client-standalone[] === Get started with {java-client} @@ -72,7 +74,7 @@ You can find {java-client} code samples in the https://github.com/hazelcast/haze TIP: For a tutorial on getting started with Java in an embedded topology, see xref:getting-started:get-started-java.adoc[]. -=== Get started with {java-client-new} (BETA) +=== Get started with {java-client-new} To get started using the {java-client-new}, you need to add the `hazelcast-java-client` dependency to your pom.xml, as shown below. You can then start using this client as if you are using the Hazelcast API. @@ -113,17 +115,14 @@ If you are using `hazelcast-enterprise-java-client`, you need to add the `hazelc To migrate an application from the {java-client} to the {java-client-new}, you only have to update the dependency as described above. [java-client-standalone] -==== {java-client-new} (BETA) +==== {java-client-new} -The {java-client-new} is only available as a Beta release and does not have full feature parity with the {java-client}. Please note the following differences and restrictions: +The {java-client-new} provides full feature parity with the {java-client} in terms of functionality. However, please note the following differences and restrictions: // check standalone -* Hazelcast Cloud is not supported * You cannot use the {java-client} and the {java-client-new} on the same JVM * Any methods that raise the`UnsupportedOperationException` exception are not available e.g. `addLocalEntryListener(@Nonnull MapListener listener)` -* MultiMap and Set are not supported data structures -* Some client system properties are not supported (see individual notes) === Client API The Client API is your gateway to access your Hazelcast cluster, including distributed objects and data pipelines (jobs). @@ -195,9 +194,7 @@ The `addLocalEntryListener()` and `localKeySet()` methods are not supported beca === Use MultiMap -NOTE: This section is only applicable to the {java-client}. - -You can use a distributed multiMap object with the {java-client}, as follows: +You can use a distributed multiMap object with the client, as follows: [source,java] ---- @@ -236,7 +233,7 @@ The logic is the same for both member and client side, so see the specific secti * xref:data-structures:replicated-map.adoc[Replicated Map] * xref:data-structures:list.adoc[List] -* xref:data-structures:set.adoc[Set] (not supported by {java-client-new}) +* xref:data-structures:set.adoc[Set] * xref:data-structures:iatomiclong.adoc[IAtomicLong] * xref:data-structures:iatomicreference.adoc[IAtomicReference] * xref:data-structures:icountdownlatch.adoc[ICountDownLatch] @@ -507,6 +504,7 @@ security: For more information, see the appropriate API documentation for your client: +// TODO: separate JavaDocs? * https://docs.hazelcast.org/docs/{full-version}/javadoc/com/hazelcast/client/config/ClientSecurityConfig.html[{java-client-new} ClientSecurityConfig API documentation] * https://docs.hazelcast.org/hazelcast-java-client/{page-latest-supported-java-client-new}/javadoc/com/hazelcast/client/config/ClientSecurityConfig.html[{java-client} ClientSecurityConfig API documentation] @@ -1659,9 +1657,7 @@ For a programmatic example, see this xref:java#programmatic-configuration-5[code === Configure Hazelcast {hazelcast-cloud} -NOTE: This section is only applicable to the {java-client}. - -You can connect the {java-client} to a {hazelcast-cloud} Standard cluster which is hosted on link:{url-cloud-signup}[{hazelcast-cloud}]. +You can connect the client to a {hazelcast-cloud} Standard cluster which is hosted on link:{url-cloud-signup}[{hazelcast-cloud}]. For this, you need to enable {hazelcast-cloud} and specify the cluster's discovery token provided while creating the cluster; this allows the cluster to discover your clients. See the following example configurations: @@ -1986,8 +1982,6 @@ NOTE: You need to restart clients after modifying system properties. |long |Token to use when discovering the cluster via {hazelcast-cloud}. -NOTE: Not supported by {java-client-new}. - |`hazelcast.client.concurrent.window.ms` |100 |int @@ -1999,8 +1993,6 @@ Setting it too high effectively disables the optimization because once concurren it will keep that way. Setting it too low could lead to suboptimal performance because the system will try to use write-through and other optimizations even though the system is concurrent. -NOTE: Not supported by {java-client-new}. - |`hazelcast.discovery.enabled` |false |bool @@ -2166,8 +2158,6 @@ increased performance and reduced memory usage. to the same member when this property is `true`. When it is set to `false`, the client tries to connect to the members in the given order. -NOTE: Not supported by {java-client-new}. - |`hazelcast.client.connectivity.logging.delay.seconds` |10 |int From b5ccbc69a030cc670540ca04164ef18ad1220846 Mon Sep 17 00:00:00 2001 From: Alexey Agapov Date: Mon, 2 Dec 2024 15:58:49 +0100 Subject: [PATCH 2/2] List of unsupported features in Standalone Java Client uptated --- docs/modules/clients/pages/java.adoc | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/docs/modules/clients/pages/java.adoc b/docs/modules/clients/pages/java.adoc index 461be4501..f3dce26eb 100644 --- a/docs/modules/clients/pages/java.adoc +++ b/docs/modules/clients/pages/java.adoc @@ -119,10 +119,12 @@ To migrate an application from the {java-client} to the {java-client-new}, you o The {java-client-new} provides full feature parity with the {java-client} in terms of functionality. However, please note the following differences and restrictions: -// check standalone - -* You cannot use the {java-client} and the {java-client-new} on the same JVM -* Any methods that raise the`UnsupportedOperationException` exception are not available e.g. `addLocalEntryListener(@Nonnull MapListener listener)` +* Client Configuration Import is not supported. +* XA Transactions are not supported. +* For Pipeline API only built-in sources and sinks are supported. +* Cloud support is only for Hazelcast Cloud and Kubernetes. +* Session replication with Spring Boot is not supported. +* You cannot use the {java-client} and the {java-client-new} on the same JVM. === Client API The Client API is your gateway to access your Hazelcast cluster, including distributed objects and data pipelines (jobs).