Skip to content

DeltaTimeTravelSpec

Time Travel Patterns

DeltaTimeTravelSpec defines regular expressions for timestamp- and version-based time travel identifiers:

  • Version URI: (path)@[vV](some numbers)
  • Timestamp URI: (path)@(yyyyMMddHHmmssSSS)

Creating Instance

DeltaTimeTravelSpec takes the following to be created:

  • Optional Timestamp Expression
  • Optional Version
  • Optional creationSource identifier

Either version or timestamp should be provided.

DeltaTimeTravelSpec is created when:

resolvePath

resolvePath(
  conf: SQLConf,
  identifier: String): (DeltaTimeTravelSpec, String)

resolvePath...FIXME

resolvePath is used when DeltaTableUtils utility is used to extractIfPathContainsTimeTravel.

getTimestamp

getTimestamp(
  timeZone: String): Timestamp

getTimestamp...FIXME

getTimestamp is used when DeltaTableUtils utility is used to resolveTimeTravelVersion.

isApplicable

isApplicable(
  conf: SQLConf,
  identifier: String): Boolean

isApplicable is true when all of the following hold:

isApplicable is used when DeltaTableUtils utility is used to extractIfPathContainsTimeTravel.

identifierContainsTimeTravel

identifierContainsTimeTravel(
  identifier: String): Boolean

identifierContainsTimeTravel is true when the given identifier is either timestamp or version time travel pattern.


Last update: 2020-10-13