Skip to content

UpdatableStore #113

@avibryant

Description

@avibryant

What do you guys think about something like

trait UpdatableStore[K,V] extends Store[K,V] {
  def update(k : K)(fn : V => Option[V]) : Future[Option[V]]
}

Where the semantics are that this would be an atomic update (so this makes sense for redis, mysql, etc where there's a notion of transactions or locks... presumably not for memcache).

This would be a good primitive to build MergeableStore implementations on top of that don't require specific backends.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions