Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

IDIEP-34
Author
Sponsor
Created

 

Status

Status
colourGreen
titleCOMPLETED


Table of Contents

Motivation

Currently transactions are not supported by thin client protocol. 

Description

There are changes needed for protocol, server side, and client side to support transactions.

Protocol changes

Add new operations to the thin client protocol:

NameCodeDescription
OP_TX_START4000Start a new transaction
OP_TX_END4001End the transaction

OP_TX_START message format

Request
byte

Concurrency control:

0 - OPTIMISTIC

1 - PESSIMISTIC

byte

Isolation level:

0 - READ_COMMITTED

1 - REPEATABLE_READ

2 - SERIALIZABLE

longTimeout
stringlabel

...

Response

intUnique per client connection transaction id. This id should be returned as parameter with OP_TX_END message and all messages of cache operations within the transaction.

OP_TX_END message format

Request
int

Transaction id.

bool

Commit flag.


Empty response.

Cache operations

We need to add a new field to requests header of all cache data manipulation operations (opcodes 1000-1020, 2000, 2002, 2004) to bind these operations with the transaction.

...

When the client sends OP_TX_END request, thread served this request resumes the transaction and commit or rollback it.

Client-side changes

The client must bind transaction and all cache operations which was made within this explicitly started transaction. We can implement transaction per thread approach on the thin client side as implemented now for the thick client. In this case, each transaction on the thin client side will be bound to a thread started this transaction. And each cache operation performed by this thread will be bound to the same transaction until the transaction is completed.

...

This transaction configuration can be used when the client connection is created (as a property of ClientConfiguration class).

Risks and Assumptions

//

Discussion Links

http://apache-ignite-developers.2346864.n4.nabble.com/Thin-client-transactions-support-td27761.html

Reference Links

// Links to various reference documents, if applicable.

Tickets

Jira
serverASF JIRA
columnskey,summary,type,created,updated,due,assignee,reporter,priority,status,resolution
maximumIssues20
jqlQueryproject = Ignite AND labels IN (iep-34) ORDER BY status
serverId5aa69414-a9e9-3523-82ec-879b028fb15b