mirror of https://github.com/apache/kafka.git
MINOR: Moving the rollback out of lock in share partition (#20153)
CI / build (push) Has been cancelled
Details
Fixup PR Labels / fixup-pr-labels (needs-attention) (push) Has been cancelled
Details
Fixup PR Labels / fixup-pr-labels (triage) (push) Has been cancelled
Details
Docker Image CVE Scanner / scan_jvm (3.7.2) (push) Has been cancelled
Details
Docker Image CVE Scanner / scan_jvm (3.8.1) (push) Has been cancelled
Details
Docker Image CVE Scanner / scan_jvm (3.9.1) (push) Has been cancelled
Details
Docker Image CVE Scanner / scan_jvm (4.0.0) (push) Has been cancelled
Details
Docker Image CVE Scanner / scan_jvm (latest) (push) Has been cancelled
Details
Fixup PR Labels / needs-attention (push) Has been cancelled
Details
Flaky Test Report / Flaky Test Report (push) Has been cancelled
Details
CI / build (push) Has been cancelled
Details
Fixup PR Labels / fixup-pr-labels (needs-attention) (push) Has been cancelled
Details
Fixup PR Labels / fixup-pr-labels (triage) (push) Has been cancelled
Details
Docker Image CVE Scanner / scan_jvm (3.7.2) (push) Has been cancelled
Details
Docker Image CVE Scanner / scan_jvm (3.8.1) (push) Has been cancelled
Details
Docker Image CVE Scanner / scan_jvm (3.9.1) (push) Has been cancelled
Details
Docker Image CVE Scanner / scan_jvm (4.0.0) (push) Has been cancelled
Details
Docker Image CVE Scanner / scan_jvm (latest) (push) Has been cancelled
Details
Fixup PR Labels / needs-attention (push) Has been cancelled
Details
Flaky Test Report / Flaky Test Report (push) Has been cancelled
Details
Moving rollback out of lock, if persister returns a completed future for write state then same data-plane-request-handler thread should not call purgatory safeTryAndComplete while holding SharePartition's write lock. Reviewers: Andrew Schofield <aschofield@confluent.io>, Abhinav Dixit <adixit@confluent.io>
This commit is contained in:
parent
c058c134d2
commit
986322dc36
|
@ -958,14 +958,12 @@ public class SharePartition {
|
|||
break;
|
||||
}
|
||||
}
|
||||
|
||||
// If the acknowledgement is successful then persist state, complete the state transition
|
||||
// and update the cached state for start offset. Else rollback the state transition.
|
||||
rollbackOrProcessStateUpdates(future, throwable, updatedStates, stateBatches);
|
||||
} finally {
|
||||
lock.writeLock().unlock();
|
||||
}
|
||||
|
||||
// If the acknowledgement is successful then persist state, complete the state transition
|
||||
// and update the cached state for start offset. Else rollback the state transition.
|
||||
rollbackOrProcessStateUpdates(future, throwable, updatedStates, stateBatches);
|
||||
return future;
|
||||
}
|
||||
|
||||
|
@ -1014,13 +1012,12 @@ public class SharePartition {
|
|||
break;
|
||||
}
|
||||
}
|
||||
|
||||
// If the release acquired records is successful then persist state, complete the state transition
|
||||
// and update the cached state for start offset. Else rollback the state transition.
|
||||
rollbackOrProcessStateUpdates(future, throwable, updatedStates, stateBatches);
|
||||
} finally {
|
||||
lock.writeLock().unlock();
|
||||
}
|
||||
// If the release acquired records is successful then persist state, complete the state transition
|
||||
// and update the cached state for start offset. Else rollback the state transition.
|
||||
rollbackOrProcessStateUpdates(future, throwable, updatedStates, stateBatches);
|
||||
return future;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue