[ 
https://issues.apache.org/jira/browse/IGNITE-24740?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17943548#comment-17943548
 ] 

Denis Chudov commented on IGNITE-24740:
---------------------------------------

As a simple solution, I would suggest a node attribute provider passed to 
ClusterConfiguration:
{code:java}
@Override
protected void customizeConfiguration(ClusterConfiguration.Builder 
clusterConfigurationBuilder) {
    clusterConfigurationBuilder.nodeAttributesProvider(nodeIndex ->
            nodeIndex == 0
            ? "{region = EU, storage = SSD}"
            : NODE_ATTRIBUTES
    );
} {code}

> ClusterPerTestIntegrationTest does not support different startup configuration
> ------------------------------------------------------------------------------
>
>                 Key: IGNITE-24740
>                 URL: https://issues.apache.org/jira/browse/IGNITE-24740
>             Project: Ignite
>          Issue Type: Improvement
>            Reporter: Vladislav Pyatkov
>            Priority: Major
>              Labels: ignite-3
>         Attachments: 
> IGNITE-24740_ClusterPerTestIntegrationTest_does_not_support_different_startup_configuratio.patch,
>  ItClusterNodesAttributeTest.java
>
>
> h3. Motivation
> The base class (_ClusterPerTestIntegrationTest_) is frequently used for 
> integration tests where the configured class is required before scenario. 
> Currently, the only way to define the startap configuration is to use 
> getNodeBootstrapConfigTemplate, but this way defines a generic template that 
> is applied to all nodes.
> For example, it is impossible to determine node attributes for specific nodes 
> in a cluster, IP ports, e.t.c.
> Also need to check _ClusterPerClassIntegrationTest_, because likely the same 
> issue is for this base class also.
> h3. Definition of done
> Provide a way to define different startup configurations for different nodes.
> Prove that it is the easiest way to use this on the existing tests (for 
> example, test for data zone filters, where the different node attributes are 
> used).



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to