Hello.

Looks like you are right about interrupted flag. I don't understand why tests 
was pass successfully in master. Your solution  also looks correct.

SegmentAware - it's info object of actual state of WAL segments like "current 
work segment", "last archived segment" etc. Actually it's nothing new here. It 
just was extracted from FileWriteAheadLogManager for centralization and future 
simplification. It should not change a old behaviour if it was happened it  
will need to be investigate.

If you already have fix for it, please will create task and add me to the 
watchers. Or I can fix it by myself.

-- 
Best regards,
Anton Kalashnikov


28.09.2018, 16:06, "Maxim Muzafarov" <[email protected]>:
> Igniters,
>
> I would like to discuss this question here and create a separate topic for
> it. Previously, I've posted some comments on the probable issue in Apache
> Ignite 2.7 topic [2]. My question is related to the IGNITE-8559 [3] (commit
> [4]). We've added a new SegmentAware class and change the
> FileWriteAheadLogManager behaviour.
>
> The FileWriteAheadLogManager now contains:
>
> `private final SegmentAware segmentAware;`.
>
> The SegmentAware have the `interrupt()` method which at manager
> de-activation sets (e.g. for SegmentArchivedStorage) `interrupted` filed to
> `true` value [5] but never revert it to `false` after activation. So, the
> SegmentArchivedStorage after de-activation always remain interrupted.
>
> I think it can lead us to unpredictable issues with multiple cluster
> activation/de-activation. I don't know why all tests in master branch
> suppose to be successful but in my local branch, they hang on exchange
> future get() method.
>
> My local solution (probably not ideal) is:
> 1) make it volatile - `private volatile SegmentAware segmentAware;`
> 2) move field init to the `start0()` method of FileWriteAheadLogManager;
>
> With these changes, everything begins to work fine but I can miss something
> because I don’t understand the whole this change well enough.
>
> Can anyone comment on this and share details IGNITE-8559 implementation?
>
> [1]
> https://github.com/apache/ignite/blob/master/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/wal/FileWriteAheadLogManager.java#L319
> [2]
> http://apache-ignite-developers.2346864.n4.nabble.com/Apache-Ignite-2-7-release-tp34076p35863.html
> [3] https://issues.apache.org/jira/browse/IGNITE-8559
> [4]
> https://github.com/apache/ignite/commit/2f72fe758d4256c4eb4610e5922ad3d174b43dc5
> [5]
> https://github.com/apache/ignite/blob/master/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/wal/aware/SegmentArchivedStorage.java#L117
> --
> --
> Maxim Muzafarov

Reply via email to