Module to manipulate files in the storage repository.
Summary
Types
An archive structure. tsindex is a list of maps stored in json ie. [{"offset": 0, "timestamp": 1111}]
Functions
Returns the full path of the file, where it can be read. Includes the mountpoint set in the application config, the name of the repository as subdirectory And the path of the file.
Returns the path with the offset, in a syntax that dataselect understands.
Test the repositories. Gets a list of repositories, list the expected mount point for each of them.
Find the best fitting offsets (start and end). Timeindex is expected to be like: [ %{"offset" => 0, "timestamp" => 533174407868300000} ]
Types
@type t() :: %Wsdataselect.DataFile{ cha: String.t(), checksum: DateTime.t(), earliest: DateTime.t(), end_offset: integer(), extnet: String.t(), latest: DateTime.t(), loc: String.t(), net: String.t(), path: String.t(), quality: String.t(), repository: String.t(), source_id: String.t(), sta: String.t(), start_offset: integer(), tsindex: list(), updated: DateTime.t() }
An archive structure. tsindex is a list of maps stored in json ie. [{"offset": 0, "timestamp": 1111}]
Functions
Returns the full path of the file, where it can be read. Includes the mountpoint set in the application config, the name of the repository as subdirectory And the path of the file.
Returns the path with the offset, in a syntax that dataselect understands.
@spec health() :: {:ok | :warning | :error, String.t()}
Test the repositories. Gets a list of repositories, list the expected mount point for each of them.
Return
A tupple: {:ok, message} if all repositories are accessible
Find the best fitting offsets (start and end). Timeindex is expected to be like: [ %{"offset" => 0, "timestamp" => 533174407868300000} ]