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

Mikhail Petrov commented on IGNITE-19977:
-----------------------------------------

[~vladsz83] Thank you for the contribution.

> Defragmentation can't use 1 thread.
> -----------------------------------
>
>                 Key: IGNITE-19977
>                 URL: https://issues.apache.org/jira/browse/IGNITE-19977
>             Project: Ignite
>          Issue Type: Bug
>    Affects Versions: 2.12
>            Reporter: Vladimir Steshin
>            Assignee: Vladimir Steshin
>            Priority: Minor
>             Fix For: 2.16
>
>          Time Spent: 50m
>  Remaining Estimate: 0h
>
> {code:java}
> /**
>      * Sets maximum number of partitions which can be defragmented at the 
> same time.
>      *
>      * @param defragmentationThreadPoolSize Maximum number of partitions 
> which can be defragmented at the same time.
>      *      Default is {@link 
> DataStorageConfiguration#DFLT_DEFRAGMENTATION_THREAD_POOL_SIZE}.
>      * @return {@code this} for chaining.
>      */
>     public DataStorageConfiguration setDefragmentationThreadPoolSize(int 
> defragmentationThreadPoolSize) {
>         A.ensure(defragmentationThreadPoolSize > 1, "Defragmentation thread 
> pool size must be greater or equal to 1.");
>         this.defragmentationThreadPoolSize = defragmentationThreadPoolSize;
>         return this;
>     }
> {code}
> should compare with 0:
> {code:java}
> A.ensure(defragmentationThreadPoolSize > 0, "Defragmentation thread pool size 
> must be greater or equal to 1.");
> {code}
> Defragmentation actually works with just 1 thread. Also, 1 thread seems to be 
> a workaround for https://issues.apache.org/jira/browse/IGNITE-19904 . I 
> couldn't detect the failure with one defragmentation worker. 



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

Reply via email to