Vladislav Pyatkov created IGNITE-20768:
------------------------------------------

             Summary: Test coverege of batch operations
                 Key: IGNITE-20768
                 URL: https://issues.apache.org/jira/browse/IGNITE-20768
             Project: Ignite
          Issue Type: Improvement
            Reporter: Vladislav Pyatkov


Investigation during the implementation of IGNITE-20609 shows that no one fails 
when we have a mistace in the patch.
The first place not covered by tests in the code:
{code:title=PartitionReplicaListener.java}
if (lastCommitTimestamp != null || row != null) {
            TimedBinaryRowMessageBuilder rowMsgBldr = 
MSG_FACTORY.timedBinaryRowMessage();

            if (lastCommitTimestamp != null) {
                rowMsgBldr.timestamp(lastCommitTimestamp.longValue());
            }

            if (row != null) {
                rowMsgBldr.binaryRowMessage(binaryRowMessage(row));
            }

            bldr.messageRowToUpdate(rowMsgBldr.build());
        }
{code}
We need to add a test for batch operations that has both fields (not nulles): 
_lastCommitTimestamp_ and _row_.
The second
{code:title=StorageUpdateHandler.java}
performStorageCleanupIfNeeded(txId, rowId, entry.getValue() == null ? null : 
entry.getValue().commitTimestamp());
{code}
We need to add a test for batch operations where `entry.getValue()` is null. 



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to