You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by "ASF GitHub Bot (JIRA)" <ji...@apache.org> on 2017/04/27 09:53:04 UTC

[jira] [Commented] (FLINK-5823) Store Checkpoint Root Metadata in StateBackend (not in HA custom store)

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

ASF GitHub Bot commented on FLINK-5823:
---------------------------------------

Github user StefanRRichter commented on a diff in the pull request:

    https://github.com/apache/flink/pull/3522#discussion_r113657592
  
    --- Diff: flink-contrib/flink-statebackend-rocksdb/src/main/java/org/apache/flink/contrib/streaming/state/RocksDBStateBackend.java ---
    @@ -222,11 +227,40 @@ public CheckpointStreamFactory createStreamFactory(JobID jobId,
     
     	@Override
     	public CheckpointStreamFactory createSavepointStreamFactory(
    -			JobID jobId,
     			String operatorIdentifier,
     			String targetLocation) throws IOException {
     
    -		return checkpointStreamBackend.createSavepointStreamFactory(jobId, operatorIdentifier, targetLocation);
    +		return checkpointStreamBackend.createSavepointStreamFactory(operatorIdentifier, targetLocation);
    +	}
    +
    +	@Override
    +	public boolean supportsExternalizedMetadata() {
    +		return checkpointStreamBackend.supportsExternalizedMetadata();
    +	}
    +
    +	@Nullable
    +	@Override
    +	public String getMetadataPersistenceLocation() {
    +		return checkpointStreamBackend.getMetadataPersistenceLocation();
    +	}
    +
    +	@Override
    +	public CheckpointMetadataStreamFactory createCheckpointMetadataStreamFactory(
    +			JobID jobID,
    +			long checkpointId) throws IOException {
    +		return checkpointStreamBackend.createCheckpointMetadataStreamFactory(jobID, checkpointId);
    +	}
    +
    +	@Override
    +	public CheckpointMetadataStreamFactory createSavepointMetadataStreamFactory(
    +			JobID jobID,
    +			@Nullable String targetLocation) throws IOException {
    +		return checkpointStreamBackend.createSavepointMetadataStreamFactory(jobID, targetLocation);
    +	}
    +
    +	@Override
    +	public StreamStateHandle resolveCheckpointLocation(String pointer) throws IOException {
    --- End diff --
    
    I would suggest to introduce an actual class for the concept of pointers to improve type safety and readability. Through subclasses, it can also be easier to reason about what kinds of pointer a backend accepts or rejects, compared to think about how a string was parsed and failed.


> Store Checkpoint Root Metadata in StateBackend (not in HA custom store)
> -----------------------------------------------------------------------
>
>                 Key: FLINK-5823
>                 URL: https://issues.apache.org/jira/browse/FLINK-5823
>             Project: Flink
>          Issue Type: Sub-task
>          Components: State Backends, Checkpointing
>            Reporter: Stephan Ewen
>            Assignee: Stephan Ewen
>             Fix For: 1.3.0
>
>




--
This message was sent by Atlassian JIRA
(v6.3.15#6346)