GitHub user zentol opened a pull request:

    https://github.com/apache/flink/pull/4651

    [FLINK-7595] [Savepoints] Allow removing stateless operators

    ## What is the purpose of the change
    
    This PR reverts a regression where stateless operators could no longer be 
removed from a job when loading a savepoint without setting the 
`--allowNonRestoredState` flag. The check now explicitly checks whether the 
state of an operator, that could not be mapped to the new program, is empty.
    
    ## Brief change log
    
    * Modify `SavepointLoader` to check whether the unmapped state is actually 
empty
    * Modify `AbstractOperatorRestoreTestBase` to allow subclasses to set the 
`--allowNonRestoredState` flag
    * Add a modified version of `ChainLengthDecreaseTest` to prevent this issue 
from re-emerging.
    
    
    ## Verifying this change
    
    This change added tests and can be verified as follows:
    
    Run `ChainLengthStatelessDecreaseTest`. Alternatively, run the reproducer 
from the JIRA before and after the change.
    
    ## Does this pull request potentially affect one of the following parts:
    
      - Dependencies (does it add or upgrade a dependency): (no)
      - The public API, i.e., is any changed class annotated with 
`@Public(Evolving)`: (no)
      - The serializers: (no)
      - The runtime per-record code paths (performance sensitive): no)
      - Anything that affects deployment or recovery: JobManager (and its 
components), Checkpointing, Yarn/Mesos, ZooKeeper: (yes)
    
    ## Documentation
    
      - Does this pull request introduce a new feature? (no)
      - If yes, how is the feature documented? (not applicable)
    
    This should be merged to 1.3 and master. Note that for 1.3 it may be 
necessary to backport the `OperatorSubtaskState#hasState()` method.
    
    @StefanRRichter @uce 


You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/zentol/flink 7595

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/flink/pull/4651.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #4651
    
----
commit 2a44118ddc3a79f9386fe05f3b1f9e6128e92e64
Author: zentol <[email protected]>
Date:   2017-09-06T13:38:20Z

    [FLINK-7595] [Savepoints] Allow removing stateless operators

----


---

Reply via email to