org.apache.ignite.internal.processors.cache.mvcc

## Class ProbedTx

- java.lang.Object
- - org.apache.ignite.internal.processors.cache.mvcc.ProbedTx

All Implemented Interfaces:
  Serializable, Message

    public class ProbedTx
    extends Object
    implements Message

Contains attributes of tx visited during deadlock detection.

See Also:
  Serialized Form

### Field Summary

### Fields inherited from interface org.apache.ignite.plugin.extensions.communication.Message

`DIRECT_TYPE_SIZE`

### Constructor Summary

Constructors
Constructor and Description
`ProbedTx()`
`ProbedTx(UUID nodeId, GridCacheVersion xidVer, GridCacheVersion nearXidVer, long startTime, int lockCntr)`

### Method Summary

All Methods Instance Methods Concrete Methods
`short` `directType()` Gets message type.
`byte` `fieldsCount()` Gets fields count.
`int` `lockCounter()`
`GridCacheVersion` `nearXidVersion()`
`UUID` `nodeId()`
`void` `onAckReceived()` Method called when ack message received.
`boolean` `readFrom(ByteBuffer buf, MessageReader reader)` Reads this message from provided byte buffer.
`long` `startTime()`
`String` `toString()`
`ProbedTx` `withStartTime(long updStartTime)` Creates a copy of this instance with modified transaction start time.
`boolean` `writeTo(ByteBuffer buf, MessageWriter writer)` Writes this message to provided byte buffer.
`GridCacheVersion` `xidVersion()`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

### Constructor Detail

#### ProbedTx

    public ProbedTx()

#### ProbedTx

    public ProbedTx(UUID nodeId,
                    GridCacheVersion xidVer,
                    GridCacheVersion nearXidVer,
                    long startTime,
                    int lockCntr)

Parameters:
  `nodeId` - Node on which probed transaction runs.
  `xidVer` - Identifier of transaction.
  `nearXidVer` - Identifier of near transaction.
  `startTime` - Transaction start time.
  `lockCntr` - Number of locks acquired by probed transaction at a time of probe handling.

### Method Detail

#### nodeId

    public UUID nodeId()

Returns:
  Node on which probed transaction runs.

#### xidVersion

    public GridCacheVersion xidVersion()

Returns:
  Identifier of transaction.

#### nearXidVersion

    public GridCacheVersion nearXidVersion()

Returns:
  Identifier of near transaction.

#### startTime

    public long startTime()

Returns:
  Transaction start time.

#### lockCounter

    public int lockCounter()

Returns:
  Number of locks acquired by probed transaction at a time of probe handling.

#### withStartTime

    public ProbedTx withStartTime(long updStartTime)

Creates a copy of this instance with modified transaction start time.

Parameters:
  `updStartTime` - New start time value.
Returns:
  Instance with updated start time.

#### writeTo

    public boolean writeTo(ByteBuffer buf,
                           MessageWriter writer)

Writes this message to provided byte buffer.

Specified by:
  `writeTo` in interface `Message`
Parameters:
  `buf` - Byte buffer.
  `writer` - Writer.
Returns:
  Whether message was fully written.

#### readFrom

    public boolean readFrom(ByteBuffer buf,
                            MessageReader reader)

Reads this message from provided byte buffer.

Specified by:
  `readFrom` in interface `Message`
Parameters:
  `buf` - Byte buffer.
  `reader` - Reader.
Returns:
  Whether message was fully read.

#### directType

    public short directType()

Gets message type.

Specified by:
  `directType` in interface `Message`
Returns:
  Message type.

#### fieldsCount

    public byte fieldsCount()

Gets fields count.

Specified by:
  `fieldsCount` in interface `Message`
Returns:
  Fields count.

#### onAckReceived

    public void onAckReceived()

Method called when ack message received.

Specified by:
  `onAckReceived` in interface `Message`

#### toString

    public String toString()

Overrides:
  `toString` in class `Object`

${current.year} Copyright © Apache Software Foundation

Follow @ApacheIgnite

Ignite Database and Caching Platform | : ver. 2.15.0
Release Date | : April 25 2023