Interface ArchiveWriter


public interface ArchiveWriter
Interface for writing samples to an archive
Author:
Kay Kasemir
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    Should be called to release resources, for example disconnect from a relational database.
    void
    Write all recently added samples to the archive.
    Obtain a channel to which samples can be written
  • Method Details

    • getChannel

      WriteChannel getChannel(String name) throws Exception
      Obtain a channel to which samples can be written
      Parameters:
      name - Channel name (typically a PV name)
      Returns:
      WriteChannel, not null
      Throws:
      Exception - on error, for example failure to access the data store, or a new, previously unknown channel name could not be added to the archive
    • flush

      void flush() throws Exception
      Write all recently added samples to the archive.

      Since the underlying implementation is allowed to optimize, it might buffer the added samples, or queue them by data type, and an explicit call to this method is required to flush them out to the archive storage.

      Throws:
      Exception - on error, for example failure to access the data store. Samples added since the last flush() are likely lost
    • close

      void close()
      Should be called to release resources, for example disconnect from a relational database.