[
https://issues.apache.org/jira/browse/IGNITE-21290?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17813149#comment-17813149
]
Alexander Lapin commented on IGNITE-21290:
------------------------------------------
[~v.pyatkov] LGTM.
> Scan cursors do not close after being fully read in transactions
> ----------------------------------------------------------------
>
> Key: IGNITE-21290
> URL: https://issues.apache.org/jira/browse/IGNITE-21290
> Project: Ignite
> Issue Type: Bug
> Reporter: Vladislav Pyatkov
> Assignee: Vladislav Pyatkov
> Priority: Major
> Labels: ignite-3
> Time Spent: 1h 40m
> Remaining Estimate: 0h
>
> h3. Motivation
> Open cursors require extra memory on the server side, so they should be
> closed as soon as they are no longer used. It is easy to understand on the
> coursor owner server when the coursor returns false for the hasNext
> invocation.
> Despite the fact that all acquired transaction resources should be released
> after the transaction finalizes, it would be better to close usles coursorse
> faseter. Moreover, the agreement is fit for all types of transactions: RO,
> RW, and inplicit.
> h3. Implementation notes
> When the replica returns a batch, their size can be estimated, and the cursor
> can be closed if the size is less than requested.
> h3. Definition of done
> A cursor is closed on the server side when the client retrieves all data from
> it through any type of scan operation.
> Moreover, the server-side cursors should be closed in case the cursor
> supplier is closing through the API.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)