[ignite] branch IGNITE-17700__realtime_cdc updated (6eda7c91b41 -> a225705fc5f)
This is an automated email from the ASF dual-hosted git repository. timoninmaxim pushed a change to branch IGNITE-17700__realtime_cdc in repository https://gitbox.apache.org/repos/asf/ignite.git from 6eda7c91b41 IGNITE-19607 Fixed flaky IgniteClusterSnapshotStreamerTest test (#10755) add 9eaae91e0a5 IGNITE-19628 Add IndexQuery to performance statistics add 6d022194ed3 Revert "IGNITE-19628 Add IndexQuery to performance statistics" add 8950aefc115 IGNITE-19620 Provided ability to configure metric exporter filter from Spring XML (#10757) add 53dba922826 IGNITE-19590 SQL Calcite: Add sensitive information hiding when IGNITE_TO_STRING_INCLUDE_SENSITIVE property set to false - Fixes #10760. add 5c2b42dd4ec IGNITE-19628 Added IndexQuery to performance statistics (#10758) add 97176a35396 IGNITE-19650 Fixed broken serialization of communication messages due to incorrect GridCacheQueryRequest class marshalling. (#10768) add 0fb4ac567d0 IGNITE-19378 Documentation: Improve docs related to lazy loading - Fixes #10671. add 46d865d63dd IGNITE-15629 Management API introduced (#10675) add 77723f0d95c IGNITE-19588 SQL Calcite: Add long-running queries warnings - Fixes #10769. add 2fbd3a3329f IGNITE-19164 Improved message about requested partitions during snapshot restore (#10638) add f6e03372967 IGNITE-19164 Removed node consistent ID from snapshot restore message (#10771) add e7c9fe7eb1e IGNITE-19715 Thin client socket#open timeout changed to ClientConfiguration#timeout property. (#10770) add fc51f0e4327 IGNITE-19652 Adapt to DirectByteBuffer ctor changes in JDK 21 (#10764) add a225705fc5f IGNITE-16619 IndexQuery should support limit (#10767) No new revisions were added by this update. Summary of changes: docs/_docs/SQL/JDBC/jdbc-client-driver.adoc| 10 - docs/_docs/SQL/JDBC/jdbc-driver.adoc | 6 - docs/_docs/SQL/ODBC/connection-string-dsn.adoc | 6 - .../_docs/perf-and-troubleshooting/sql-tuning.adoc | 17 +- .../query/calcite/CalciteQueryProcessor.java | 66 +- .../internal/processors/query/calcite/Query.java | 32 +- .../processors/query/calcite/QueryRegistry.java| 11 +- .../query/calcite/QueryRegistryImpl.java | 29 +- .../processors/query/calcite}/QueryState.java | 2 +- .../processors/query/calcite/RootQuery.java| 67 +- .../query/calcite/exec/ExchangeService.java| 5 + .../query/calcite/exec/ExchangeServiceImpl.java| 16 +- .../query/calcite/exec/ExecutionServiceImpl.java | 35 +- .../query/calcite/exec/rel/RootNode.java | 62 +- .../calcite/prepare/AbstractMultiStepPlan.java | 5 +- .../{QueryPlan.java => AbstractQueryPlan.java} | 24 +- .../processors/query/calcite/prepare/DdlPlan.java | 6 +- .../query/calcite/prepare/ExplainPlan.java | 6 +- .../query/calcite/prepare/FragmentPlan.java| 6 +- .../query/calcite/prepare/MultiStepDmlPlan.java| 5 +- .../query/calcite/prepare/MultiStepQueryPlan.java | 5 +- .../query/calcite/prepare/PrepareServiceImpl.java | 11 +- .../query/calcite/prepare/QueryPlan.java | 5 + .../calcite/util/ConvertingClosableIterator.java | 10 +- .../processors/query/calcite/CancelTest.java | 6 +- .../exec/rel/TimeCalculationExecutionTest.java | 170 + .../KillQueryCommandDdlIntegrationTest.java| 2 +- .../integration/RunningQueriesIntegrationTest.java | 25 +- .../integration/SqlDiagnosticIntegrationTest.java | 190 +- ...citeCommunicationMessageSerializationTest.java} | 28 +- .../query/calcite/planner/PlannerTest.java | 2 +- .../ignite/testsuites/ExecutionTestSuite.java | 2 + .../ignite/testsuites/IgniteCalciteTestSuite.java | 2 + .../thin/JdbcThinPartitionAwarenessSelfTest.java | 2 +- ...ThinPartitionAwarenessTransactionsSelfTest.java | 2 +- modules/control-utility/pom.xml| 7 + .../internal/commandline/AbstractCommand.java | 70 -- .../internal/commandline/ActivateCommand.java | 75 --- .../internal/commandline/ArgumentParser.java | 508 +++ .../internal/commandline/BaselineCommand.java | 316 - .../commandline/ClusterChangeTagCommand.java | 115 .../commandline/ClusterStateChangeCommand.java | 130 .../ignite/internal/commandline/Command.java | 281 .../internal/commandline/CommandArgIterator.java | 216 --- .../internal/commandline/CommandHandler.java | 400 +--- .../internal/commandline/CommandInvoker.java | 316 + .../ignite/internal/commandline/CommandList.java | 167 - .../ignite/internal/commandline/CommandLogger.java | 99 --- .../internal/commandline/CommandsProvider.java | 5 +- .../internal/commandline/CommonArgParser.java | 402 .../commandline/ConnectionAndSslParameters.java| 186 +++--- .../int
[ignite-3] branch ignite-19363 updated (4d20911b45 -> e7acecc3d5)
This is an automated email from the ASF dual-hosted git repository. sdanilov pushed a change to branch ignite-19363 in repository https://gitbox.apache.org/repos/asf/ignite-3.git from 4d20911b45 Add test and review fixes add e7acecc3d5 Add test and review fixes No new revisions were added by this update. Summary of changes: .../table/distributed/BitSetPartitionSet.java| 8 .../internal/table/distributed/PartitionSet.java | 20 ++-- 2 files changed, 14 insertions(+), 14 deletions(-)
[ignite-3] branch ignite-19363 updated (fae0b0af01 -> 4d20911b45)
This is an automated email from the ASF dual-hosted git repository. sdanilov pushed a change to branch ignite-19363 in repository https://gitbox.apache.org/repos/asf/ignite-3.git from fae0b0af01 Merge fixes add 4d20911b45 Add test and review fixes No new revisions were added by this update. Summary of changes: .../table/distributed/BitSetPartitionSet.java | 29 + .../internal/table/distributed/PartitionSet.java | 68 +++- .../internal/table/distributed/TableManager.java | 8 +- .../distributed/AbstractPartitionSetTest.java | 117 + .../table/distributed/BitSetPartitionSetTest.java} | 14 +-- 5 files changed, 222 insertions(+), 14 deletions(-) create mode 100644 modules/table/src/test/java/org/apache/ignite/internal/table/distributed/AbstractPartitionSetTest.java copy modules/{raft/src/testFixtures/java/org/apache/ignite/raft/jraft/core/MockClosure.java => table/src/test/java/org/apache/ignite/internal/table/distributed/BitSetPartitionSetTest.java} (74%)
[ignite-3] branch main updated: IGNITE-19601 Remove port range from client configuration (#2195)
This is an automated email from the ASF dual-hosted git repository. ptupitsyn pushed a commit to branch main in repository https://gitbox.apache.org/repos/asf/ignite-3.git The following commit(s) were added to refs/heads/main by this push: new 9d3f085606 IGNITE-19601 Remove port range from client configuration (#2195) 9d3f085606 is described below commit 9d3f085606dbbf3676ce6c0393048afb43a3a24b Author: Pavel Tupitsyn AuthorDate: Thu Jun 15 17:03:16 2023 +0300 IGNITE-19601 Remove port range from client configuration (#2195) Remove port range from: * Server-side `ClientHandlerModule` configuration * Java client configuration * .NET client configuration --- .../testframework/IntegrationTestBase.java | 11 +- .../org/apache/ignite/internal/NodeConfig.java | 2 + .../internal/cli/CliIntegrationTestBase.java | 3 +- .../cli/commands/ItClusterCommandTest.java | 1 + .../internal/rest/ItGeneratedRestClientTest.java | 5 +- .../resources/hardcoded-ports-config.json | 3 + .../apache/ignite/client/handler/TestServer.java | 1 - .../ignite/client/handler/ClientHandlerModule.java | 31 +++-- .../ClientConnectorConfigurationSchema.java| 5 - .../org/apache/ignite/client/IgniteClient.java | 3 +- .../ignite/client/IgniteClientConfiguration.java | 16 +-- .../{HostAndPortRange.java => HostAndPort.java}| 125 - .../ignite/internal/client/ReliableChannel.java| 15 +-- .../apache/ignite/client/AbstractClientTest.java | 14 +-- .../ignite/client/ClientAuthenticationTest.java| 5 +- .../apache/ignite/client/ClientComputeTest.java| 6 +- .../apache/ignite/client/ClientLoggingTest.java| 42 --- .../apache/ignite/client/ClientMetricsTest.java| 16 +-- .../ignite/client/ClientPutGetBenchmark.java | 2 +- .../apache/ignite/client/ConfigurationTest.java| 4 +- .../org/apache/ignite/client/ConnectionTest.java | 12 +- .../org/apache/ignite/client/DataStreamerTest.java | 2 +- .../org/apache/ignite/client/HeartbeatTest.java| 8 +- .../org/apache/ignite/client/MultiClusterTest.java | 13 +-- .../ignite/client/PartitionAwarenessTest.java | 8 +- .../org/apache/ignite/client/ReconnectTest.java| 52 +++-- .../apache/ignite/client/RequestBalancingTest.java | 6 +- .../org/apache/ignite/client/RetryPolicyTest.java | 2 +- .../org/apache/ignite/client/SchemaUpdateTest.java | 4 +- .../ignite/client/TestClientHandlerModule.java | 24 ++-- .../java/org/apache/ignite/client/TestServer.java | 27 +++-- ...tAndPortRangeTest.java => HostAndPortTest.java} | 63 ++- .../java/org/apache/ignite/lang/ErrorGroups.java | 3 + .../apache/ignite/jdbc/ItJdbcErrorsSelfTest.java | 2 +- .../ignite/internal/jdbc/ConnectionProperties.java | 6 +- .../internal/jdbc/ConnectionPropertiesImpl.java| 18 +-- .../ignite/internal/jdbc/JdbcConnection.java | 9 +- .../dotnet/Apache.Ignite.Tests/EndpointTests.cs| 27 + .../Apache.Ignite/Internal/ClientFailoverSocket.cs | 9 +- .../dotnet/Apache.Ignite/Internal/Endpoint.cs | 40 +-- .../java/org/apache/ignite/internal/Cluster.java | 11 +- .../internal/ClusterPerTestIntegrationTest.java| 9 +- .../cluster/management/ItClusterInitTest.java | 1 + .../internal/compute/ItLogicalTopologyTest.java| 3 +- .../zones/ItDistributionZonesFilterTest.java | 1 + .../raftsnapshot/ItTableRaftSnapshotsTest.java | 3 +- .../ignite/internal/rest/AbstractRestTestBase.java | 9 +- .../org/apache/ignite/internal/rest/RestNode.java | 1 + .../runner/app/AbstractSchemaChangeTest.java | 9 +- .../internal/runner/app/ItDataSchemaSyncTest.java | 6 +- .../app/ItIgniteInMemoryNodeRestartTest.java | 9 +- .../runner/app/ItIgniteNodeRestartTest.java| 10 +- .../ignite/internal/runner/app/ItIgnitionTest.java | 9 +- .../internal/runner/app/ItTablesApiTest.java | 6 +- .../runner/app/PlatformTestNodeRunner.java | 6 +- .../app/client/ItAbstractThinClientTest.java | 2 + .../sql/engine/ClusterPerClassIntegrationTest.java | 8 +- .../ignite/internal/sqllogic/ItSqlLogicTest.java | 7 +- .../org/apache/ignite/internal/ssl/ItSslTest.java | 24 ++-- 59 files changed, 308 insertions(+), 471 deletions(-) diff --git a/modules/api/src/testFixtures/java/org/apache/ignite/internal/testframework/IntegrationTestBase.java b/modules/api/src/testFixtures/java/org/apache/ignite/internal/testframework/IntegrationTestBase.java index c0f66e1ba0..860e07b637 100644 --- a/modules/api/src/testFixtures/java/org/apache/ignite/internal/testframework/IntegrationTestBase.java +++ b/modules/api/src/testFixtures/java/org/apache/ignite/internal/testframework/IntegrationTestBase.java @@ -70,6 +70,8 @@ public class IntegrationTestBase extends BaseIgniteAbstractTest { private static final int BASE_
[ignite-3] branch main updated: IGNITE-19606 Linearize metaStorageManager.deployWatches and metaStorageManager.start() (#2183)
This is an automated email from the ASF dual-hosted git repository. vpyatkov pushed a commit to branch main in repository https://gitbox.apache.org/repos/asf/ignite-3.git The following commit(s) were added to refs/heads/main by this push: new f5f2c65827 IGNITE-19606 Linearize metaStorageManager.deployWatches and metaStorageManager.start() (#2183) f5f2c65827 is described below commit f5f2c658273efaf98b5df156690f3b1afe10876d Author: Vladislav Pyatkov AuthorDate: Thu Jun 15 18:01:15 2023 +0400 IGNITE-19606 Linearize metaStorageManager.deployWatches and metaStorageManager.start() (#2183) --- .../internal/catalog/CatalogServiceSelfTest.java | 7 +- .../catalog/storage/UpdateLogImplTest.java | 5 +- .../metastore/DeploymentUnitStoreImplTest.java | 6 +- .../DistributionZonesTestUtil.java | 11 +- .../internal/metastorage/MetaStorageManager.java | 4 +- .../impl/ItMetaStorageManagerImplTest.java | 6 +- .../ItMetaStorageMultipleNodesAbstractTest.java| 28 - .../metastorage/impl/ItMetaStorageWatchTest.java | 11 +- .../metastorage/impl/MetaStorageManagerImpl.java | 11 +- .../MetaStorageDeployWatchesCorrectnessTest.java | 122 + .../MultiActorPlacementDriverTest.java | 7 +- .../PlacementDriverManagerTest.java| 6 +- .../placementdriver/PlacementDriverTest.java | 5 +- .../ItDistributedConfigurationPropertiesTest.java | 23 ++-- .../ItDistributedConfigurationStorageTest.java | 17 ++- .../storage/ItRebalanceDistributedTest.java| 19 +++- .../runner/app/ItIgniteNodeRestartTest.java| 21 +--- .../org/apache/ignite/internal/app/IgniteImpl.java | 8 +- 18 files changed, 241 insertions(+), 76 deletions(-) diff --git a/modules/catalog/src/test/java/org/apache/ignite/internal/catalog/CatalogServiceSelfTest.java b/modules/catalog/src/test/java/org/apache/ignite/internal/catalog/CatalogServiceSelfTest.java index 3c6affd572..d4f21d0222 100644 --- a/modules/catalog/src/test/java/org/apache/ignite/internal/catalog/CatalogServiceSelfTest.java +++ b/modules/catalog/src/test/java/org/apache/ignite/internal/catalog/CatalogServiceSelfTest.java @@ -100,7 +100,6 @@ import org.apache.ignite.lang.DistributionZoneNotFoundException; import org.apache.ignite.lang.IgniteInternalException; import org.apache.ignite.lang.IndexAlreadyExistsException; import org.apache.ignite.lang.IndexNotFoundException; -import org.apache.ignite.lang.NodeStoppingException; import org.apache.ignite.lang.TableAlreadyExistsException; import org.apache.ignite.lang.TableNotFoundException; import org.apache.ignite.sql.ColumnType; @@ -138,7 +137,7 @@ public class CatalogServiceSelfTest { private HybridClock clock; @BeforeEach -void setUp() throws NodeStoppingException { +void setUp() { vault = new VaultManager(new InMemoryVaultService()); metastore = StandaloneMetaStorageManager.create( @@ -152,7 +151,7 @@ public class CatalogServiceSelfTest { metastore.start(); service.start(); -metastore.deployWatches(); +assertThat("Watches were not deployed", metastore.deployWatches(), willCompleteSuccessfully()); } @AfterEach @@ -1128,7 +1127,7 @@ public class CatalogServiceSelfTest { metaStorageManager.start(); service.start(); -metaStorageManager.deployWatches(); +assertThat("Watches were not deployed", metaStorageManager.deployWatches(), willCompleteSuccessfully()); try { CreateTableParams params = CreateTableParams.builder() diff --git a/modules/catalog/src/test/java/org/apache/ignite/internal/catalog/storage/UpdateLogImplTest.java b/modules/catalog/src/test/java/org/apache/ignite/internal/catalog/storage/UpdateLogImplTest.java index e41ba4eb53..dd9bf36ee5 100644 --- a/modules/catalog/src/test/java/org/apache/ignite/internal/catalog/storage/UpdateLogImplTest.java +++ b/modules/catalog/src/test/java/org/apache/ignite/internal/catalog/storage/UpdateLogImplTest.java @@ -19,6 +19,7 @@ package org.apache.ignite.internal.catalog.storage; import static org.apache.ignite.internal.testframework.IgniteTestUtils.await; import static org.apache.ignite.internal.testframework.IgniteTestUtils.waitForCondition; +import static org.apache.ignite.internal.testframework.matchers.CompletableFutureMatcher.willCompleteSuccessfully; import static org.hamcrest.MatcherAssert.assertThat; import static org.hamcrest.Matchers.containsString; import static org.hamcrest.Matchers.equalTo; @@ -79,7 +80,7 @@ class UpdateLogImplTest { updateLog.registerUpdateHandler(update -> {/* no-op */}); updateLog.start(); -metastore.deployWatches(); +assertThat("Watches were not deployed", metastore.deployWatches(), willCompleteSuccessfully()); List expectedLog = List.of( new VersionedUpdate(1, 1L, List.of(new Te
[ignite] branch IGNITE-15629 deleted (was be7fcf2528b)
This is an automated email from the ASF dual-hosted git repository. nizhikov pushed a change to branch IGNITE-15629 in repository https://gitbox.apache.org/repos/asf/ignite.git was be7fcf2528b IGNITE-15629 Code review fixes The revisions that were on this branch are still contained in other references; therefore, this change does not discard any commits from the repository.
[ignite-3] branch main updated: IGNITE-19740 Reduce amount of noise in the log on cluster stop (#2198)
This is an automated email from the ASF dual-hosted git repository. ibessonov pushed a commit to branch main in repository https://gitbox.apache.org/repos/asf/ignite-3.git The following commit(s) were added to refs/heads/main by this push: new 0a797f0719 IGNITE-19740 Reduce amount of noise in the log on cluster stop (#2198) 0a797f0719 is described below commit 0a797f0719320a52ba438f51f580a23d15aa147c Author: Roman Puchkovskiy AuthorDate: Thu Jun 15 16:36:21 2023 +0400 IGNITE-19740 Reduce amount of noise in the log on cluster stop (#2198) --- .../apache/ignite/internal/util/ExceptionUtils.java | 4 +++- .../ignite/network/DefaultMessagingService.java | 19 ++- .../raft/client/TopologyAwareRaftGroupService.java| 5 - 3 files changed, 21 insertions(+), 7 deletions(-) diff --git a/modules/core/src/main/java/org/apache/ignite/internal/util/ExceptionUtils.java b/modules/core/src/main/java/org/apache/ignite/internal/util/ExceptionUtils.java index c0b277f54d..0b2f7e6b6c 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/util/ExceptionUtils.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/util/ExceptionUtils.java @@ -79,6 +79,7 @@ public final class ExceptionUtils { * @param throwable The exception to examine. * @return The wrapped exception, or {@code null} if not found. */ +@Nullable private static Throwable getCauseUsingWellKnownTypes(Throwable throwable) { if (throwable instanceof SQLException) { return ((SQLException) throwable).getNextException(); @@ -216,7 +217,8 @@ public final class ExceptionUtils { * @param mtdNames The method names, null treated as default set. * @return The cause of the {@code Throwable}, {@code null} if none found or null throwable input. */ -public static Throwable getCause(Throwable throwable, String[] mtdNames) { +@Nullable +public static Throwable getCause(@Nullable Throwable throwable, String[] mtdNames) { if (throwable == null) { return null; } diff --git a/modules/network/src/main/java/org/apache/ignite/network/DefaultMessagingService.java b/modules/network/src/main/java/org/apache/ignite/network/DefaultMessagingService.java index f2bfa2102a..7ca5811863 100644 --- a/modules/network/src/main/java/org/apache/ignite/network/DefaultMessagingService.java +++ b/modules/network/src/main/java/org/apache/ignite/network/DefaultMessagingService.java @@ -317,11 +317,7 @@ public class DefaultMessagingService extends AbstractMessagingService { try { onMessage(obj); } catch (Throwable e) { -LOG.error("onMessage() failed while processing {} from {}", e, obj.message(), obj.consistentId()); - -if (e instanceof Error) { -throw e; -} +logAndRethrowIfError(obj, e); } }); @@ -363,6 +359,19 @@ public class DefaultMessagingService extends AbstractMessagingService { } } +private static void logAndRethrowIfError(InNetworkObject obj, Throwable e) { +if (e instanceof UnresolvableConsistentIdException && obj.message() instanceof InvokeRequest) { +LOG.info("onMessage() failed while processing {} from {} as the sender has left the topology", +obj.message(), obj.consistentId()); +} else { +LOG.error("onMessage() failed while processing {} from {}", e, obj.message(), obj.consistentId()); +} + +if (e instanceof Error) { +throw (Error) e; +} +} + /** * Handles a response to an invocation request. * diff --git a/modules/replicator/src/main/java/org/apache/ignite/internal/raft/client/TopologyAwareRaftGroupService.java b/modules/replicator/src/main/java/org/apache/ignite/internal/raft/client/TopologyAwareRaftGroupService.java index 6831025ca1..cc5a82c84f 100644 --- a/modules/replicator/src/main/java/org/apache/ignite/internal/raft/client/TopologyAwareRaftGroupService.java +++ b/modules/replicator/src/main/java/org/apache/ignite/internal/raft/client/TopologyAwareRaftGroupService.java @@ -43,6 +43,7 @@ import org.apache.ignite.internal.raft.service.RaftGroupService; import org.apache.ignite.internal.replicator.ReplicationGroupId; import org.apache.ignite.lang.ErrorGroups.Common; import org.apache.ignite.lang.IgniteException; +import org.apache.ignite.lang.NodeStoppingException; import org.apache.ignite.network.ClusterNode; import org.apache.ignite.network.ClusterService; import org.apache.ignite.raft.jraft.RaftMessagesFactory; @@ -229,7 +230,9 @@ public class TopologyAwareRaftGroupService implements RaftGroupService { } }, executor); } else { -LOG.error("Could not send the subscribe message t
[ignite-3] branch ignite-17765-2 updated (4e6fa3073d -> 1fe54945a5)
This is an automated email from the ASF dual-hosted git repository. amashenkov pushed a change to branch ignite-17765-2 in repository https://gitbox.apache.org/repos/asf/ignite-3.git from 4e6fa3073d Expose prepare service methods to the interface. Revert unrelated changes. add 1fe54945a5 wip. No new revisions were added by this update. Summary of changes: .../sql/engine/prepare/PrepareServiceImpl.java | 76 ++ 1 file changed, 49 insertions(+), 27 deletions(-)
[ignite-3] branch ignite-19363 updated (298f19c911 -> fae0b0af01)
This is an automated email from the ASF dual-hosted git repository. sdanilov pushed a change to branch ignite-19363 in repository https://gitbox.apache.org/repos/asf/ignite-3.git from 298f19c911 Merge fixes add fae0b0af01 Merge fixes No new revisions were added by this update. Summary of changes: .../ignite/internal/rebalance/ItRebalanceTest.java| 2 ++ .../apache/ignite/internal/table/IndexWrapper.java| 19 --- 2 files changed, 18 insertions(+), 3 deletions(-)
[ignite] branch master updated: IGNITE-16619 IndexQuery should support limit (#10767)
This is an automated email from the ASF dual-hosted git repository. timoninmaxim pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/ignite.git The following commit(s) were added to refs/heads/master by this push: new a225705fc5f IGNITE-16619 IndexQuery should support limit (#10767) a225705fc5f is described below commit a225705fc5f487c2170dc584913f769f1b80f34b Author: yurinaryshkin <135707807+yurinarysh...@users.noreply.github.com> AuthorDate: Thu Jun 15 13:05:20 2023 +0300 IGNITE-16619 IndexQuery should support limit (#10767) --- .../org/apache/ignite/cache/query/IndexQuery.java | 26 +++ .../client/thin/ProtocolBitmaskFeature.java| 5 +- .../internal/client/thin/TcpClientCache.java | 7 + .../processors/cache/IgniteCacheProxyImpl.java | 3 + .../platform/client/ClientBitmaskFeature.java | 5 +- .../platform/client/ClientMessageParser.java | 2 +- .../client/cache/ClientCacheIndexQueryRequest.java | 15 +- .../ignite/cache/query/IndexQueryLimitTest.java| 233 + .../ignite/cache/query/IndexQueryTestSuite.java| 3 +- .../cache/query/ThinClientIndexQueryTest.java | 65 ++ 10 files changed, 359 insertions(+), 5 deletions(-) diff --git a/modules/core/src/main/java/org/apache/ignite/cache/query/IndexQuery.java b/modules/core/src/main/java/org/apache/ignite/cache/query/IndexQuery.java index 0e7f2a1abc9..8c61ccc1936 100644 --- a/modules/core/src/main/java/org/apache/ignite/cache/query/IndexQuery.java +++ b/modules/core/src/main/java/org/apache/ignite/cache/query/IndexQuery.java @@ -50,6 +50,9 @@ public final class IndexQuery extends Query> { /** Index name. */ private final @Nullable String idxName; +/** Limit */ +private int limit; + /** Index query criteria. */ private @Nullable List criteria; @@ -152,6 +155,29 @@ public final class IndexQuery extends Query> { return idxName; } +/** + * Gets limit to response records count. + * + * @return Limit value. + */ +public int getLimit() { +return limit; +} + +/** + * Sets limit to response records count. + * + * @param limit POsitive limit to set. + * @return {@code this} For chaining. + */ +public IndexQuery setLimit(int limit) { +A.ensure(limit > 0, "Limit must be positive."); + +this.limit = limit; + +return this; +} + /** * Sets remote cache entries filter. * diff --git a/modules/core/src/main/java/org/apache/ignite/internal/client/thin/ProtocolBitmaskFeature.java b/modules/core/src/main/java/org/apache/ignite/internal/client/thin/ProtocolBitmaskFeature.java index 3a586ec4952..751f66dbc27 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/client/thin/ProtocolBitmaskFeature.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/client/thin/ProtocolBitmaskFeature.java @@ -71,7 +71,10 @@ public enum ProtocolBitmaskFeature { ALL_AFFINITY_MAPPINGS(13), /** IndexQuery. */ -INDEX_QUERY(14); +INDEX_QUERY(14), + +/** IndexQuery limit. */ +INDEX_QUERY_LIMIT(15); /** */ private static final EnumSet ALL_FEATURES_AS_ENUM_SET = diff --git a/modules/core/src/main/java/org/apache/ignite/internal/client/thin/TcpClientCache.java b/modules/core/src/main/java/org/apache/ignite/internal/client/thin/TcpClientCache.java index 5edf586652b..130447a2309 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/client/thin/TcpClientCache.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/client/thin/TcpClientCache.java @@ -1016,6 +1016,13 @@ public class TcpClientCache implements ClientCache { w.writeBoolean(qry.isLocal()); w.writeInt(qry.getPartition() == null ? -1 : qry.getPartition()); +if (!payloadCh.clientChannel().protocolCtx().isFeatureSupported(ProtocolBitmaskFeature.INDEX_QUERY_LIMIT)) { +if (qry.getLimit() > 0) +throw new ClientFeatureNotSupportedByServerException(ProtocolBitmaskFeature.INDEX_QUERY_LIMIT); +} +else +w.writeInt(qry.getLimit()); + w.writeString(qry.getValueType()); w.writeString(qry.getIndexName()); diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/IgniteCacheProxyImpl.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/IgniteCacheProxyImpl.java index 274f476042d..8d9f23f9a00 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/IgniteCacheProxyImpl.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/IgniteCacheProxyImpl.java @@ -558,6 +558,9 @@ public class IgniteCacheProxyImpl extends AsyncSupportAdapter 0) +qry.limit(q.getLimit()); + fut = ct
[ignite-3] branch ignite-19363 updated (1307c410c8 -> 298f19c911)
This is an automated email from the ASF dual-hosted git repository. sdanilov pushed a change to branch ignite-19363 in repository https://gitbox.apache.org/repos/asf/ignite-3.git from 1307c410c8 Review fixes add 44c97c0065 IGNITE-19698 Add node name to threads in DefaultMessagingService (#2175) add 764e8a124b IGNITE-19090 Don't show progress bar in case of an error (#2169) add 995eba14b3 IGNITE-19518 Validate unit after node restart (#2151) add 19d1ff5a17 IGNITE-19304 Forbid creating index on the duplicate columns (#2174) add 17d53e99cf IGNITE-19707 Fix AssertionError in DistributionZoneManagerScaleUpTest (#2180) add 575ce79edb IGNITE-19552 Build JDBC module jar (#2127) add 79a841d952 IGNITE-19545 .NET: Add Basic Data Streamer (#2182) add 7bcea31c9e IGNITE-18692 ItRebalanceTest fix (#2157) add 006ddb06e1 IGNITE-19522 Modify deploy unit command (#2152) add f90f949b34 IGNITE-19517 Cache JobClassLoaders (#2146) add dd927f7d43 IGNITE-19483 Transform TableManager and IndexManager to internally work against Catalog event types (#2184) add 5200f0c1f3 IGNITE-19600 Removed topologyVersionedDataNodes (#2171) add dab1c8d3ad IGNITE-19204 Implement ODBC connection establishment (#2149) add 1b5fce2a6a IGNITE-19079 Enabled tests in ItIgniteNodeRestartTest: testTwoNodesRestartDirect and testTwoNodesRestartReverse (#2187) add c99ca59509 IGNITE-19709 Sql. Remove reflection call from mapping implementation (#2181) add fa76d246f5 IGNITE-19728 .NET: Fix TestAutoFlushFrequency flakiness (#2189) add 2373d9bd3f IGNITE-19587: Sql. Remove execution-related part from IgniteTable. (#2140) add 3a7cf4d0e5 IGNITE-19373 Get rid of waitForIndex from tests (#2190) add 7e1f785e21 IGNITE-19714 Fix AssertionError in DistributionZoneManagerWatchListenerTest (#2185) add 5dd07b8f95 IGNITE-18831 Sql. Fix dynamic parameters type coercion. (#2047) add f91a642951 IGNITE-19184 Added javadocs and md file to describe node attributes and distribution zone filters (#2188) add a3d3a3b5a9 Merge branch 'main' into ignite-19363 add 298f19c911 Merge fixes No new revisions were added by this update. Summary of changes: .../ignite/internal/affinity/AffinityUtils.java| 6 +- .../org/apache/ignite/compute/DeploymentUnit.java | 22 + modules/catalog/build.gradle | 2 + .../internal/catalog/CatalogServiceImpl.java | 39 +- .../internal/catalog/commands/CatalogUtils.java| 9 +- .../descriptors/CatalogDataStorageDescriptor.java | 61 +++ .../descriptors/CatalogDescriptorUtils.java| 40 ++ .../descriptors/CatalogTableDescriptor.java| 11 +- .../catalog/descriptors/CatalogZoneDescriptor.java | 49 +- .../internal/catalog/CatalogServiceSelfTest.java | 184 +--- .../cli/call/unit/DeployUndeployTestSupport.java | 7 +- .../cli/commands/unit/ItDeploymentUnitTest.java| 106 - .../internal/rest/ItGeneratedRestClientTest.java | 5 +- .../cli/call/cluster/unit/DeployUnitCall.java | 21 +- .../cli/call/cluster/unit/DeployUnitCallInput.java | 19 +- .../cli/call/cluster/unit/DeployUnitClient.java| 62 ++- .../ignite/internal/cli/commands/Options.java | 9 +- .../cluster/unit/ClusterUnitDeployCommand.java | 42 +- .../cluster/unit/ClusterUnitDeployReplCommand.java | 42 +- ...loyCommand.java => UnitDeployOptionsMixin.java} | 90 ++-- .../cli/core/call/AsyncCallExecutionPipeline.java | 18 +- .../internal/cli/core/call/ProgressBarTracker.java | 36 +- .../internal/cli/core/call/ProgressTracker.java| 5 +- .../completer/DynamicCompleterActivationPoint.java | 12 + .../unit/UnitNodesDynamicCompleterFactory.java | 48 ++ .../cli/commands/UrlOptionsNegativeTest.java | 28 +- .../cli/commands/unit/DeployCommandTest.java | 55 +++ .../cluster/management/ItClusterManagerTest.java | 18 + .../management/ClusterManagementGroupManager.java | 11 +- .../NodeAttributeConfigurationSchema.java | 7 +- .../cluster/management/raft/CmgRaftService.java| 34 ++ .../management/topology/api/LogicalNode.java | 7 +- modules/code-deployment/build.gradle | 2 + .../internal/deployunit/DefaultNodeCallback.java | 98 .../deployunit/DeployMessagingService.java | 6 +- .../internal/deployunit/DeploymentManagerImpl.java | 203 +--- .../deployunit/DeploymentUnitAccessor.java}| 40 +- .../deployunit/DeploymentUnitAccessorImpl.java | 55 +++ .../deployunit/DisposableDeploymentUnit.java | 96 .../{DeployTracker.java => DownloadTracker.java} | 24 +- .../internal/deployunit/FileDeployerService.java | 20 +- .../internal/deployunit/IgniteDeployment.java | 83 +++- .../internal/deployunit/InitialDeployMode.java}| 16 +- .../exception/DeploymentUnitNotFoundException.java | 48 +- .../DeploymentUnitUnavailableException.java|
[ignite-3] branch ignite-17765-2 updated (31f386fdf2 -> 4e6fa3073d)
This is an automated email from the ASF dual-hosted git repository. amashenkov pushed a change to branch ignite-17765-2 in repository https://gitbox.apache.org/repos/asf/ignite-3.git from 31f386fdf2 Merge branch 'main' into ignite-17765-2 add 4e6fa3073d Expose prepare service methods to the interface. Revert unrelated changes. No new revisions were added by this update. Summary of changes: .../sql/engine/prepare/PrepareService.java | 13 +++- .../sql/engine/prepare/PrepareServiceImpl.java | 91 -- .../sql/engine/exec/ExecutionServiceImplTest.java | 3 +- .../internal/sql/engine/framework/TestNode.java| 3 +- 4 files changed, 67 insertions(+), 43 deletions(-)
[ignite] branch IGNITE-19676 deleted (was c8a7290348d)
This is an automated email from the ASF dual-hosted git repository. nizhikov pushed a change to branch IGNITE-19676 in repository https://gitbox.apache.org/repos/asf/ignite.git was c8a7290348d IGNITE-19676 merge errors fix The revisions that were on this branch are still contained in other references; therefore, this change does not discard any commits from the repository.
[ignite] 01/03: IGNITE-19676 JMX Command invoker
This is an automated email from the ASF dual-hosted git repository. nizhikov pushed a commit to branch IGNITE-19676 in repository https://gitbox.apache.org/repos/asf/ignite.git commit d79ad50c3aee2374220102b2582a00788f8d1f05 Author: nizhikov AuthorDate: Tue Jun 13 12:05:38 2023 +0300 IGNITE-19676 JMX Command invoker --- .../internal/commandline/ArgumentParser.java | 133 +- .../internal/commandline/CommandHandler.java | 105 +-- .../internal/commandline/CommandInvoker.java | 189 +++- .../java/org/apache/ignite/internal/IgniteEx.java | 7 + .../org/apache/ignite/internal/IgniteKernal.java | 10 ++ .../internal/management/ActivateCommand.java | 3 +- .../internal/management/DeactivateCommand.java | 3 +- .../internal/management/SetStateCommand.java | 3 +- .../ignite/internal/management/StateCommand.java | 7 +- .../management/api/AbstractCommandInvoker.java | 115 + .../internal/management/api/CommandUtils.java | 131 ++ .../internal/management/api/LocalCommand.java | 4 +- .../api/{LocalCommand.java => Node.java} | 33 +++- .../management/api/NodeCommandInvoker.java | 124 + .../management/cache/CacheListCommand.java | 2 +- .../consistency/ConsistencyRepairCommand.java | 6 +- .../internal/management/jmx/CommandMBean.java | 191 + .../management/jmx/JmxComandRegistryInvoker.java | 117 + .../JmxCommandRegistryInvokerPluginProvider.java | 110 .../internal/management/tx/TxInfoCommand.java | 3 +- .../apache/ignite/internal/util/IgniteUtils.java | 23 +++ 21 files changed, 994 insertions(+), 325 deletions(-) diff --git a/modules/control-utility/src/main/java/org/apache/ignite/internal/commandline/ArgumentParser.java b/modules/control-utility/src/main/java/org/apache/ignite/internal/commandline/ArgumentParser.java index 3a0a58ee016..20ab97269cb 100644 --- a/modules/control-utility/src/main/java/org/apache/ignite/internal/commandline/ArgumentParser.java +++ b/modules/control-utility/src/main/java/org/apache/ignite/internal/commandline/ArgumentParser.java @@ -19,7 +19,6 @@ package org.apache.ignite.internal.commandline; import java.lang.reflect.Field; -import java.lang.reflect.InvocationTargetException; import java.util.ArrayList; import java.util.Arrays; import java.util.Collections; @@ -30,8 +29,6 @@ import java.util.Set; import java.util.function.BiConsumer; import java.util.function.BiFunction; import java.util.function.Consumer; -import java.util.function.Function; -import org.apache.ignite.IgniteException; import org.apache.ignite.IgniteLogger; import org.apache.ignite.IgniteSystemProperties; import org.apache.ignite.internal.client.GridClientConfiguration; @@ -41,13 +38,9 @@ import org.apache.ignite.internal.dto.IgniteDataTransferObject; import org.apache.ignite.internal.management.IgniteCommandRegistry; import org.apache.ignite.internal.management.api.Argument; import org.apache.ignite.internal.management.api.ArgumentGroup; -import org.apache.ignite.internal.management.api.BeforeNodeStartCommand; import org.apache.ignite.internal.management.api.CliSubcommandsWithPrefix; import org.apache.ignite.internal.management.api.Command; import org.apache.ignite.internal.management.api.CommandsRegistry; -import org.apache.ignite.internal.management.api.ComputeCommand; -import org.apache.ignite.internal.management.api.HelpCommand; -import org.apache.ignite.internal.management.api.LocalCommand; import org.apache.ignite.internal.management.api.Positional; import org.apache.ignite.internal.util.typedef.F; import org.apache.ignite.internal.util.typedef.internal.U; @@ -65,13 +58,13 @@ import static org.apache.ignite.internal.commandline.argument.parser.CLIArgument import static org.apache.ignite.internal.management.api.CommandUtils.CMD_WORDS_DELIM; import static org.apache.ignite.internal.management.api.CommandUtils.NAME_PREFIX; import static org.apache.ignite.internal.management.api.CommandUtils.PARAM_WORDS_DELIM; +import static org.apache.ignite.internal.management.api.CommandUtils.argument; import static org.apache.ignite.internal.management.api.CommandUtils.asOptional; +import static org.apache.ignite.internal.management.api.CommandUtils.executable; import static org.apache.ignite.internal.management.api.CommandUtils.fromFormattedCommandName; import static org.apache.ignite.internal.management.api.CommandUtils.isBoolean; -import static org.apache.ignite.internal.management.api.CommandUtils.parameterExample; import static org.apache.ignite.internal.management.api.CommandUtils.toFormattedCommandName; import static org.apache.ignite.internal.management.api.CommandUtils.toFormattedFieldName; -import static org.apache.ignite.internal.management.api.CommandUtils.toFormattedNames; import static org.apache.ignite.internal.manageme
[ignite] 02/03: Merge branch 'master' into IGNITE-19676
This is an automated email from the ASF dual-hosted git repository. nizhikov pushed a commit to branch IGNITE-19676 in repository https://gitbox.apache.org/repos/asf/ignite.git commit e80c60a5201f37ec8cc5d99449ad9a0a28502d98 Merge: d79ad50c3ae e7c9fe7eb1e Author: nizhikov AuthorDate: Thu Jun 15 11:33:01 2023 +0300 Merge branch 'master' into IGNITE-19676 docs/_docs/SQL/JDBC/jdbc-client-driver.adoc| 10 - docs/_docs/SQL/JDBC/jdbc-driver.adoc | 6 - docs/_docs/SQL/ODBC/connection-string-dsn.adoc | 6 - .../_docs/perf-and-troubleshooting/sql-tuning.adoc | 17 +- .../query/calcite/CalciteQueryProcessor.java | 40 +- .../internal/processors/query/calcite/Query.java | 32 +- .../processors/query/calcite/QueryRegistry.java| 11 +- .../query/calcite/QueryRegistryImpl.java | 27 +- .../processors/query/calcite/RootQuery.java| 67 ++- .../query/calcite/exec/ExchangeService.java| 5 + .../query/calcite/exec/ExchangeServiceImpl.java| 16 +- .../query/calcite/exec/ExecutionServiceImpl.java | 33 +- .../query/calcite/exec/rel/RootNode.java | 62 ++- .../calcite/util/ConvertingClosableIterator.java | 10 +- .../processors/query/calcite/CancelTest.java | 6 +- .../exec/rel/TimeCalculationExecutionTest.java | 170 ++ .../KillQueryCommandDdlIntegrationTest.java| 2 +- .../integration/RunningQueriesIntegrationTest.java | 25 +- .../integration/SqlDiagnosticIntegrationTest.java | 106 +++- ...citeCommunicationMessageSerializationTest.java} | 28 +- .../ignite/testsuites/ExecutionTestSuite.java | 2 + .../ignite/testsuites/IgniteCalciteTestSuite.java | 2 + .../thin/JdbcThinPartitionAwarenessSelfTest.java | 2 +- ...ThinPartitionAwarenessTransactionsSelfTest.java | 2 +- .../internal/commandline/ArgumentParser.java | 169 +- .../ignite/internal/binary/BinaryObjectImpl.java | 5 +- .../GridNioClientConnectionMultiplexer.java| 7 +- .../internal/management/api/HelpCommand.java | 19 + .../internal/management/api/LocalCommand.java | 16 +- .../internal/managers/IgniteMBeansManager.java | 8 +- .../processors/bulkload/BulkLoadProcessor.java | 4 +- .../snapshot/SnapshotRestoreProcess.java | 27 +- .../cache/query/GridCacheQueryRequest.java | 6 +- .../processors/query/GridQueryIndexing.java| 10 +- .../processors/query/GridQueryProcessor.java | 4 +- .../internal/processors/query/NoOpQueryEngine.java | 12 - .../internal/processors/query/QueryEngine.java | 8 - .../query/{ => running}/GridRunningQueryInfo.java | 13 +- .../query/running/HeavyQueriesTracker.java}| 108 +++- .../query/{ => running}/QueryHistory.java | 2 +- .../query/{ => running}/QueryHistoryKey.java | 2 +- .../{ => running}/QueryHistoryMetricsValue.java| 2 +- .../query/{ => running}/QueryHistoryTracker.java | 2 +- .../query/{ => running}/QueryRunningFuture.java| 2 +- .../query/{ => running}/RunningQueryManager.java | 28 +- .../processors/query/running}/SqlQueryMXBean.java | 2 +- .../query/running}/SqlQueryMXBeanImpl.java | 23 +- .../spi/systemview/view/SqlQueryHistoryView.java | 2 +- .../ignite/spi/systemview/view/SqlQueryView.java | 2 +- .../main/resources/META-INF/classnames.properties | 3 +- ...tractCommunicationMessageSerializationTest.java | 601 + ...iteIoCommunicationMessageSerializationTest.java | 91 .../processors/query/DummyQueryIndexing.java | 7 +- .../ignite/testsuites/IgniteCacheTestSuite10.java | 2 + modules/indexing/pom.xml | 7 + .../query/h2/H2QueryFetchSizeInterceptor.java | 92 .../internal/processors/query/h2/H2QueryInfo.java | 22 +- .../processors/query/h2/H2ResultSetIterator.java | 13 +- .../processors/query/h2/IgniteH2Indexing.java | 43 +- .../processors/query/h2/RegisteredQueryCursor.java | 5 +- .../query/h2/twostep/MapQueryResult.java | 10 +- .../query/h2/twostep/msg/GridH2QueryRequest.java | 3 +- .../metric/SqlStatisticsUserQueriesFastTest.java | 2 +- .../metric/SqlStatisticsUserQueriesLongTest.java | 2 +- .../internal/metric/UserQueriesTestBase.java | 4 +- .../cache/CacheSqlQueryValueCopySelfTest.java | 2 +- .../IgniteSqlSkipReducerOnUpdateDmlSelfTest.java | 1 + .../query/KillQueryErrorOnCancelTest.java | 1 + .../query/KillQueryOnClientDisconnectTest.java | 1 + .../internal/processors/query/KillQueryTest.java | 1 + .../processors/query/LongRunningQueryTest.java | 22 +- .../processors/query/RunningQueriesTest.java | 1 + .../processors/query/SqlQueryHistorySelfTest.java | 1 + .../systemview/SystemViewSecurityTest.java | 2 +- .../H2CommunicationMessageSerializationTest.java} | 24 +- .../IgniteBinaryCacheQueryTestSuite3.j
[ignite] branch IGNITE-19676 created (now c8a7290348d)
This is an automated email from the ASF dual-hosted git repository. nizhikov pushed a change to branch IGNITE-19676 in repository https://gitbox.apache.org/repos/asf/ignite.git at c8a7290348d IGNITE-19676 merge errors fix This branch includes the following new commits: new d79ad50c3ae IGNITE-19676 JMX Command invoker new e80c60a5201 Merge branch 'master' into IGNITE-19676 new c8a7290348d IGNITE-19676 merge errors fix The 3 revisions listed above as "new" are entirely new to this repository and will be described in separate emails. The revisions listed as "add" were already present in the repository and have only been added to this reference.
[ignite] 03/03: IGNITE-19676 merge errors fix
This is an automated email from the ASF dual-hosted git repository. nizhikov pushed a commit to branch IGNITE-19676 in repository https://gitbox.apache.org/repos/asf/ignite.git commit c8a7290348dd227903c418a2c4de8dbf525d4d87 Author: nizhikov AuthorDate: Thu Jun 15 12:09:29 2023 +0300 IGNITE-19676 merge errors fix --- .../processors/query/calcite/QueryState.java} | 32 +++--- .../internal/commandline/ArgumentParser.java | 119 - .../internal/management/api/HelpCommand.java | 19 .../internal/management/api/LocalCommand.java | 15 +-- .../query/running/TrackableQuery.java} | 20 ++-- .../junits/multijvm/IgniteProcessProxy.java| 6 ++ 6 files changed, 43 insertions(+), 168 deletions(-) diff --git a/modules/core/src/main/java/org/apache/ignite/internal/management/api/LocalCommand.java b/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/QueryState.java similarity index 60% copy from modules/core/src/main/java/org/apache/ignite/internal/management/api/LocalCommand.java copy to modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/QueryState.java index 2f60d073ed8..95a04564559 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/management/api/LocalCommand.java +++ b/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/QueryState.java @@ -15,19 +15,25 @@ * limitations under the License. */ -package org.apache.ignite.internal.management.api; +package org.apache.ignite.internal.processors.query.calcite; -import java.util.function.Consumer; -import org.apache.ignite.internal.client.GridClient; -import org.apache.ignite.internal.client.GridClientException; -import org.apache.ignite.internal.dto.IgniteDataTransferObject; +/** */ +public enum QueryState { +/** */ +INITED, -/** - * Marker interface only for backward compatibility with {@code ./control.sh}. - */ -public interface HelpCommand extends Command { -/** {@inheritDoc} */ -@Override public default Class argClass() { -return NoArg.class; -} +/** */ +PLANNING, + +/** */ +MAPPING, + +/** */ +EXECUTING, + +/** */ +CLOSING, + +/** */ +CLOSED } diff --git a/modules/control-utility/src/main/java/org/apache/ignite/internal/commandline/ArgumentParser.java b/modules/control-utility/src/main/java/org/apache/ignite/internal/commandline/ArgumentParser.java index 16f9e8ec26a..5abe7ce6f75 100644 --- a/modules/control-utility/src/main/java/org/apache/ignite/internal/commandline/ArgumentParser.java +++ b/modules/control-utility/src/main/java/org/apache/ignite/internal/commandline/ArgumentParser.java @@ -42,9 +42,7 @@ import org.apache.ignite.internal.management.api.CliSubcommandsWithPrefix; import org.apache.ignite.internal.management.api.Command; import org.apache.ignite.internal.management.api.CommandsRegistry; import org.apache.ignite.internal.management.api.Positional; -import org.apache.ignite.internal.util.typedef.F; import org.apache.ignite.internal.util.typedef.internal.U; -import org.apache.ignite.lang.IgniteBiTuple; import org.apache.ignite.lang.IgniteExperimental; import org.apache.ignite.ssl.SslContextFactory; @@ -380,121 +378,4 @@ public class ArgumentParser { return new CLIArgumentParser(positionalArgs, namedArgs); } - -/** - * Fill and vaildate command argument. - * - * @param argCls Argument class. - * @param positionalParamProvider Provider of positional parameters. - * @param paramProvider Provider of named parameters. - * @return Argument filled with parameters. - * @param Argument type. - */ -private static A argument( -Class argCls, -BiFunction positionalParamProvider, -Function paramProvider -) { -try { -ArgumentState arg = new ArgumentState<>(argCls); - -visitCommandParams( -argCls, -fld -> arg.accept(fld, positionalParamProvider.apply(fld, arg.nextIdx())), -fld -> arg.accept(fld, paramProvider.apply(fld)), -(argGrp, flds) -> flds.forEach(fld -> { -if (fld.isAnnotationPresent(Positional.class)) -arg.accept(fld, positionalParamProvider.apply(fld, arg.nextIdx())); -else -arg.accept(fld, paramProvider.apply(fld)); -}) -); - -if (arg.argGrp != null && (!arg.grpOptional() && !arg.grpFldExists)) -throw new IllegalArgumentException("One of " + toFormattedNames(argCls, arg.grpdFlds) + " required"); - -return arg.res; -} -catch (InstantiationException | IllegalAccessException e) { -throw new IgniteException(e); -} -} - -/** */ -private static class ArgumentState implements BiConsumer { -/** */
[ignite-3] branch ignite-19363 updated (1fb06a2b6c -> 1307c410c8)
This is an automated email from the ASF dual-hosted git repository. sdanilov pushed a change to branch ignite-19363 in repository https://gitbox.apache.org/repos/asf/ignite-3.git from 1fb06a2b6c IGNITE-19363 Initial fix add 1307c410c8 Review fixes No new revisions were added by this update. Summary of changes: .../apache/ignite/internal/index/IndexManager.java | 7 +- .../ignite/internal/index/IndexManagerTest.java| 10 +- .../apache/ignite/internal/table/IndexWrapper.java | 114 + .../apache/ignite/internal/table/TableImpl.java| 90 ++-- .../internal/table/distributed/PartitionSet.java | 25 + .../internal/table/distributed/TableManager.java | 42 .../table/distributed/TableManagerTest.java| 5 +- 7 files changed, 182 insertions(+), 111 deletions(-) create mode 100644 modules/table/src/main/java/org/apache/ignite/internal/table/IndexWrapper.java
[ignite] branch master updated: IGNITE-19652 Adapt to DirectByteBuffer ctor changes in JDK 21 (#10764)
This is an automated email from the ASF dual-hosted git repository. ptupitsyn pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/ignite.git The following commit(s) were added to refs/heads/master by this push: new fc51f0e4327 IGNITE-19652 Adapt to DirectByteBuffer ctor changes in JDK 21 (#10764) fc51f0e4327 is described below commit fc51f0e43275953ab6a77c7f4d10ba32d1a640b6 Author: Mateusz "Serafin" Gajewski AuthorDate: Thu Jun 15 10:43:56 2023 +0200 IGNITE-19652 Adapt to DirectByteBuffer ctor changes in JDK 21 (#10764) Signature has changed in https://github.com/openjdk/jdk/commit/a56598f5a534cc9223367e7faa8433ea38661db9 --- .../main/java/org/apache/ignite/internal/util/GridUnsafe.java | 10 +++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/modules/core/src/main/java/org/apache/ignite/internal/util/GridUnsafe.java b/modules/core/src/main/java/org/apache/ignite/internal/util/GridUnsafe.java index 9f4608a1f01..ef215493cac 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/util/GridUnsafe.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/util/GridUnsafe.java @@ -114,6 +114,9 @@ public abstract class GridUnsafe { /** {@link java.nio.Buffer#address} field offset. */ private static final long DIRECT_BUF_ADDR_OFF = bufferAddressOffset(); +/** Whether to use newDirectByteBuffer(long, long) constructor */ +private static final boolean IS_DIRECT_BUF_LONG_CAP = majorJavaVersion(jdkVersion()) >= 21; + /** Cleaner code for direct {@code java.nio.ByteBuffer}. */ private static final DirectBufferCleaner DIRECT_BUF_CLEANER = majorJavaVersion(jdkVersion()) < 9 @@ -1641,7 +1644,8 @@ public abstract class GridUnsafe { try { Class cls = nioAccessObj.getClass(); -Method mtd = cls.getMethod("newDirectByteBuffer", long.class, int.class, Object.class); +Method mtd = IS_DIRECT_BUF_LONG_CAP ? cls.getMethod("newDirectByteBuffer", long.class, long.class, Object.class) : +cls.getMethod("newDirectByteBuffer", long.class, int.class, Object.class); mtd.setAccessible(true); @@ -1660,7 +1664,6 @@ public abstract class GridUnsafe { return javaVer < 9 ? "sun" : "jdk.internal"; } - /** * Creates and tests contructor for Direct ByteBuffer. Test is wrapping one-byte unsafe memory into a buffer. * @@ -1696,7 +1699,8 @@ public abstract class GridUnsafe { try { ByteBuffer buf = ByteBuffer.allocateDirect(1).order(NATIVE_BYTE_ORDER); -Constructor ctor = buf.getClass().getDeclaredConstructor(long.class, int.class); +Constructor ctor = IS_DIRECT_BUF_LONG_CAP ? buf.getClass().getDeclaredConstructor(long.class, long.class) : +buf.getClass().getDeclaredConstructor(long.class, int.class); ctor.setAccessible(true);
[ignite-3] branch main updated: IGNITE-19184 Added javadocs and md file to describe node attributes and distribution zone filters (#2188)
This is an automated email from the ASF dual-hosted git repository. sk0x50 pushed a commit to branch main in repository https://gitbox.apache.org/repos/asf/ignite-3.git The following commit(s) were added to refs/heads/main by this push: new f91a642951 IGNITE-19184 Added javadocs and md file to describe node attributes and distribution zone filters (#2188) f91a642951 is described below commit f91a6429513629d2906e88a14b9bb35e2dc64172 Author: Mirza Aliev AuthorDate: Thu Jun 15 12:30:13 2023 +0400 IGNITE-19184 Added javadocs and md file to describe node attributes and distribution zone filters (#2188) --- .../NodeAttributeConfigurationSchema.java | 7 ++- .../management/topology/api/LogicalNode.java | 7 ++- .../distributionzones/DistributionZoneManager.java | 2 + .../DistributionZoneConfigurationSchema.java | 2 + modules/distribution-zones/tech-notes/filters.md | 70 ++ 5 files changed, 85 insertions(+), 3 deletions(-) diff --git a/modules/cluster-management/src/main/java/org/apache/ignite/internal/cluster/management/configuration/NodeAttributeConfigurationSchema.java b/modules/cluster-management/src/main/java/org/apache/ignite/internal/cluster/management/configuration/NodeAttributeConfigurationSchema.java index 55b4479550..cb52ebf3a2 100644 --- a/modules/cluster-management/src/main/java/org/apache/ignite/internal/cluster/management/configuration/NodeAttributeConfigurationSchema.java +++ b/modules/cluster-management/src/main/java/org/apache/ignite/internal/cluster/management/configuration/NodeAttributeConfigurationSchema.java @@ -22,8 +22,11 @@ import org.apache.ignite.configuration.annotation.InjectedName; import org.apache.ignite.configuration.annotation.Value; /** - * Node's attribute configuration schema. - * TODO: add proper javadocs when filtering feature will be closer to the end https://issues.apache.org/jira/browse/IGNITE-19184 + * Node's attribute configuration schema. User can specify any number of pairs (key, attribute) for a node through the local configuration + * of a node, and also can specify a filter through the SQL syntax of distribution zones. Any time data nodes will be recalculated, + * corresponding filter will be applied to set of nodes with pre-defined attributes. + * + * @see https://github.com/apache/ignite-3/blob/main/modules/distribution-zones/tech-notes/filters.md";>Filter documentation */ @Config public class NodeAttributeConfigurationSchema { diff --git a/modules/cluster-management/src/main/java/org/apache/ignite/internal/cluster/management/topology/api/LogicalNode.java b/modules/cluster-management/src/main/java/org/apache/ignite/internal/cluster/management/topology/api/LogicalNode.java index ce808d4a50..9ff7789dcd 100644 --- a/modules/cluster-management/src/main/java/org/apache/ignite/internal/cluster/management/topology/api/LogicalNode.java +++ b/modules/cluster-management/src/main/java/org/apache/ignite/internal/cluster/management/topology/api/LogicalNode.java @@ -28,7 +28,12 @@ import org.apache.ignite.network.NetworkAddress; * Representation of a logical node in a cluster. */ public class LogicalNode extends ClusterNode { -/** Node's attributes. */ +/** + * Node's attributes. + * + * @see https://github.com/apache/ignite-3/blob/main/modules/distribution-zones/tech-notes/filters.md";>Filter + * documentation + */ @IgniteToStringInclude private final Map nodeAttributes; diff --git a/modules/distribution-zones/src/main/java/org/apache/ignite/internal/distributionzones/DistributionZoneManager.java b/modules/distribution-zones/src/main/java/org/apache/ignite/internal/distributionzones/DistributionZoneManager.java index 92a98f7ead..9666848b01 100644 --- a/modules/distribution-zones/src/main/java/org/apache/ignite/internal/distributionzones/DistributionZoneManager.java +++ b/modules/distribution-zones/src/main/java/org/apache/ignite/internal/distributionzones/DistributionZoneManager.java @@ -230,6 +230,8 @@ public class DistributionZoneManager implements IgniteComponent { * Local mapping of {@code nodeId} -> node's attributes, where {@code nodeId} is a node id, that changes between restarts. * This map is updated every time we receive a topology event in a {@code topologyWatchListener}. * TODO: https://issues.apache.org/jira/browse/IGNITE-19491 properly clean up this map + * + * @see https://github.com/apache/ignite-3/blob/main/modules/distribution-zones/tech-notes/filters.md";>Filter documentation */ private final Map> nodesAttributes; diff --git a/modules/distribution-zones/src/main/java/org/apache/ignite/internal/distributionzones/configuration/DistributionZoneConfigurationSchema.java b/modules/distribution-zones/src/main/java/org/apache/ignite/internal/distributionzones/configuration/DistributionZoneConfigurationSchema.java index 4db3f9ea82..e1dd497b8e 100644 --- a/modules/distribu