|
PACS System 0.1.0
PACS DICOM system library
|
Metadata for tracking instance tier location. More...
#include <hsm_types.h>

Public Member Functions | |
| auto | age () const -> std::chrono::system_clock::duration |
| Get the age of the instance (time since storage) | |
| auto | time_since_access () const -> std::chrono::system_clock::duration |
| Get the time since last access. | |
| auto | should_migrate (const tier_policy &policy, storage_tier target_tier) const -> bool |
| Check if instance is eligible for migration to a target tier. | |
Public Attributes | |
| std::string | sop_instance_uid |
| SOP Instance UID of the DICOM instance. | |
| storage_tier | current_tier {storage_tier::hot} |
| Current storage tier. | |
| std::chrono::system_clock::time_point | stored_at |
| Timestamp when instance was stored. | |
| std::optional< std::chrono::system_clock::time_point > | last_accessed |
| Timestamp of last access (retrieve operation) nullopt if never accessed after initial storage. | |
| std::size_t | size_bytes {0} |
| Size of the instance in bytes. | |
| std::string | study_instance_uid |
| Study Instance UID (for grouping migrations) | |
| std::string | series_instance_uid |
| Series Instance UID (for grouping migrations) | |
Metadata for tracking instance tier location.
Stores information about where an instance is stored and when it was last accessed, used for making migration decisions.
Definition at line 142 of file hsm_types.h.
|
inlinenodiscard |
Get the age of the instance (time since storage)
Definition at line 170 of file hsm_types.h.
References stored_at.
Referenced by time_since_access().

|
inlinenodiscard |
Check if instance is eligible for migration to a target tier.
| policy | The tier policy to check against |
| target_tier | The target tier for migration |
Definition at line 192 of file hsm_types.h.
References kcenon::pacs::storage::cold, current_tier, kcenon::pacs::storage::hot, size_bytes, time_since_access(), and kcenon::pacs::storage::warm.

|
inlinenodiscard |
Get the time since last access.
Definition at line 178 of file hsm_types.h.
References age(), and last_accessed.
Referenced by should_migrate().


| storage_tier kcenon::pacs::storage::tier_metadata::current_tier {storage_tier::hot} |
Current storage tier.
Definition at line 147 of file hsm_types.h.
Referenced by should_migrate(), and kcenon::pacs::storage::hsm_storage::update_metadata().
| std::optional<std::chrono::system_clock::time_point> kcenon::pacs::storage::tier_metadata::last_accessed |
Timestamp of last access (retrieve operation) nullopt if never accessed after initial storage.
Definition at line 155 of file hsm_types.h.
Referenced by time_since_access().
| std::string kcenon::pacs::storage::tier_metadata::series_instance_uid |
Series Instance UID (for grouping migrations)
Definition at line 164 of file hsm_types.h.
Referenced by kcenon::pacs::storage::hsm_storage::update_metadata().
| std::size_t kcenon::pacs::storage::tier_metadata::size_bytes {0} |
Size of the instance in bytes.
Definition at line 158 of file hsm_types.h.
Referenced by should_migrate(), and kcenon::pacs::storage::hsm_storage::update_metadata().
| std::string kcenon::pacs::storage::tier_metadata::sop_instance_uid |
SOP Instance UID of the DICOM instance.
Definition at line 144 of file hsm_types.h.
Referenced by kcenon::pacs::storage::hsm_storage::update_metadata().
| std::chrono::system_clock::time_point kcenon::pacs::storage::tier_metadata::stored_at |
Timestamp when instance was stored.
Definition at line 150 of file hsm_types.h.
Referenced by age(), and kcenon::pacs::storage::hsm_storage::update_metadata().
| std::string kcenon::pacs::storage::tier_metadata::study_instance_uid |
Study Instance UID (for grouping migrations)
Definition at line 161 of file hsm_types.h.
Referenced by kcenon::pacs::storage::hsm_storage::update_metadata().