Skip to content

Is it really STM? #2

@graninas

Description

@graninas

* Pure functional STM using a free monad to hide the underlying Scala STM. Refs and transaction

Hello, I'm curious if this is actually a real STM. I see atomic evaluation, but I don't see conflicts resolving. Not sure if the behavior of real STM holds here. Could you please clarify?

I found the same approach to STM with Free monads independently and then googled your code, but my STM follows the straightforward definition of STM and thus can be considered well-behaving:

https://github.com/graninas/stm-free

Also, it differs from other STMs by declaring a context explicitly. This is good because many optimizations can utilize some additional knowledge came with different contexts. Also, you can have separate "clusters" of independent STM models.

I'm still working on the library, so you might find it not that rich and mature as original Haskell's STM.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions