This project manages an in-memory store using a map that can hold arbitrary structs as values identified by a string key. Changes to the values in the store are managed by two sets of channels: a primary channel for high-priority changes and a secondary channel for low-priority background processes.
- In-memory store with string keys and arbitrary struct values
- Primary and secondary channels for managing changes
- Thread-safe operations with sync.RWMutex
- Example usage with goroutines
-
Navigate to the project directory:
cd /Users/jp/Dev/datastoreconcept -
Run the project:
go run main.go
The main.go file contains examples of how to use the store:
- Submitting changes to the primary and secondary channels
- Printing the final state of the store
- Deleting a key from the store