Interface SnapshotMetaPath

All Known Implementing Classes:
LocalSnapshotMetaPath

public interface SnapshotMetaPath
Represents a snapshot's meta file.

Locks are not used as concurrent reading and writing of the same file shouldn't happen by design. Only concurrent reads during restoration of the single-copy snapshot are possible.

  • Method Summary

    Modifier and Type
    Method
    Description
    Opens a channel to read the object identified by this path.
    uri()
    Returns URI of the object identified by this path.
    Opens a channel to write the object identified by this path.
  • Method Details

    • readChannel

      ReadableByteChannel readChannel() throws IOException
      Opens a channel to read the object identified by this path.
      Throws:
      IOException
    • writeChannel

      WritableByteChannel writeChannel() throws IOException
      Opens a channel to write the object identified by this path.

      Creates the object if it does not exist.

      Closing the channel ensures that the data has been saved durably on the underlying storage.

      Throws:
      IOException
    • uri

      URI uri()
      Returns URI of the object identified by this path.