Uploaded image for project: 'Flink'
  1. Flink
  2. FLINK-10185

Make ZooKeeperStateHandleStore#releaseAndTryRemove synchronous

    Details

      Description

      The ZooKeeperStateHandleStore#releaseAndTryRemove method executes parts of its logic synchronously (retrieving the state handle and unlocking the ZNode) and others asynchronously (removing the ZNode). Moreover, the method takes a parameter which is used to execute some logic in case of a successful removal. This was done in order to execute a potentially blocking state discard operation in a different thread.

      I think this can be simplified by executing all logic in the same thread and running the callback after having called ZooKeeperStateHandleStore#releaseAndTryRemove. Moreover, if this operation needs to be not blocking one could use a different thread to call into this method.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                till.rohrmann Till Rohrmann
                Reporter:
                till.rohrmann Till Rohrmann
              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: