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

Anton Vinogradov commented on IGNITE-16375:
-------------------------------------------

It seems to be a broken test case when the configuration has explicit server 
mode, instead of null and we're trying to start it as a client.

That's not a huge problem, but we have weak logic here.
And client nodes may be unexpected at abstract test (where configuration is 
set) while used at implementation.

Setting client mode at configuration you setting the contract it always server 
or client. 
Otherwise, you must keep it null (default) or set it only when necessary.
{code:java}
cfg.setClientMode(false); // Bad code when client nodes starts are expected
{code}
Once again, that's not a severe issue, in contrast to startClientGrid(name) 
behavior, but ... let's keep the same contract here.

> GridAbstractTest.startClientGrid() method does not guarantee that started 
> node will be the client
> -------------------------------------------------------------------------------------------------
>
>                 Key: IGNITE-16375
>                 URL: https://issues.apache.org/jira/browse/IGNITE-16375
>             Project: Ignite
>          Issue Type: Bug
>            Reporter: Anton Vinogradov
>            Assignee: Sergey Korotkov
>            Priority: Major
>              Labels: newbie
>         Attachments: Client_node_start_failed_reproducer.patch
>
>          Time Spent: 20m
>  Remaining Estimate: 0h
>
> If {{cfg.setClientMode(false)}} was applied to the Ignite configuration, 
> {{GridAbstractTest.startClientGrid()}} will start the server node, while 
> client node is expected according to the method name and JavaDoc.
> {noformat}
> Starts new client grid with given index.
> {noformat}
> {{GridAbstractTest.startClientGrid()}} should start client node even when 
> {{cfg.setClientMode(false)}} is set or throw an exception (preferred). 
> See reproducer at  [^Client_node_start_failed_reproducer.patch] 



--
This message was sent by Atlassian Jira
(v8.20.1#820001)

Reply via email to