This is an automated email from the ASF dual-hosted git repository.
pjfanning pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/pekko.git
The following commit(s) were added to refs/heads/main by this push:
new 83b1b31604 fix javadoc durable state deleteobject (#2972)
83b1b31604 is described below
commit 83b1b316049e303dbb4a44a65c032bf503b4f7cb
Author: PJ Fanning <[email protected]>
AuthorDate: Fri May 15 08:37:12 2026 +0100
fix javadoc durable state deleteobject (#2972)
* fix: clarify deleteObject revision must be expected next revision
(current + 1) in docs
Agent-Logs-Url:
https://github.com/pjfanning/incubator-pekko/sessions/e855d7d3-4827-4438-9c9d-8f288f2f0c4d
Co-authored-by: pjfanning <[email protected]>
* further changes
---------
Co-authored-by: copilot-swe-agent[bot]
<[email protected]>
Co-authored-by: pjfanning <[email protected]>
---
.../pekko/persistence/state/javadsl/DurableStateUpdateStore.scala | 7 ++++---
.../pekko/persistence/state/scaladsl/DurableStateUpdateStore.scala | 7 ++++---
2 files changed, 8 insertions(+), 6 deletions(-)
diff --git
a/persistence/src/main/scala/org/apache/pekko/persistence/state/javadsl/DurableStateUpdateStore.scala
b/persistence/src/main/scala/org/apache/pekko/persistence/state/javadsl/DurableStateUpdateStore.scala
index b5ad4bec56..6fc15902c6 100644
---
a/persistence/src/main/scala/org/apache/pekko/persistence/state/javadsl/DurableStateUpdateStore.scala
+++
b/persistence/src/main/scala/org/apache/pekko/persistence/state/javadsl/DurableStateUpdateStore.scala
@@ -50,14 +50,15 @@ trait DurableStateUpdateStore[A] extends
DurableStateStore[A] {
* Delete the object with the given `persistenceId` and `revision`.
*
* <p>
- * Since Pekko v1.1, if the revision does not match the current revision
+ * If the revision does not match the expected revision
* of the object, the delete operation will fail. The returned
CompletionStage
* will complete with a failed result wrapping the exception.
* </p>
*
* @param persistenceId the persistenceId of the object to delete
- * @param revision the revision of the object to delete
- * @return a CompletionStage that completes when the object has been deleted
+ * @param revision the expected next revision for the `persistenceId` — this
must be one more than
+ * the current (existing) revision of the object
+ * @return a CompletionStage that completes when the object has been deleted
or fails if the revision does not match the expected revision of the object
*/
def deleteObject(persistenceId: String, revision: Long):
CompletionStage[Done]
}
diff --git
a/persistence/src/main/scala/org/apache/pekko/persistence/state/scaladsl/DurableStateUpdateStore.scala
b/persistence/src/main/scala/org/apache/pekko/persistence/state/scaladsl/DurableStateUpdateStore.scala
index cce5df016e..c0aa6c9525 100644
---
a/persistence/src/main/scala/org/apache/pekko/persistence/state/scaladsl/DurableStateUpdateStore.scala
+++
b/persistence/src/main/scala/org/apache/pekko/persistence/state/scaladsl/DurableStateUpdateStore.scala
@@ -50,14 +50,15 @@ trait DurableStateUpdateStore[A] extends
DurableStateStore[A] {
* Delete the object with the given `persistenceId` and `revision`.
*
* <p>
- * Since Pekko v1.1, if the revision does not match the current revision
+ * If the revision does not match the expected revision
* of the object, the delete operation will fail. The returned Future
* will complete with a failed result wrapping the exception.
* </p>
*
* @param persistenceId the persistenceId of the object to delete
- * @param revision the revision of the object to delete
- * @return a Future that completes when the object has been deleted
+ * @param revision the expected next revision for the `persistenceId` — this
must be one more than
+ * the current (existing) revision of the object
+ * @return a Future that completes when the object has been deleted or fails
if the revision does not match the expected revision of the object
*/
def deleteObject(persistenceId: String, revision: Long): Future[Done]
}
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]