memory_store.go 452 B

12345678910111213141516171819202122232425
  1. package states
  2. import (
  3. "sync"
  4. )
  5. type MemoryStore sync.Map //The current root store of a rule
  6. func newMemoryStore() *MemoryStore {
  7. return &MemoryStore{}
  8. }
  9. func (s *MemoryStore) SaveState(_ int64, _ string, _ map[string]interface{}) error {
  10. //do nothing
  11. return nil
  12. }
  13. func (s *MemoryStore) SaveCheckpoint(_ int64) error {
  14. //do nothing
  15. return nil
  16. }
  17. func (s *MemoryStore) GetOpState(opId string) (*sync.Map, error) {
  18. return &sync.Map{}, nil
  19. }