Sudhanva Huruli created SPARK-62311:
---------------------------------------

             Summary: Declarative pipelines guide does not say that the 
pipeline storage directory must be durable
                 Key: SPARK-62311
                 URL: https://issues.apache.org/jira/browse/SPARK-62311
             Project: Spark
          Issue Type: Documentation
          Components: Declarative Pipelines
    Affects Versions: 4.2.0
            Reporter: Sudhanva Huruli


The declarative-pipelines programming guide describes the storage field of the 
pipeline spec only as "a directory where checkpoints can be stored for 
streaming tables within the pipeline", and its example spec shows storage: 
file:///absolute/path/to/storage/dir without comment. It does not say what 
happens when that directory is lost. When the storage directory is on a disk 
that does not outlive the process that runs the pipeline, for example the local 
disk of a container that is replaced on restart, the streaming checkpoints are 
gone after the restart. The next spark-pipelines run still completes without an 
error, but streaming tables read their sources again from the beginning. 
Reproduce: start a Spark Connect server with a Hive catalog, run a pipeline 
with a streaming table that reads JSON files against that server, as the 
guide's spark-pipelines run section shows, stop the server, empty the storage 
directory, start the server and run again. With a Parquet table (master at 
1aa1e8fc68a) the second run skips rows that arrived since the first run; with a 
Delta table (Spark 4.2.0, Delta 4.4.1) the table holds the earlier rows twice. 
Proposed: say in the storage field description that the URI must name a 
location that survives restarts of the machine or server that runs the 
pipeline, such as cloud storage or a mounted volume, describe what a lost 
directory causes, and mark the example's file:// path as a placeholder.



--
This message was sent by Atlassian Jira
(v10.3.26#10030026)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to