ignite-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Andrey N. Gura (Jira)" <j...@apache.org>
Subject [jira] [Created] (IGNITE-14269) Design conditional multi update functionality for meta storage client
Date Wed, 03 Mar 2021 06:32:00 GMT
Andrey N. Gura created IGNITE-14269:
---------------------------------------

             Summary: Design conditional multi update functionality for meta storage client
                 Key: IGNITE-14269
                 URL: https://issues.apache.org/jira/browse/IGNITE-14269
             Project: Ignite
          Issue Type: New Feature
            Reporter: Andrey N. Gura
            Assignee: Andrey N. Gura
             Fix For: 3.0.0-alpha2


Define entities required for implementation of conditional multi updates (aka "transactions")
for meta storage.

Requirements:

- Design should provide possibility to define conditional updates in if-then-else manner with
nested branches.
- Update always starts with condition.
- Any nested branch must start with condition. 
- Update can't precede to condition.
- Every branch can yield exactly one custom result (limited by number of simple types) and
any number of entries. Corresponding expression always must be at the end of branch.
- Condition for entry revision allows the following comparisons: equal, !equal, less, greater.
- Condition for entry value allows the following operations (byte-wise): equal, !equal.
- Update allows the following operations: put, remove, no-op.
- Condition can not use previously defined condition instance again because it will lead to
graph cycle and infinite update execution.

Assumptions:

- It seems that conditions and updates entities can be conveniently linked using chaining.

Simple example (pseudocode):

{code}
    CompletableFuture<Result, List<Entry>> = invoke(valCond(EQUAL, perstEnabled,
true)._then(
             valCond(EQUAL, walEnabled, true)._then(
                     update(walEnabled, true)).
             _else(
                     update(walEnabled, false))
            )._else(NoopUpdate))

{code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Mime
View raw message