Ah, cool finally! I was looking for some LUA code examples,
particularly those that improve transactions.
Forgot to mention the rollbacks of course, that was the second problem point.
I'll look into this, but for the transaction-internal dependencies my
problem is that sometimes the condition is not known at the moment the
transaction is sent, and which does not depend on code outside
redis/lua but some other java logic.. Have to check for way to
workaround that.
thanks a lot for your answer!
ingvar
2011/9/15 Jak Sprats <jaks...@gmail.com>:
> --
> You received this message because you are subscribed to the Google Groups "Redis DB" group.
> To post to this group, send email to redi...@googlegroups.com.
> To unsubscribe from this group, send email to redis-db+u...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/redis-db?hl=en.
>
>
> So my learning's from your reply:
> Yes its possible to use Redis (Master/Slave) for ACID transactions
> (including rollback) under the following conditions:
> - AOF is set to always on the master
why do you say AOF always? According to the information embedded in
the redis config file, AOF set to always is very slow. It emphasizes
that aof every second is a good compromise, but of course this depends
on your use case needs.
> - All the transactions are scripted in LUA and the rollback logic (if
> required) is factored into it.
beware that LUA scripting (eval) is not yet available in every client.
e.g. jedis, the Java client, doesn't support Lua yet.
I'd be interested in your experiences with LUA transaction scripts
best,
ingvar
Hello Ingvar,
we'll start without any MULTI/EXEC support for Cluster (unless they
are all about a single key).
Basically we'll support only operations that are Cluster Obvious.
We'll see later if we'll be able to add transactions to the mix, but
the plan is to start with a reasonable subset of Redis commands.
Other things that will not be supported (at least initially, unsure
about the future) are commands operating on multiple keys.
Cheers,
Salvatore
--
Salvatore 'antirez' Sanfilippo
open source developer - VMware
http://invece.org
"We are what we repeatedly do. Excellence, therefore, is not an act,
but a habit." -- Aristotele