Skip to content

Commit

Permalink
Remove note about Lagom (#698)
Browse files Browse the repository at this point in the history
* Remove note about Lagom

* Update PersistenceId.scala
  • Loading branch information
pjfanning authored Oct 7, 2023
1 parent e5d03e0 commit c6dc821
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 26 deletions.
8 changes: 0 additions & 8 deletions docs/src/main/paradox/typed/persistence.md
Original file line number Diff line number Diff line change
Expand Up @@ -119,14 +119,6 @@ to help with constructing such `PersistenceId` from an `entityTypeHint` and `ent
The default separator when concatenating the `entityTypeHint` and `entityId` is `|`, but a custom separator
is supported.

@@@ note

The `|` separator is also used in Lagom's `scaladsl.PersistentEntity` but no separator is used
in Lagom's `javadsl.PersistentEntity`. For compatibility with Lagom's `javadsl.PersistentEntity`
you should use `""` as the separator.

@@@

A custom identifier can be created with @apidoc[PersistenceId.ofUniqueId](typed.PersistenceId$) {scala="#ofUniqueId(id:String):org.apache.pekko.persistence.typed.PersistenceId" java="#ofUniqueId(java.lang.String)"}.

### Command handler
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,6 @@ object PersistenceId {

/**
* Default separator character used for concatenating a `typeHint` with `entityId` to construct unique persistenceId.
* This must be same as in Lagom's `scaladsl.PersistentEntity`, for compatibility. No separator is used
* in Lagom's `javadsl.PersistentEntity` so for compatibility with that the `""` separator must be used instead.
*/
val DefaultSeparator = "|"

Expand All @@ -37,10 +35,6 @@ object PersistenceId {
*
* Another separator can be defined by using the `apply` that takes a `separator` parameter.
*
* The `|` separator is also used in Lagom's `scaladsl.PersistentEntity` but no separator is used
* in Lagom's `javadsl.PersistentEntity`. For compatibility with Lagom's `javadsl.PersistentEntity`
* you should use `""` as the separator.
*
* @throws java.lang.IllegalArgumentException if the `entityTypeHint` or `entityId` contains `|`
*/
def apply(entityTypeHint: String, entityId: String): PersistenceId =
Expand All @@ -61,10 +55,6 @@ object PersistenceId {
*
* The default separator `|` is used by the `apply` that doesn't take a `separator` parameter.
*
* The `|` separator is also used in Lagom's `scaladsl.PersistentEntity` but no separator is used
* in Lagom's `javadsl.PersistentEntity`. For compatibility with Lagom's `javadsl.PersistentEntity`
* you should use `""` as the separator.
*
* @throws java.lang.IllegalArgumentException if the `entityTypeHint` or `entityId` contains `separator`
*/
def apply(entityTypeHint: String, entityId: String, separator: String): PersistenceId = {
Expand Down Expand Up @@ -95,10 +85,6 @@ object PersistenceId {
*
* Another separator can be defined by using the `PersistenceId.of` that takes a `separator` parameter.
*
* The `|` separator is also used in Lagom's `scaladsl.PersistentEntity` but no separator is used
* in Lagom's `javadsl.PersistentEntity`. For compatibility with Lagom's `javadsl.PersistentEntity`
* you should use `""` as the separator.
*
* @throws java.lang.IllegalArgumentException if the `entityTypeHint` or `entityId` contains `|`
*/
def of(entityTypeHint: String, entityId: String): PersistenceId =
Expand All @@ -119,10 +105,6 @@ object PersistenceId {
*
* The default separator `|` is used by the `apply` that doesn't take a `separator` parameter.
*
* The `|` separator is also used in Lagom's `scaladsl.PersistentEntity` but no separator is used
* in Lagom's `javadsl.PersistentEntity`. For compatibility with Lagom's `javadsl.PersistentEntity`
* you should use `""` as the separator.
*
* @throws java.lang.IllegalArgumentException if the `entityTypeHint` or `entityId` contains `separator`
*/
def of(entityTypeHint: String, entityId: String, separator: String): PersistenceId =
Expand Down

0 comments on commit c6dc821

Please sign in to comment.