View Source Jellyfish.Cache (Jellyfish v0.2.4)
Provides process-dictionary-based caching for hot upgrade operations.
This module manages ephemeral state during the build process to track which applications and dependencies have been processed for appup generation and copying. The cache is scoped to the current Mix process and does not persist across builds.
Use Cases
- Deduplication: Ensures appup files are generated only once per dependency
- Version Tracking: Stores application version information for use across build tasks
- Build Coordination: Coordinates state between
GenAppupandCopyAppuptasks
Summary
Functions
Checks if this is the first time copying appup files for a library.
Checks if this is the first time generating appup files for a library.
Retrieves application information from the cache.
Stores application version information in the process cache.
Functions
Checks if this is the first time copying appup files for a library.
Similar to first_run_gen_appup?/1, but tracks the copy operation separately.
This allows the build process to coordinate generation and copying as distinct phases.
Checks if this is the first time generating appup files for a library.
This function uses a boolean flag to track whether appup generation has been
triggered for a specific library. The first call returns true and sets the
flag to false, ensuring subsequent calls return false.
Retrieves application information from the cache.
Returns the data previously stored via store_app_version/2, or nil if
no data exists for the given application.
Stores application version information in the process cache.
The version is stored as a map with a :version key, allowing for future
extension with additional metadata if needed.