diff --git a/.github/release-drafter.yml b/.github/release-drafter.yml index cdcfdc01..11724eb3 100644 --- a/.github/release-drafter.yml +++ b/.github/release-drafter.yml @@ -1,5 +1,5 @@ # Config for https://github.com/toolmantim/release-drafter -name-template: 'Akka Persistence Postgres $NEXT_PATCH_VERSION' +name-template: 'Pekko Persistence Postgres $NEXT_PATCH_VERSION' tag-template: 'v$NEXT_PATCH_VERSION' categories: @@ -10,7 +10,7 @@ categories: - title: 'Dependency changes' label: 'dependency-change' -change-template: '- $TITLE [#$NUMBER](https://github.com/SwissBorg/akka-persistence-postgres/issues/$NUMBER) by [@$AUTHOR](https://github.com/$AUTHOR)' +change-template: '- $TITLE [#$NUMBER](https://github.com/SwissBorg/pekko-persistence-postgres/issues/$NUMBER) by [@$AUTHOR](https://github.com/$AUTHOR)' template: | ## Changes diff --git a/.scala-steward.conf b/.scala-steward.conf index 5b981ee7..92bcf3ed 100644 --- a/.scala-steward.conf +++ b/.scala-steward.conf @@ -1,7 +1,6 @@ pullRequests.frequency = "1 day" updates.ignore = [ - { groupId = "com.typesafe.akka" }, { groupId = "org.scalameta", artifactId = "scalafmt-core" } ] diff --git a/build.sbt b/build.sbt index 695e0673..bf817359 100644 --- a/build.sbt +++ b/build.sbt @@ -1,6 +1,6 @@ import com.typesafe.tools.mima.plugin.MimaKeys.mimaBinaryIssueFilters -lazy val `akka-persistence-postgres` = project +lazy val `pekko-persistence-postgres` = project .in(file(".")) .enablePlugins(ScalaUnidocPlugin) .disablePlugins(MimaPlugin) @@ -11,7 +11,7 @@ lazy val core = project .in(file("core")) .enablePlugins(MimaPlugin) .settings( - name := "akka-persistence-postgres", + name := "pekko-persistence-postgres", libraryDependencies ++= Dependencies.Libraries, mimaBinaryIssueFilters ++= Seq()) @@ -19,7 +19,7 @@ lazy val migration = project .in(file("migration")) .disablePlugins(MimaPlugin) .settings( - name := "akka-persistence-postgres-migration", + name := "pekko-persistence-postgres-migration", libraryDependencies ++= Dependencies.Migration, Test / parallelExecution := false) .dependsOn(core) diff --git a/core/src/main/resources/reference.conf b/core/src/main/resources/reference.conf index 1db61189..0ed78be8 100644 --- a/core/src/main/resources/reference.conf +++ b/core/src/main/resources/reference.conf @@ -12,7 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -akka-persistence-postgres { +pekko-persistence-postgres { # If set to true event deletion is performed as a soft, logical delete. Events are kept in the journal and are sill # delivered in queries. Otherwise, a hard delete will be performed. @@ -25,7 +25,7 @@ akka-persistence-postgres { # logicalDeletion.enable = true - database-provider-fqcn = "akka.persistence.postgres.db.DefaultSlickDatabaseProvider" + database-provider-fqcn = "org.apache.pekko.persistence.postgres.db.DefaultSlickDatabaseProvider" shared-databases { // Shared databases can be defined here. @@ -43,15 +43,15 @@ akka-persistence-postgres { # The JDBC URL for the chosen database # (uncomment and set the property below to match your needs) - # url = "jdbc:postgresql://localhost:5432/akka-plugin" + # url = "jdbc:postgresql://localhost:5432/pekko-plugin" # The database username # (uncomment and set the property below to match your needs) - # user = "akka-plugin" + # user = "pekko-plugin" # The username's password # (uncomment and set the property below to match your needs) - # password = "akka-plugin" + # password = "pekko-plugin" # hikariCP settings; see: https://github.com/brettwooldridge/HikariCP # Slick will use an async executor with a fixed size queue of 10.000 objects @@ -99,14 +99,14 @@ akka-persistence-postgres { } } -# the akka-persistence-journal in use +# the pekko-persistence-journal in use postgres-journal { - class = "akka.persistence.postgres.journal.PostgresAsyncWriteJournal" + class = "org.apache.pekko.persistence.postgres.journal.PostgresAsyncWriteJournal" tables { journal { - # Used by akka.persistence.postgres.journal.dao.NestedPartitionsJournalDao - # and akka.persistence.postgres.journal.dao.PartitionedJournalDao + # Used by org.apache.pekko.persistence.postgres.journal.dao.NestedPartitionsJournalDao + # and org.apache.pekko.persistence.postgres.journal.dao.PartitionedJournalDao partitions { # The size of a single partition size: 10000000 @@ -147,12 +147,12 @@ postgres-journal { } } - # Replace with "akka.persistence.postgres.journal.dao.NestedPartitionsJournalDao" - # or "akka.persistence.postgres.journal.dao.PartitionedJournalDao" in order to enable + # Replace with "org.apache.pekko.persistence.postgres.journal.dao.NestedPartitionsJournalDao" + # or "org.apache.pekko.persistence.postgres.journal.dao.PartitionedJournalDao" in order to enable # partitioning. - dao = "akka.persistence.postgres.journal.dao.FlatJournalDao" + dao = "org.apache.pekko.persistence.postgres.journal.dao.FlatJournalDao" - # Confguration for akka.persistence.postgres.tag.TagIdResolver + # Confguration for org.apache.pekko.persistence.postgres.tag.TagIdResolver tags { # The timeout after unused tag is removed from the TagIdResolver's cache cacheTtl = 1 hour @@ -172,16 +172,16 @@ postgres-journal { parallelism = 8 # Only mark as deleted. If false, delete physically - # should not be configured directly, but through property akka-persistence-postgres.logicalDelete.enable + # should not be configured directly, but through property pekko-persistence-postgres.logicalDelete.enable # in order to keep consistent behavior over write/read sides - logicalDelete = ${akka-persistence-postgres.logicalDeletion.enable} + logicalDelete = ${pekko-persistence-postgres.logicalDeletion.enable} # This setting can be used to configure usage of a shared database. # To disable usage of a shared database, set to null or an empty string. - # When set to a non emty string, this setting does two things: + # When set to a non empty string, this setting does two things: # - The actor which manages the write-journal will not automatically close the db when the actor stops (since it is shared) - # - If akka-persistence-postgres.database-provider-fqcn is set to akka.persistence.postgres.db.DefaultSlickDatabaseProvider - # then the shared database with the given name will be used. (shared databases are configured as part of akka-persistence-postgres.shared-databases) + # - If pekko-persistence-postgres.database-provider-fqcn is set to org.apache.pekko.persistence.postgres.db.DefaultSlickDatabaseProvider + # then the shared database with the given name will be used. (shared databases are configured as part of pekko-persistence-postgres.shared-databases) # Please note that the database will only be shared with the other journals if the use-shared-db is also set # to the same value for these other journals. use-shared-db = null @@ -201,15 +201,15 @@ postgres-journal { # The JDBC URL for the chosen database # (uncomment and set the property below to match your needs) - # url = "jdbc:postgresql://localhost:5432/akka-plugin" + # url = "jdbc:postgresql://localhost:5432/pekko-plugin" # The database username # (uncomment and set the property below to match your needs) - # user = "akka-plugin" + # user = "pekko-plugin" # The username's password # (uncomment and set the property below to match your needs) - # password = "akka-plugin" + # password = "pekko-plugin" # hikariCP settings; see: https://github.com/brettwooldridge/HikariCP # Slick will use an async executor with a fixed size queue of 10.000 objects @@ -256,9 +256,9 @@ postgres-journal { } } -# the akka-persistence-snapshot-store in use +# the pekko-persistence-snapshot-store in use postgres-snapshot-store { - class = "akka.persistence.postgres.snapshot.PostgresSnapshotStore" + class = "org.apache.pekko.persistence.postgres.snapshot.PostgresSnapshotStore" tables { snapshot { @@ -276,15 +276,15 @@ postgres-snapshot-store { # This setting can be used to configure usage of a shared database. # To disable usage of a shared database, set to null or an empty string. - # When set to a non emty string, this setting does two things: + # When set to a non empty string, this setting does two things: # - The actor which manages the snapshot-journal will not automatically close the db when the actor stops (since it is shared) - # - If akka-persistence-postgres.database-provider-fqcn is set to akka.persistence.postgres.db.DefaultSlickDatabaseProvider - # then the shared database with the given name will be used. (shared databases are configured as part of akka-persistence-postgres.shared-databases) + # - If pekko-persistence-postgres.database-provider-fqcn is set to org.apache.pekko.persistence.postgres.db.DefaultSlickDatabaseProvider + # then the shared database with the given name will be used. (shared databases are configured as part of pekko-persistence-postgres.shared-databases) # Please note that the database will only be shared with the other journals if the use-shared-db is also set # to the same value for these other journals. use-shared-db = null - dao = "akka.persistence.postgres.snapshot.dao.ByteArraySnapshotDao" + dao = "org.apache.pekko.persistence.postgres.snapshot.dao.ByteArraySnapshotDao" slick { @@ -293,15 +293,15 @@ postgres-snapshot-store { # The JDBC URL for the chosen database # (uncomment and set the property below to match your needs) - # url = "jdbc:postgresql://localhost:5432/akka-plugin" + # url = "jdbc:postgresql://localhost:5432/pekko-plugin" # The database username # (uncomment and set the property below to match your needs) - # user = "akka-plugin" + # user = "pekko-plugin" # The username's password # (uncomment and set the property below to match your needs) - # password = "akka-plugin" + # password = "pekko-plugin" # hikariCP settings; see: https://github.com/brettwooldridge/HikariCP # Slick will use an async executor with a fixed size queue of 10.000 objects @@ -348,9 +348,9 @@ postgres-snapshot-store { } } -# the akka-persistence-query provider in use +# the pekko-persistence-query provider in use postgres-read-journal { - class = "akka.persistence.postgres.query.PostgresReadJournalProvider" + class = "org.apache.pekko.persistence.postgres.query.PostgresReadJournalProvider" # Absolute path to the write journal plugin configuration section. # Read journal uses event adapters from the write plugin @@ -369,9 +369,9 @@ postgres-read-journal { # This setting can be used to configure usage of a shared database. # To disable usage of a shared database, set to null or an empty string. - # This setting only has effect if akka-persistence-postgres.database-provider-fqcn is set to - # akka.persistence.postgres.db.DefaultSlickDatabaseProvider. When this setting is set to a non empty string - # then the shared database with the given name will be used. (shared databases are configured as part of akka-persistence-postgres.shared-databases) + # This setting only has effect if pekko-persistence-postgres.database-provider-fqcn is set to + # org.apache.pekko.persistence.postgres.db.DefaultSlickDatabaseProvider. When this setting is set to a non empty string + # then the shared database with the given name will be used. (shared databases are configured as part of pekko-persistence-postgres.shared-databases) # Please note that the database will only be shared with the other journals if the use-shared-db is also set # to the same value for these other journals. use-shared-db = null @@ -385,26 +385,26 @@ postgres-read-journal { use-journal-metadata = false - # Replace with "akka.persistence.postgres.query.dao.PartitionedReadJournalDao" in order to leverage dedicated queries to + # Replace with "org.apache.pekko.persistence.postgres.query.dao.PartitionedReadJournalDao" in order to leverage dedicated queries to # partitioned journal. - dao = "akka.persistence.postgres.query.dao.FlatReadJournalDao" + dao = "org.apache.pekko.persistence.postgres.query.dao.FlatReadJournalDao" - # Confguration for akka.persistence.postgres.tag.TagIdResolver + # Configuration for org.apache.pekko.persistence.postgres.tag.TagIdResolver tags { # The timeout after unused tag is removed from the TagIdResolver's cache cacheTtl = 1 hour } # if true, queries will include logically deleted events - # should not be configured directly, but through property akka-persistence-postgres.logicalDelete.enable + # should not be configured directly, but through property pekko-persistence-postgres.logicalDelete.enable # in order to keep consistent behavior over write/read sides - includeLogicallyDeleted = ${akka-persistence-postgres.logicalDeletion.enable} + includeLogicallyDeleted = ${pekko-persistence-postgres.logicalDeletion.enable} # Settings for determining if ids (ordering column) in the journal are out of sequence. journal-sequence-retrieval { # The maximum number of ids that will be retrieved in each batch batch-size = 10000 - # In case a number in the sequence is missing, this is the ammount of retries that will be done to see + # In case a number in the sequence is missing, this is the amount of retries that will be done to see # if the number is still found. Note that the time after which a number in the sequence is assumed missing is # equal to maxTries * queryDelay # (maxTries may not be zero) @@ -413,7 +413,7 @@ postgres-read-journal { query-delay = 1 second # The maximum backoff time before trying to query again in case of database failures max-backoff-query-delay = 1 minute - # The ask timeout to use when querying the journal sequence actor, the actor should normally repond very quickly, + # The ask timeout to use when querying the journal sequence actor, the actor should normally respond very quickly, # since it always replies with its current internal state ask-timeout = 1 second } @@ -459,15 +459,15 @@ postgres-read-journal { # The JDBC URL for the chosen database # (uncomment and set the property below to match your needs) - # url = "jdbc:postgresql://localhost:5432/akka-plugin" + # url = "jdbc:postgresql://localhost:5432/pekko-plugin" # The database username # (uncomment and set the property below to match your needs) - # user = "akka-plugin" + # user = "pekko-plugin" # The username's password # (uncomment and set the property below to match your needs) - # password = "akka-plugin" + # password = "pekko-plugin" # hikariCP settings; see: https://github.com/brettwooldridge/HikariCP # Slick will use an async executor with a fixed size queue of 10.000 objects diff --git a/core/src/main/scala/akka/persistence/postgres/tag/EventTag.scala b/core/src/main/scala/akka/persistence/postgres/tag/EventTag.scala deleted file mode 100644 index 0fcc769c..00000000 --- a/core/src/main/scala/akka/persistence/postgres/tag/EventTag.scala +++ /dev/null @@ -1,3 +0,0 @@ -package akka.persistence.postgres.tag - -case class EventTag(id: Int, name: String) diff --git a/core/src/main/scala/akka/persistence/postgres/config/AkkaPersistenceConfig.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/config/PekkoPersistenceConfig.scala similarity index 95% rename from core/src/main/scala/akka/persistence/postgres/config/AkkaPersistenceConfig.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/config/PekkoPersistenceConfig.scala index 73e3c079..29bfa29f 100644 --- a/core/src/main/scala/akka/persistence/postgres/config/AkkaPersistenceConfig.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/config/PekkoPersistenceConfig.scala @@ -3,9 +3,9 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.config +package org.apache.pekko.persistence.postgres.config -import akka.persistence.postgres.util.ConfigOps._ +import org.apache.pekko.persistence.postgres.util.ConfigOps._ import com.typesafe.config.Config import scala.concurrent.duration._ @@ -107,7 +107,7 @@ class TagsTableConfiguration(config: Config) { } class JournalPluginConfig(config: Config) { - val dao: String = config.asString("dao", "akka.persistence.postgres.journal.dao.FlatJournalDao") + val dao: String = config.asString("dao", "org.apache.pekko.persistence.postgres.journal.dao.FlatJournalDao") override def toString: String = s"JournalPluginConfig($dao)" } @@ -122,12 +122,12 @@ class BaseByteArrayJournalDaoConfig(config: Config) { } class ReadJournalPluginConfig(config: Config) { - val dao: String = config.as[String]("dao", "akka.persistence.postgres.query.dao.FlatReadJournalDao") + val dao: String = config.as[String]("dao", "org.apache.pekko.persistence.postgres.query.dao.FlatReadJournalDao") override def toString: String = s"ReadJournalPluginConfig($dao)" } class SnapshotPluginConfig(config: Config) { - val dao: String = config.as[String]("dao", "akka.persistence.postgres.snapshot.dao.ByteArraySnapshotDao") + val dao: String = config.as[String]("dao", "org.apache.pekko.persistence.postgres.snapshot.dao.ByteArraySnapshotDao") override def toString: String = s"SnapshotPluginConfig($dao)" } diff --git a/core/src/main/scala/akka/persistence/postgres/db/DbErrors.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/db/DbErrors.scala similarity index 96% rename from core/src/main/scala/akka/persistence/postgres/db/DbErrors.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/db/DbErrors.scala index 9f24a611..94011020 100644 --- a/core/src/main/scala/akka/persistence/postgres/db/DbErrors.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/db/DbErrors.scala @@ -1,4 +1,4 @@ -package akka.persistence.postgres.db +package org.apache.pekko.persistence.postgres.db import java.sql.SQLException diff --git a/core/src/main/scala/akka/persistence/postgres/db/ExtendedPostgresProfile.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/db/ExtendedPostgresProfile.scala similarity index 96% rename from core/src/main/scala/akka/persistence/postgres/db/ExtendedPostgresProfile.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/db/ExtendedPostgresProfile.scala index 23e84eef..25fb41c0 100644 --- a/core/src/main/scala/akka/persistence/postgres/db/ExtendedPostgresProfile.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/db/ExtendedPostgresProfile.scala @@ -1,4 +1,4 @@ -package akka.persistence.postgres.db +package org.apache.pekko.persistence.postgres.db import com.github.tminglei.slickpg._ import slick.basic.Capability diff --git a/core/src/main/scala/akka/persistence/postgres/db/SlickDatabase.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/db/SlickDatabase.scala similarity index 94% rename from core/src/main/scala/akka/persistence/postgres/db/SlickDatabase.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/db/SlickDatabase.scala index e84993ba..e353a495 100644 --- a/core/src/main/scala/akka/persistence/postgres/db/SlickDatabase.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/db/SlickDatabase.scala @@ -3,11 +3,11 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.db +package org.apache.pekko.persistence.postgres.db -import akka.actor.ActorSystem +import org.apache.pekko.actor.ActorSystem import javax.naming.InitialContext -import akka.persistence.postgres.config.SlickConfiguration +import org.apache.pekko.persistence.postgres.config.SlickConfiguration import com.typesafe.config.Config import slick.basic.DatabaseConfig import slick.jdbc.JdbcProfile diff --git a/core/src/main/scala/akka/persistence/postgres/db/SlickExtension.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/db/SlickExtension.scala similarity index 75% rename from core/src/main/scala/akka/persistence/postgres/db/SlickExtension.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/db/SlickExtension.scala index b522bec2..1efa6f52 100644 --- a/core/src/main/scala/akka/persistence/postgres/db/SlickExtension.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/db/SlickExtension.scala @@ -3,11 +3,11 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.db +package org.apache.pekko.persistence.postgres.db -import akka.actor.{ ActorSystem, ExtendedActorSystem, Extension, ExtensionId, ExtensionIdProvider } -import akka.persistence.postgres.config.{ ConfigKeys, SlickConfiguration } -import akka.persistence.postgres.util.ConfigOps._ +import org.apache.pekko.actor.{ ActorSystem, ExtendedActorSystem, Extension, ExtensionId, ExtensionIdProvider } +import org.apache.pekko.persistence.postgres.config.{ ConfigKeys, SlickConfiguration } +import org.apache.pekko.persistence.postgres.util.ConfigOps._ import com.typesafe.config.{ Config, ConfigObject } import scala.jdk.CollectionConverters._ @@ -21,7 +21,7 @@ object SlickExtension extends ExtensionId[SlickExtensionImpl] with ExtensionIdPr class SlickExtensionImpl(system: ExtendedActorSystem) extends Extension { private val dbProvider: SlickDatabaseProvider = { - val fqcn = system.settings.config.getString("akka-persistence-postgres.database-provider-fqcn") + val fqcn = system.settings.config.getString("pekko-persistence-postgres.database-provider-fqcn") val args = List(classOf[ActorSystem] -> system) system.dynamicAccess.createInstanceFor[SlickDatabaseProvider](fqcn, args) match { case Success(result) => result @@ -34,12 +34,12 @@ class SlickExtensionImpl(system: ExtendedActorSystem) extends Extension { /** * User overridable database provider. - * Since this provider is called from an akka extension it must be thread safe! + * Since this provider is called from an pekko extension it must be thread safe! * * A SlickDatabaseProvider is loaded using reflection, * The instance is created using the following: * - The fully qualified class name as configured in `postgres-journal.database-provider-fqcn`. - * - The constructor with one argument of type [[akka.actor.ActorSystem]] is used to create the instance. + * - The constructor with one argument of type [[org.apache.pekko.actor.ActorSystem]] is used to create the instance. * Therefore the class must have such a constructor. */ trait SlickDatabaseProvider { @@ -54,7 +54,7 @@ trait SlickDatabaseProvider { class DefaultSlickDatabaseProvider(system: ActorSystem) extends SlickDatabaseProvider { val sharedDatabases: Map[String, LazySlickDatabase] = system.settings.config - .getObject("akka-persistence-postgres.shared-databases") + .getObject("pekko-persistence-postgres.shared-databases") .asScala .flatMap { case (key, confObj: ConfigObject) => @@ -65,7 +65,7 @@ class DefaultSlickDatabaseProvider(system: ActorSystem) extends SlickDatabasePro } else Nil case (key, notAnObject) => throw new RuntimeException( - s"""Expected "akka-persistence-postgres.shared-databases.$key" to be a config ConfigObject, but got ${notAnObject + s"""Expected "pekko-persistence-postgres.shared-databases.$key" to be a config ConfigObject, but got ${notAnObject .valueType()} (${notAnObject.getClass})""") } .toMap @@ -74,7 +74,7 @@ class DefaultSlickDatabaseProvider(system: ActorSystem) extends SlickDatabasePro sharedDatabases.getOrElse( sharedDbName, throw new RuntimeException( - s"No shared database is configured under akka-persistence-postgres.shared-databases.$sharedDbName")) + s"No shared database is configured under pekko-persistence-postgres.shared-databases.$sharedDbName")) def database(config: Config): SlickDatabase = { config.asOptionalNonEmptyString(ConfigKeys.useSharedDb) match { diff --git a/core/src/main/scala/akka/persistence/postgres/journal/PostgresAsyncWriteJournal.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/journal/PostgresAsyncWriteJournal.scala similarity index 84% rename from core/src/main/scala/akka/persistence/postgres/journal/PostgresAsyncWriteJournal.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/journal/PostgresAsyncWriteJournal.scala index 72d17c79..a58ae54a 100644 --- a/core/src/main/scala/akka/persistence/postgres/journal/PostgresAsyncWriteJournal.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/journal/PostgresAsyncWriteJournal.scala @@ -3,21 +3,21 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.journal +package org.apache.pekko.persistence.postgres.journal import java.util.{ HashMap => JHMap, Map => JMap } -import akka.Done -import akka.actor.{ ActorSystem, ExtendedActorSystem } -import akka.pattern.pipe -import akka.persistence.postgres.config.JournalConfig -import akka.persistence.postgres.db.{ SlickDatabase, SlickExtension } -import akka.persistence.postgres.journal.PostgresAsyncWriteJournal.{ InPlaceUpdateEvent, WriteFinished } -import akka.persistence.postgres.journal.dao.{ JournalDao, JournalDaoWithUpdates } -import akka.persistence.journal.AsyncWriteJournal -import akka.persistence.{ AtomicWrite, PersistentRepr } -import akka.serialization.{ Serialization, SerializationExtension } -import akka.stream.{ Materializer, SystemMaterializer } +import org.apache.pekko.Done +import org.apache.pekko.actor.{ ActorSystem, ExtendedActorSystem } +import org.apache.pekko.pattern.pipe +import org.apache.pekko.persistence.postgres.config.JournalConfig +import org.apache.pekko.persistence.postgres.db.{ SlickDatabase, SlickExtension } +import org.apache.pekko.persistence.postgres.journal.PostgresAsyncWriteJournal.{ InPlaceUpdateEvent, WriteFinished } +import org.apache.pekko.persistence.postgres.journal.dao.{ JournalDao, JournalDaoWithUpdates } +import org.apache.pekko.persistence.journal.AsyncWriteJournal +import org.apache.pekko.persistence.{ AtomicWrite, PersistentRepr } +import org.apache.pekko.serialization.{ Serialization, SerializationExtension } +import org.apache.pekko.stream.{ Materializer, SystemMaterializer } import com.typesafe.config.Config import slick.jdbc.JdbcBackend._ @@ -32,7 +32,7 @@ object PostgresAsyncWriteJournal { * Extra Plugin API: May be used to issue in-place updates for events. * To be used only for data migrations such as "encrypt all events" and similar operations. * - * The write payload may be wrapped in a [[akka.persistence.journal.Tagged]], + * The write payload may be wrapped in a [[org.apache.pekko.persistence.journal.Tagged]], * in which case the new tags will be skipped and the old tags remain unchanged. */ final case class InPlaceUpdateEvent(persistenceId: String, seqNr: Long, write: AnyRef) diff --git a/core/src/main/scala/akka/persistence/postgres/journal/dao/BaseByteArrayJournalDao.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/BaseByteArrayJournalDao.scala similarity index 89% rename from core/src/main/scala/akka/persistence/postgres/journal/dao/BaseByteArrayJournalDao.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/BaseByteArrayJournalDao.scala index 27b76493..f4c58d97 100644 --- a/core/src/main/scala/akka/persistence/postgres/journal/dao/BaseByteArrayJournalDao.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/BaseByteArrayJournalDao.scala @@ -3,17 +3,17 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres +package org.apache.pekko.persistence.postgres package journal.dao -import akka.actor.Scheduler -import akka.persistence.postgres.config.JournalConfig -import akka.persistence.postgres.serialization.FlowPersistentReprSerializer -import akka.persistence.postgres.tag.TagIdResolver -import akka.persistence.{ AtomicWrite, PersistentRepr } -import akka.stream.scaladsl.{ Keep, Sink, Source } -import akka.stream.{ Materializer, OverflowStrategy, QueueOfferResult } -import akka.{ Done, NotUsed } +import org.apache.pekko.actor.Scheduler +import org.apache.pekko.persistence.postgres.config.JournalConfig +import org.apache.pekko.persistence.postgres.serialization.FlowPersistentReprSerializer +import org.apache.pekko.persistence.postgres.tag.TagIdResolver +import org.apache.pekko.persistence.{ AtomicWrite, PersistentRepr } +import org.apache.pekko.stream.scaladsl.{ Keep, Sink, Source } +import org.apache.pekko.stream.{ Materializer, OverflowStrategy, QueueOfferResult } +import org.apache.pekko.{ Done, NotUsed } import org.slf4j.{ Logger, LoggerFactory } import slick.dbio.DBIOAction import slick.jdbc.JdbcBackend._ @@ -35,7 +35,7 @@ trait BaseByteArrayJournalDao extends JournalDaoWithUpdates with BaseJournalDaoW implicit val ec: ExecutionContext implicit val mat: Materializer - import akka.persistence.postgres.db.ExtendedPostgresProfile.api._ + import org.apache.pekko.persistence.postgres.db.ExtendedPostgresProfile.api._ import journalConfig.daoConfig.{ batchSize, bufferSize, logicalDelete, parallelism } val logger: Logger = LoggerFactory.getLogger(this.getClass) @@ -44,13 +44,13 @@ trait BaseByteArrayJournalDao extends JournalDaoWithUpdates with BaseJournalDaoW JournalMetadataTable(journalConfig.journalMetadataTableConfiguration)) // This logging may block since we don't control how the user will configure logback - // We can't use a Akka logging neither because we don't have an ActorSystem in scope and + // We can't use a Pekko logging neither because we don't have an ActorSystem in scope and // we should not introduce another dependency here. // Therefore, we make sure we only log a warning for logical deletes once lazy val logWarnAboutLogicalDeletionDeprecation: Unit = { logger.warn( "Logical deletion of events is deprecated and will be removed. " + - "To disable it in this current version you must set the property 'akka-persistence-postgres.logicalDeletion.enable' to false.") + "To disable it in this current version you must set the property 'pekko-persistence-postgres.logicalDeletion.enable' to false.") } private val writeQueue = Source @@ -87,7 +87,7 @@ trait BaseByteArrayJournalDao extends JournalDaoWithUpdates with BaseJournalDaoW } /** - * @see [[akka.persistence.journal.AsyncWriteJournal.asyncWriteMessages(messages)]] + * @see [[org.apache.pekko.persistence.journal.AsyncWriteJournal.asyncWriteMessages(messages)]] */ def asyncWriteMessages(messages: Seq[AtomicWrite]): Future[Seq[Try[Unit]]] = Future @@ -118,7 +118,7 @@ trait BaseByteArrayJournalDao extends JournalDaoWithUpdates with BaseJournalDaoW db.run(queries.markJournalMessagesAsDeleted(persistenceId, maxSequenceNr)).map(_ => ()) } else { // We should keep journal record with highest sequence number in order to be compliant - // with @see [[akka.persistence.journal.JournalSpec]] + // with @see [[org.apache.pekko.persistence.journal.JournalSpec]] val actions = for { _ <- queries.markJournalMessagesAsDeleted(persistenceId, maxSequenceNr) highestMarkedSequenceNr <- highestMarkedSequenceNr(persistenceId) @@ -216,7 +216,7 @@ trait BaseJournalDaoWithReadMessages extends JournalDaoWithReadMessages { case Continue => retrieveNextBatch() case ContinueDelayed => val (delay, scheduler) = refreshInterval.get - akka.pattern.after(delay, scheduler)(retrieveNextBatch()) + org.apache.pekko.pattern.after(delay, scheduler)(retrieveNextBatch()) } } .mapConcat(identity) diff --git a/core/src/main/scala/akka/persistence/postgres/journal/dao/ByteArrayJournalSerializer.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/ByteArrayJournalSerializer.scala similarity index 88% rename from core/src/main/scala/akka/persistence/postgres/journal/dao/ByteArrayJournalSerializer.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/ByteArrayJournalSerializer.scala index b521ff36..c1cd9a62 100644 --- a/core/src/main/scala/akka/persistence/postgres/journal/dao/ByteArrayJournalSerializer.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/ByteArrayJournalSerializer.scala @@ -3,14 +3,14 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres +package org.apache.pekko.persistence.postgres package journal.dao -import akka.persistence.PersistentRepr -import akka.persistence.postgres.journal.dao.ByteArrayJournalSerializer.Metadata -import akka.persistence.postgres.serialization.FlowPersistentReprSerializer -import akka.persistence.postgres.tag.TagIdResolver -import akka.serialization.{ Serialization, Serializers } +import org.apache.pekko.persistence.PersistentRepr +import org.apache.pekko.persistence.postgres.journal.dao.ByteArrayJournalSerializer.Metadata +import org.apache.pekko.persistence.postgres.serialization.FlowPersistentReprSerializer +import org.apache.pekko.persistence.postgres.tag.TagIdResolver +import org.apache.pekko.serialization.{ Serialization, Serializers } import io.circe.{ Decoder, Encoder } import scala.collection.immutable._ diff --git a/core/src/main/scala/akka/persistence/postgres/journal/dao/FlatJournalDao.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/FlatJournalDao.scala similarity index 68% rename from core/src/main/scala/akka/persistence/postgres/journal/dao/FlatJournalDao.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/FlatJournalDao.scala index 12feb4c1..51491977 100644 --- a/core/src/main/scala/akka/persistence/postgres/journal/dao/FlatJournalDao.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/FlatJournalDao.scala @@ -1,10 +1,10 @@ -package akka.persistence.postgres +package org.apache.pekko.persistence.postgres package journal.dao -import akka.persistence.postgres.config.JournalConfig -import akka.persistence.postgres.tag.{ CachedTagIdResolver, SimpleTagDao } -import akka.serialization.Serialization -import akka.stream.Materializer +import org.apache.pekko.persistence.postgres.config.JournalConfig +import org.apache.pekko.persistence.postgres.tag.{ CachedTagIdResolver, SimpleTagDao } +import org.apache.pekko.serialization.Serialization +import org.apache.pekko.stream.Materializer import slick.jdbc.JdbcBackend._ import scala.concurrent.ExecutionContext diff --git a/core/src/main/scala/akka/persistence/postgres/journal/dao/FlowControl.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/FlowControl.scala similarity index 91% rename from core/src/main/scala/akka/persistence/postgres/journal/dao/FlowControl.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/FlowControl.scala index 2579dbd0..b5d53455 100644 --- a/core/src/main/scala/akka/persistence/postgres/journal/dao/FlowControl.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/FlowControl.scala @@ -3,7 +3,7 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.journal.dao +package org.apache.pekko.persistence.postgres.journal.dao private[postgres] sealed trait FlowControl diff --git a/core/src/main/scala/akka/persistence/postgres/journal/dao/JournalDao.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/JournalDao.scala similarity index 80% rename from core/src/main/scala/akka/persistence/postgres/journal/dao/JournalDao.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/JournalDao.scala index 137efb08..bf6b24c3 100644 --- a/core/src/main/scala/akka/persistence/postgres/journal/dao/JournalDao.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/JournalDao.scala @@ -3,9 +3,9 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.journal.dao +package org.apache.pekko.persistence.postgres.journal.dao -import akka.persistence.AtomicWrite +import org.apache.pekko.persistence.AtomicWrite import scala.collection.immutable.Seq import scala.concurrent.Future import scala.util.Try @@ -24,7 +24,7 @@ trait JournalDao extends JournalDaoWithReadMessages { def highestSequenceNr(persistenceId: String, fromSequenceNr: Long): Future[Long] /** - * @see [[akka.persistence.journal.AsyncWriteJournal.asyncWriteMessages(messages)]] + * @see [[org.apache.pekko.persistence.journal.AsyncWriteJournal.asyncWriteMessages(messages)]] */ def asyncWriteMessages(messages: Seq[AtomicWrite]): Future[Seq[Try[Unit]]] } diff --git a/core/src/main/scala/akka/persistence/postgres/journal/dao/JournalDaoWithReadMessages.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/JournalDaoWithReadMessages.scala similarity index 82% rename from core/src/main/scala/akka/persistence/postgres/journal/dao/JournalDaoWithReadMessages.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/JournalDaoWithReadMessages.scala index c8cc1563..42b5e593 100644 --- a/core/src/main/scala/akka/persistence/postgres/journal/dao/JournalDaoWithReadMessages.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/JournalDaoWithReadMessages.scala @@ -3,15 +3,15 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.journal.dao +package org.apache.pekko.persistence.postgres.journal.dao import scala.concurrent.duration.FiniteDuration import scala.util.Try -import akka.NotUsed -import akka.actor.Scheduler -import akka.persistence.PersistentRepr -import akka.stream.scaladsl.Source +import org.apache.pekko.NotUsed +import org.apache.pekko.actor.Scheduler +import org.apache.pekko.persistence.PersistentRepr +import org.apache.pekko.stream.scaladsl.Source trait JournalDaoWithReadMessages { diff --git a/core/src/main/scala/akka/persistence/postgres/journal/dao/JournalDaoWithUpdates.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/JournalDaoWithUpdates.scala similarity index 87% rename from core/src/main/scala/akka/persistence/postgres/journal/dao/JournalDaoWithUpdates.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/JournalDaoWithUpdates.scala index 6d0b3780..a646d15e 100644 --- a/core/src/main/scala/akka/persistence/postgres/journal/dao/JournalDaoWithUpdates.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/JournalDaoWithUpdates.scala @@ -3,9 +3,9 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.journal.dao +package org.apache.pekko.persistence.postgres.journal.dao -import akka.Done +import org.apache.pekko.Done import scala.concurrent.Future diff --git a/core/src/main/scala/akka/persistence/postgres/journal/dao/JournalMetadataQueries.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/JournalMetadataQueries.scala similarity index 84% rename from core/src/main/scala/akka/persistence/postgres/journal/dao/JournalMetadataQueries.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/JournalMetadataQueries.scala index 9544c449..56091576 100644 --- a/core/src/main/scala/akka/persistence/postgres/journal/dao/JournalMetadataQueries.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/JournalMetadataQueries.scala @@ -1,9 +1,9 @@ -package akka.persistence.postgres.journal.dao +package org.apache.pekko.persistence.postgres.journal.dao import slick.lifted.TableQuery class JournalMetadataQueries(journalMetadataTable: TableQuery[JournalMetadataTable]) { - import akka.persistence.postgres.db.ExtendedPostgresProfile.api._ + import org.apache.pekko.persistence.postgres.db.ExtendedPostgresProfile.api._ private def _highestSequenceNrForPersistenceId(persistenceId: Rep[String]): Query[Rep[Long], Long, Seq] = { journalMetadataTable.filter(_.persistenceId === persistenceId).map(_.maxSequenceNumber).take(1) diff --git a/core/src/main/scala/akka/persistence/postgres/journal/dao/JournalQueries.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/JournalQueries.scala similarity index 96% rename from core/src/main/scala/akka/persistence/postgres/journal/dao/JournalQueries.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/JournalQueries.scala index 13e8e754..7f57890e 100644 --- a/core/src/main/scala/akka/persistence/postgres/journal/dao/JournalQueries.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/JournalQueries.scala @@ -3,7 +3,7 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres +package org.apache.pekko.persistence.postgres package journal.dao import io.circe.Json @@ -12,7 +12,7 @@ import slick.sql.FixedSqlAction class JournalQueries(journalTable: TableQuery[JournalTable]) { - import akka.persistence.postgres.db.ExtendedPostgresProfile.api._ + import org.apache.pekko.persistence.postgres.db.ExtendedPostgresProfile.api._ private val compiledJournalTable = Compiled(journalTable) diff --git a/core/src/main/scala/akka/persistence/postgres/journal/dao/JournalTables.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/JournalTables.scala similarity index 95% rename from core/src/main/scala/akka/persistence/postgres/journal/dao/JournalTables.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/JournalTables.scala index dc80cf79..583ea6e7 100644 --- a/core/src/main/scala/akka/persistence/postgres/journal/dao/JournalTables.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/JournalTables.scala @@ -3,11 +3,11 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres +package org.apache.pekko.persistence.postgres package journal.dao -import akka.persistence.postgres.config.{ JournalMetadataTableConfiguration, JournalTableConfiguration } -import akka.persistence.postgres.db.ExtendedPostgresProfile.api._ +import org.apache.pekko.persistence.postgres.config.{ JournalMetadataTableConfiguration, JournalTableConfiguration } +import org.apache.pekko.persistence.postgres.db.ExtendedPostgresProfile.api._ import io.circe.Json trait JournalTable extends Table[JournalRow] { diff --git a/core/src/main/scala/akka/persistence/postgres/journal/dao/NestedPartitionsJournalDao.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/NestedPartitionsJournalDao.scala similarity index 89% rename from core/src/main/scala/akka/persistence/postgres/journal/dao/NestedPartitionsJournalDao.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/NestedPartitionsJournalDao.scala index 30c34d66..6cb47aa0 100644 --- a/core/src/main/scala/akka/persistence/postgres/journal/dao/NestedPartitionsJournalDao.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/NestedPartitionsJournalDao.scala @@ -1,13 +1,13 @@ -package akka.persistence.postgres.journal.dao +package org.apache.pekko.persistence.postgres.journal.dao import java.util.concurrent.ConcurrentHashMap -import akka.persistence.postgres.JournalRow -import akka.persistence.postgres.config.JournalConfig -import akka.persistence.postgres.db.DbErrors.withHandledPartitionErrors -import akka.persistence.postgres.db.ExtendedPostgresProfile.api._ -import akka.serialization.Serialization -import akka.stream.Materializer +import org.apache.pekko.persistence.postgres.JournalRow +import org.apache.pekko.persistence.postgres.config.JournalConfig +import org.apache.pekko.persistence.postgres.db.DbErrors.withHandledPartitionErrors +import org.apache.pekko.persistence.postgres.db.ExtendedPostgresProfile.api._ +import org.apache.pekko.serialization.Serialization +import org.apache.pekko.stream.Materializer import slick.jdbc.JdbcBackend.Database import scala.collection.immutable.{ List, Nil, Seq } diff --git a/core/src/main/scala/akka/persistence/postgres/journal/dao/PartitionedJournalDao.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/PartitionedJournalDao.scala similarity index 88% rename from core/src/main/scala/akka/persistence/postgres/journal/dao/PartitionedJournalDao.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/PartitionedJournalDao.scala index a847073a..73a411fd 100644 --- a/core/src/main/scala/akka/persistence/postgres/journal/dao/PartitionedJournalDao.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/PartitionedJournalDao.scala @@ -1,13 +1,13 @@ -package akka.persistence.postgres.journal.dao +package org.apache.pekko.persistence.postgres.journal.dao -import akka.NotUsed -import akka.persistence.PersistentRepr -import akka.persistence.postgres.JournalRow -import akka.persistence.postgres.config.JournalConfig -import akka.persistence.postgres.db.DbErrors.{ withHandledIndexErrors, withHandledPartitionErrors } -import akka.serialization.Serialization -import akka.stream.Materializer -import akka.stream.scaladsl.Source +import org.apache.pekko.NotUsed +import org.apache.pekko.persistence.PersistentRepr +import org.apache.pekko.persistence.postgres.JournalRow +import org.apache.pekko.persistence.postgres.config.JournalConfig +import org.apache.pekko.persistence.postgres.db.DbErrors.{ withHandledIndexErrors, withHandledPartitionErrors } +import org.apache.pekko.serialization.Serialization +import org.apache.pekko.stream.Materializer +import org.apache.pekko.stream.scaladsl.Source import slick.jdbc.JdbcBackend.Database import java.util.concurrent.atomic.AtomicReference @@ -26,7 +26,7 @@ class PartitionedJournalDao(db: Database, journalConfig: JournalConfig, serializ private val schema = journalTableCfg.schemaName.map(_ + ".").getOrElse("") private val seqName = s"$schema${journalTableCfg.tableName}_${journalTableCfg.columnNames.ordering}_seq" - import akka.persistence.postgres.db.ExtendedPostgresProfile.api._ + import org.apache.pekko.persistence.postgres.db.ExtendedPostgresProfile.api._ override protected def writeJournalRows(xs: Seq[JournalRow]): Future[Unit] = xs match { diff --git a/core/src/main/scala/akka/persistence/postgres/journal/dao/package.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/package.scala similarity index 90% rename from core/src/main/scala/akka/persistence/postgres/journal/dao/package.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/package.scala index 84eacc3b..5209e949 100644 --- a/core/src/main/scala/akka/persistence/postgres/journal/dao/package.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/journal/dao/package.scala @@ -3,7 +3,7 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.journal +package org.apache.pekko.persistence.postgres.journal import scala.collection.immutable.Set diff --git a/core/src/main/scala/akka/persistence/postgres/package.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/package.scala similarity index 93% rename from core/src/main/scala/akka/persistence/postgres/package.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/package.scala index 145d8c9e..5a87a844 100644 --- a/core/src/main/scala/akka/persistence/postgres/package.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/package.scala @@ -3,7 +3,7 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence +package org.apache.pekko.persistence import io.circe.Json diff --git a/core/src/main/scala/akka/persistence/postgres/query/JournalSequenceActor.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/query/JournalSequenceActor.scala similarity index 94% rename from core/src/main/scala/akka/persistence/postgres/query/JournalSequenceActor.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/query/JournalSequenceActor.scala index ffa68afa..c0673e2e 100644 --- a/core/src/main/scala/akka/persistence/postgres/query/JournalSequenceActor.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/query/JournalSequenceActor.scala @@ -3,15 +3,15 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres +package org.apache.pekko.persistence.postgres package query -import akka.actor.{ Actor, ActorLogging, Props, Status, Timers } -import akka.persistence.postgres.query.dao.ReadJournalDao -import akka.pattern.pipe -import akka.persistence.postgres.config.JournalSequenceRetrievalConfig -import akka.stream.Materializer -import akka.stream.scaladsl.Sink +import org.apache.pekko.actor.{ Actor, ActorLogging, Props, Status, Timers } +import org.apache.pekko.persistence.postgres.query.dao.ReadJournalDao +import org.apache.pekko.pattern.pipe +import org.apache.pekko.persistence.postgres.config.JournalSequenceRetrievalConfig +import org.apache.pekko.stream.Materializer +import org.apache.pekko.stream.scaladsl.Sink import scala.collection.immutable.NumericRange import scala.concurrent.duration.FiniteDuration diff --git a/core/src/main/scala/akka/persistence/postgres/query/PostgresReadJournalProvider.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/query/PostgresReadJournalProvider.scala similarity index 75% rename from core/src/main/scala/akka/persistence/postgres/query/PostgresReadJournalProvider.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/query/PostgresReadJournalProvider.scala index 944d6d5c..0372e248 100644 --- a/core/src/main/scala/akka/persistence/postgres/query/PostgresReadJournalProvider.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/query/PostgresReadJournalProvider.scala @@ -3,10 +3,10 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.query +package org.apache.pekko.persistence.postgres.query -import akka.actor.ExtendedActorSystem -import akka.persistence.query.ReadJournalProvider +import org.apache.pekko.actor.ExtendedActorSystem +import org.apache.pekko.persistence.query.ReadJournalProvider import com.typesafe.config.Config class PostgresReadJournalProvider(system: ExtendedActorSystem, config: Config, configPath: String) diff --git a/core/src/main/scala/akka/persistence/postgres/query/dao/BaseByteArrayReadJournalDao.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/query/dao/BaseByteArrayReadJournalDao.scala similarity index 74% rename from core/src/main/scala/akka/persistence/postgres/query/dao/BaseByteArrayReadJournalDao.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/query/dao/BaseByteArrayReadJournalDao.scala index 0ee55c17..17a29c36 100644 --- a/core/src/main/scala/akka/persistence/postgres/query/dao/BaseByteArrayReadJournalDao.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/query/dao/BaseByteArrayReadJournalDao.scala @@ -3,22 +3,22 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres +package org.apache.pekko.persistence.postgres package query.dao -import akka.NotUsed -import akka.persistence.PersistentRepr -import akka.persistence.postgres.config.ReadJournalConfig -import akka.persistence.postgres.journal.dao.{ +import org.apache.pekko.NotUsed +import org.apache.pekko.persistence.PersistentRepr +import org.apache.pekko.persistence.postgres.config.ReadJournalConfig +import org.apache.pekko.persistence.postgres.journal.dao.{ BaseJournalDaoWithReadMessages, ByteArrayJournalSerializer, JournalMetadataTable } -import akka.persistence.postgres.serialization.FlowPersistentReprSerializer -import akka.persistence.postgres.tag.{ CachedTagIdResolver, SimpleTagDao, TagIdResolver } -import akka.serialization.Serialization -import akka.stream.Materializer -import akka.stream.scaladsl.Source +import org.apache.pekko.persistence.postgres.serialization.FlowPersistentReprSerializer +import org.apache.pekko.persistence.postgres.tag.{ CachedTagIdResolver, SimpleTagDao, TagIdResolver } +import org.apache.pekko.serialization.Serialization +import org.apache.pekko.stream.Materializer +import org.apache.pekko.stream.scaladsl.Source import slick.basic.DatabasePublisher import slick.jdbc.JdbcBackend._ @@ -33,7 +33,7 @@ trait BaseByteArrayReadJournalDao extends ReadJournalDao with BaseJournalDaoWith def tagIdResolver: TagIdResolver def readJournalConfig: ReadJournalConfig - import akka.persistence.postgres.db.ExtendedPostgresProfile.api._ + import org.apache.pekko.persistence.postgres.db.ExtendedPostgresProfile.api._ override def allPersistenceIdsSource(max: Long): Source[String, NotUsed] = Source.fromPublisher(db.stream(queries.allPersistenceIdsDistinct(max).result)) diff --git a/core/src/main/scala/akka/persistence/postgres/query/dao/FlatReadJournalDao.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/query/dao/FlatReadJournalDao.scala similarity index 62% rename from core/src/main/scala/akka/persistence/postgres/query/dao/FlatReadJournalDao.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/query/dao/FlatReadJournalDao.scala index 515cf423..21b3aba5 100644 --- a/core/src/main/scala/akka/persistence/postgres/query/dao/FlatReadJournalDao.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/query/dao/FlatReadJournalDao.scala @@ -1,10 +1,10 @@ -package akka.persistence.postgres.query.dao +package org.apache.pekko.persistence.postgres.query.dao -import akka.persistence.postgres.config.ReadJournalConfig -import akka.persistence.postgres.journal.dao.{ ByteArrayJournalSerializer, FlatJournalTable } -import akka.persistence.postgres.tag.{ CachedTagIdResolver, SimpleTagDao, TagIdResolver } -import akka.serialization.Serialization -import akka.stream.Materializer +import org.apache.pekko.persistence.postgres.config.ReadJournalConfig +import org.apache.pekko.persistence.postgres.journal.dao.{ ByteArrayJournalSerializer, FlatJournalTable } +import org.apache.pekko.persistence.postgres.tag.{ CachedTagIdResolver, SimpleTagDao, TagIdResolver } +import org.apache.pekko.serialization.Serialization +import org.apache.pekko.stream.Materializer import slick.jdbc.JdbcBackend.Database import scala.concurrent.ExecutionContext diff --git a/core/src/main/scala/akka/persistence/postgres/query/dao/PartitionedReadJournalDao.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/query/dao/PartitionedReadJournalDao.scala similarity index 78% rename from core/src/main/scala/akka/persistence/postgres/query/dao/PartitionedReadJournalDao.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/query/dao/PartitionedReadJournalDao.scala index 24438e44..7dd424da 100644 --- a/core/src/main/scala/akka/persistence/postgres/query/dao/PartitionedReadJournalDao.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/query/dao/PartitionedReadJournalDao.scala @@ -1,17 +1,17 @@ -package akka.persistence.postgres.query.dao +package org.apache.pekko.persistence.postgres.query.dao -import akka.NotUsed -import akka.persistence.PersistentRepr -import akka.persistence.postgres.config.ReadJournalConfig -import akka.persistence.postgres.journal.dao.{ +import org.apache.pekko.NotUsed +import org.apache.pekko.persistence.PersistentRepr +import org.apache.pekko.persistence.postgres.config.ReadJournalConfig +import org.apache.pekko.persistence.postgres.journal.dao.{ ByteArrayJournalSerializer, JournalMetadataTable, PartitionedJournalTable } -import akka.persistence.postgres.tag.{ CachedTagIdResolver, SimpleTagDao, TagIdResolver } -import akka.serialization.Serialization -import akka.stream.Materializer -import akka.stream.scaladsl.Source +import org.apache.pekko.persistence.postgres.tag.{ CachedTagIdResolver, SimpleTagDao, TagIdResolver } +import org.apache.pekko.serialization.Serialization +import org.apache.pekko.stream.Materializer +import org.apache.pekko.stream.scaladsl.Source import slick.jdbc.JdbcBackend.Database import scala.concurrent.ExecutionContext @@ -24,7 +24,7 @@ class PartitionedReadJournalDao( val tagIdResolver: TagIdResolver)(implicit val ec: ExecutionContext, val mat: Materializer) extends BaseByteArrayReadJournalDao { - import akka.persistence.postgres.db.ExtendedPostgresProfile.api._ + import org.apache.pekko.persistence.postgres.db.ExtendedPostgresProfile.api._ val queries = new ReadJournalQueries( PartitionedJournalTable(readJournalConfig.journalTableConfiguration), diff --git a/core/src/main/scala/akka/persistence/postgres/query/dao/ReadJournalDao.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/query/dao/ReadJournalDao.scala similarity index 82% rename from core/src/main/scala/akka/persistence/postgres/query/dao/ReadJournalDao.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/query/dao/ReadJournalDao.scala index 1b24de6d..9a6a43b9 100644 --- a/core/src/main/scala/akka/persistence/postgres/query/dao/ReadJournalDao.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/query/dao/ReadJournalDao.scala @@ -3,13 +3,13 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres +package org.apache.pekko.persistence.postgres package query.dao -import akka.NotUsed -import akka.persistence.PersistentRepr -import akka.persistence.postgres.journal.dao.JournalDaoWithReadMessages -import akka.stream.scaladsl.Source +import org.apache.pekko.NotUsed +import org.apache.pekko.persistence.PersistentRepr +import org.apache.pekko.persistence.postgres.journal.dao.JournalDaoWithReadMessages +import org.apache.pekko.stream.scaladsl.Source import scala.concurrent.Future import scala.util.Try diff --git a/core/src/main/scala/akka/persistence/postgres/query/dao/ReadJournalMetadataQueries.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/query/dao/ReadJournalMetadataQueries.scala similarity index 68% rename from core/src/main/scala/akka/persistence/postgres/query/dao/ReadJournalMetadataQueries.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/query/dao/ReadJournalMetadataQueries.scala index eceea435..0d89525f 100644 --- a/core/src/main/scala/akka/persistence/postgres/query/dao/ReadJournalMetadataQueries.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/query/dao/ReadJournalMetadataQueries.scala @@ -1,11 +1,11 @@ -package akka.persistence.postgres.query.dao +package org.apache.pekko.persistence.postgres.query.dao -import akka.persistence.postgres.journal.dao.JournalMetadataTable +import org.apache.pekko.persistence.postgres.journal.dao.JournalMetadataTable import slick.lifted.TableQuery class ReadJournalMetadataQueries(journalMetadataTable: TableQuery[JournalMetadataTable]) { - import akka.persistence.postgres.db.ExtendedPostgresProfile.api._ + import org.apache.pekko.persistence.postgres.db.ExtendedPostgresProfile.api._ private def _minAndMaxOrderingForPersistenceId( persistenceId: Rep[String]): Query[(Rep[Long], Rep[Long]), (Long, Long), Seq] = diff --git a/core/src/main/scala/akka/persistence/postgres/query/dao/ReadJournalQueries.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/query/dao/ReadJournalQueries.scala similarity index 92% rename from core/src/main/scala/akka/persistence/postgres/query/dao/ReadJournalQueries.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/query/dao/ReadJournalQueries.scala index f1752210..b3680f41 100644 --- a/core/src/main/scala/akka/persistence/postgres/query/dao/ReadJournalQueries.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/query/dao/ReadJournalQueries.scala @@ -3,14 +3,14 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres +package org.apache.pekko.persistence.postgres package query.dao -import akka.persistence.postgres.journal.dao.JournalTable +import org.apache.pekko.persistence.postgres.journal.dao.JournalTable import slick.lifted.TableQuery class ReadJournalQueries(journalTable: TableQuery[JournalTable], includeDeleted: Boolean) { - import akka.persistence.postgres.db.ExtendedPostgresProfile.api._ + import org.apache.pekko.persistence.postgres.db.ExtendedPostgresProfile.api._ private def _allPersistenceIdsDistinct(max: ConstColumn[Long]): Query[Rep[String], String, Seq] = baseTableQuery().map(_.persistenceId).distinct.take(max) diff --git a/core/src/main/scala/akka/persistence/postgres/query/javadsl/PostgresReadJournal.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/query/javadsl/PostgresReadJournal.scala similarity index 88% rename from core/src/main/scala/akka/persistence/postgres/query/javadsl/PostgresReadJournal.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/query/javadsl/PostgresReadJournal.scala index 8cc63381..57ab471d 100644 --- a/core/src/main/scala/akka/persistence/postgres/query/javadsl/PostgresReadJournal.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/query/javadsl/PostgresReadJournal.scala @@ -3,13 +3,13 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.query.javadsl +package org.apache.pekko.persistence.postgres.query.javadsl -import akka.NotUsed -import akka.persistence.postgres.query.scaladsl.{ PostgresReadJournal => ScalaPostgresReadJournal } -import akka.persistence.query.{ EventEnvelope, Offset } -import akka.persistence.query.javadsl._ -import akka.stream.javadsl.Source +import org.apache.pekko.NotUsed +import org.apache.pekko.persistence.postgres.query.scaladsl.{ PostgresReadJournal => ScalaPostgresReadJournal } +import org.apache.pekko.persistence.query.{ EventEnvelope, Offset } +import org.apache.pekko.persistence.query.javadsl._ +import org.apache.pekko.stream.javadsl.Source object PostgresReadJournal { final val Identifier = ScalaPostgresReadJournal.Identifier @@ -72,7 +72,7 @@ class PostgresReadJournal(journal: ScalaPostgresReadJournal) * The `EventEnvelope` also provides the `offset` that corresponds to the `ordering` column in * the Journal table. The `ordering` is a sequential id number that uniquely identifies the * position of each event, also across different `persistenceId`. The `Offset` type is - * `akka.persistence.query.Sequence` with the `ordering` as the offset value. This is the + * `org.apache.pekko.persistence.query.Sequence` with the `ordering` as the offset value. This is the * same `ordering` number as is used in the offset of the `eventsByTag` query. * * The returned event stream is ordered by `sequenceNr`. @@ -108,9 +108,9 @@ class PostgresReadJournal(journal: ScalaPostgresReadJournal) * The offset is exclusive, i.e. the event corresponding to the given `offset` parameter is not * included in the stream. * - * For akka-persistence-postgres the `offset` corresponds to the `ordering` column in the Journal table. + * For pekko-persistence-postgres the `offset` corresponds to the `ordering` column in the Journal table. * The `ordering` is a sequential id number that uniquely identifies the position of each event within - * the event stream. The `Offset` type is `akka.persistence.query.Sequence` with the `ordering` as the + * the event stream. The `Offset` type is `org.apache.pekko.persistence.query.Sequence` with the `ordering` as the * offset value. * * The returned event stream is ordered by `offset`. diff --git a/core/src/main/scala/akka/persistence/postgres/query/package.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/query/package.scala similarity index 64% rename from core/src/main/scala/akka/persistence/postgres/query/package.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/query/package.scala index 49ea293e..cc4ea206 100644 --- a/core/src/main/scala/akka/persistence/postgres/query/package.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/query/package.scala @@ -3,11 +3,11 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres +package org.apache.pekko.persistence.postgres -import akka.NotUsed -import akka.persistence.query._ -import akka.stream.scaladsl.Source +import org.apache.pekko.NotUsed +import org.apache.pekko.persistence.query._ +import org.apache.pekko.stream.scaladsl.Source import scala.language.implicitConversions package object query { @@ -17,7 +17,7 @@ package object query { case NoOffset => 0L case _ => throw new IllegalArgumentException( - "akka-persistence-postgres does not support " + that.getClass.getName + " offsets") + "pekko-persistence-postgres does not support " + that.getClass.getName + " offsets") } } } diff --git a/core/src/main/scala/akka/persistence/postgres/query/scaladsl/PostgresReadJournal.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/query/scaladsl/PostgresReadJournal.scala similarity index 89% rename from core/src/main/scala/akka/persistence/postgres/query/scaladsl/PostgresReadJournal.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/query/scaladsl/PostgresReadJournal.scala index f4d59601..482dce99 100644 --- a/core/src/main/scala/akka/persistence/postgres/query/scaladsl/PostgresReadJournal.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/query/scaladsl/PostgresReadJournal.scala @@ -3,24 +3,24 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.query +package org.apache.pekko.persistence.postgres.query package scaladsl -import akka.NotUsed -import akka.actor.{ ExtendedActorSystem, Scheduler } -import akka.persistence.postgres.config.ReadJournalConfig -import akka.persistence.postgres.db.SlickExtension -import akka.persistence.postgres.journal.dao.FlowControl -import akka.persistence.postgres.query.JournalSequenceActor.{ GetMaxOrderingId, MaxOrderingId } -import akka.persistence.postgres.query.dao.ReadJournalDao -import akka.persistence.postgres.tag.{ CachedTagIdResolver, SimpleTagDao, TagIdResolver } -import akka.persistence.query.scaladsl._ -import akka.persistence.query.{ EventEnvelope, Offset, Sequence } -import akka.persistence.{ Persistence, PersistentRepr } -import akka.serialization.{ Serialization, SerializationExtension } -import akka.stream.scaladsl.{ Sink, Source } -import akka.stream.{ Materializer, SystemMaterializer } -import akka.util.Timeout +import org.apache.pekko.NotUsed +import org.apache.pekko.actor.{ ExtendedActorSystem, Scheduler } +import org.apache.pekko.persistence.postgres.config.ReadJournalConfig +import org.apache.pekko.persistence.postgres.db.SlickExtension +import org.apache.pekko.persistence.postgres.journal.dao.FlowControl +import org.apache.pekko.persistence.postgres.query.JournalSequenceActor.{ GetMaxOrderingId, MaxOrderingId } +import org.apache.pekko.persistence.postgres.query.dao.ReadJournalDao +import org.apache.pekko.persistence.postgres.tag.{ CachedTagIdResolver, SimpleTagDao, TagIdResolver } +import org.apache.pekko.persistence.query.scaladsl._ +import org.apache.pekko.persistence.query.{ EventEnvelope, Offset, Sequence } +import org.apache.pekko.persistence.{ Persistence, PersistentRepr } +import org.apache.pekko.serialization.{ Serialization, SerializationExtension } +import org.apache.pekko.stream.scaladsl.{ Sink, Source } +import org.apache.pekko.stream.{ Materializer, SystemMaterializer } +import org.apache.pekko.util.Timeout import com.typesafe.config.Config import org.slf4j.LoggerFactory import slick.jdbc.JdbcBackend._ @@ -82,7 +82,7 @@ class PostgresReadJournal(config: Config, configPath: String)(implicit val syste // Started lazily to prevent the actor for querying the db if no eventsByTag queries are used private[query] lazy val journalSequenceActor = system.systemActorOf( JournalSequenceActor.props(readJournalDao, readJournalConfig.journalSequenceRetrievalConfiguration), - s"$configPath.akka-persistence-postgres-journal-sequence-actor") + s"$configPath.pekko-persistence-postgres-journal-sequence-actor") private val delaySource = Source.tick(readJournalConfig.refreshInterval, 0.seconds, 0).take(1) @@ -150,7 +150,7 @@ class PostgresReadJournal(config: Config, configPath: String)(implicit val syste * The `EventEnvelope` also provides the `offset` that corresponds to the `ordering` column in * the Journal table. The `ordering` is a sequential id number that uniquely identifies the * position of each event, also across different `persistenceId`. The `Offset` type is - * `akka.persistence.query.Sequence` with the `ordering` as the offset value. This is the + * `org.apache.pekko.persistence.query.Sequence` with the `ordering` as the offset value. This is the * same `ordering` number as is used in the offset of the `eventsByTag` query. * * The returned event stream is ordered by `sequenceNr`. @@ -227,7 +227,7 @@ class PostgresReadJournal(config: Config, configPath: String)(implicit val syste offset: Long, terminateAfterOffset: Option[Long]): Source[EventEnvelope, NotUsed] = { import FlowControl._ - import akka.pattern.ask + import org.apache.pekko.pattern.ask implicit val askTimeout: Timeout = Timeout(readJournalConfig.journalSequenceRetrievalConfiguration.askTimeout) val batchSize = readJournalConfig.maxBufferSize @@ -290,7 +290,7 @@ class PostgresReadJournal(config: Config, configPath: String)(implicit val syste case Stop => Future.successful(None) case Continue => retrieveNextBatch() case ContinueDelayed => - akka.pattern.after(readJournalConfig.refreshInterval, system.scheduler)(retrieveNextBatch()) + org.apache.pekko.pattern.after(readJournalConfig.refreshInterval, system.scheduler)(retrieveNextBatch()) } } .mapConcat(identity) @@ -312,9 +312,9 @@ class PostgresReadJournal(config: Config, configPath: String)(implicit val syste * The offset is exclusive, i.e. the event corresponding to the given `offset` parameter is not * included in the stream. * - * For akka-persistence-postgres the `offset` corresponds to the `ordering` column in the Journal table. + * For pekko-persistence-postgres the `offset` corresponds to the `ordering` column in the Journal table. * The `ordering` is a sequential id number that uniquely identifies the position of each event within - * the event stream. The `Offset` type is `akka.persistence.query.Sequence` with the `ordering` as the + * the event stream. The `Offset` type is `org.apache.pekko.persistence.query.Sequence` with the `ordering` as the * offset value. * * The returned event stream is ordered by `offset`. diff --git a/core/src/main/scala/akka/persistence/postgres/serialization/PersistentReprSerializer.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/serialization/PersistentReprSerializer.scala similarity index 81% rename from core/src/main/scala/akka/persistence/postgres/serialization/PersistentReprSerializer.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/serialization/PersistentReprSerializer.scala index 872c9afa..232596b9 100644 --- a/core/src/main/scala/akka/persistence/postgres/serialization/PersistentReprSerializer.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/serialization/PersistentReprSerializer.scala @@ -3,12 +3,12 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.serialization +package org.apache.pekko.persistence.postgres.serialization -import akka.NotUsed -import akka.persistence.journal.Tagged -import akka.persistence.{ AtomicWrite, PersistentRepr } -import akka.stream.scaladsl.Flow +import org.apache.pekko.NotUsed +import org.apache.pekko.persistence.journal.Tagged +import org.apache.pekko.persistence.{ AtomicWrite, PersistentRepr } +import org.apache.pekko.stream.scaladsl.Flow import scala.collection.immutable._ import scala.concurrent.{ ExecutionContext, Future } @@ -19,7 +19,7 @@ trait PersistentReprSerializer[T] { implicit def executionContext: ExecutionContext /** - * An akka.persistence.AtomicWrite contains a Sequence of events (with metadata, the PersistentRepr) + * An org.apache.pekko.persistence.AtomicWrite contains a Sequence of events (with metadata, the PersistentRepr) * that must all be persisted or all fail, what makes the operation atomic. The function converts * each AtomicWrite to a Future[Seq[T]]. * The Try denotes whether there was a problem with the AtomicWrite or not. diff --git a/core/src/main/scala/akka/persistence/postgres/serialization/SnapshotSerializer.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/serialization/SnapshotSerializer.scala similarity index 74% rename from core/src/main/scala/akka/persistence/postgres/serialization/SnapshotSerializer.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/serialization/SnapshotSerializer.scala index 3815cd65..6984e6f7 100644 --- a/core/src/main/scala/akka/persistence/postgres/serialization/SnapshotSerializer.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/serialization/SnapshotSerializer.scala @@ -3,9 +3,9 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.serialization +package org.apache.pekko.persistence.postgres.serialization -import akka.persistence.SnapshotMetadata +import org.apache.pekko.persistence.SnapshotMetadata import scala.util.Try diff --git a/core/src/main/scala/akka/persistence/postgres/snapshot/PostgresSnapshotStore.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/snapshot/PostgresSnapshotStore.scala similarity index 84% rename from core/src/main/scala/akka/persistence/postgres/snapshot/PostgresSnapshotStore.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/snapshot/PostgresSnapshotStore.scala index f2dcadc4..eee878cd 100644 --- a/core/src/main/scala/akka/persistence/postgres/snapshot/PostgresSnapshotStore.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/snapshot/PostgresSnapshotStore.scala @@ -3,16 +3,16 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.snapshot +package org.apache.pekko.persistence.postgres.snapshot -import akka.actor.{ ActorSystem, ExtendedActorSystem } -import akka.persistence.postgres.config.SnapshotConfig -import akka.persistence.postgres.db.{ SlickDatabase, SlickExtension } -import akka.persistence.postgres.snapshot.dao.SnapshotDao -import akka.persistence.snapshot.SnapshotStore -import akka.persistence.{ SelectedSnapshot, SnapshotMetadata, SnapshotSelectionCriteria } -import akka.serialization.{ Serialization, SerializationExtension } -import akka.stream.{ Materializer, SystemMaterializer } +import org.apache.pekko.actor.{ ActorSystem, ExtendedActorSystem } +import org.apache.pekko.persistence.postgres.config.SnapshotConfig +import org.apache.pekko.persistence.postgres.db.{ SlickDatabase, SlickExtension } +import org.apache.pekko.persistence.postgres.snapshot.dao.SnapshotDao +import org.apache.pekko.persistence.snapshot.SnapshotStore +import org.apache.pekko.persistence.{ SelectedSnapshot, SnapshotMetadata, SnapshotSelectionCriteria } +import org.apache.pekko.serialization.{ Serialization, SerializationExtension } +import org.apache.pekko.stream.{ Materializer, SystemMaterializer } import com.typesafe.config.Config import slick.jdbc.JdbcBackend._ diff --git a/core/src/main/scala/akka/persistence/postgres/snapshot/dao/ByteArraySnapshotDao.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/snapshot/dao/ByteArraySnapshotDao.scala similarity index 89% rename from core/src/main/scala/akka/persistence/postgres/snapshot/dao/ByteArraySnapshotDao.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/snapshot/dao/ByteArraySnapshotDao.scala index 551e13b1..7f0dc201 100644 --- a/core/src/main/scala/akka/persistence/postgres/snapshot/dao/ByteArraySnapshotDao.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/snapshot/dao/ByteArraySnapshotDao.scala @@ -3,13 +3,13 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.snapshot.dao +package org.apache.pekko.persistence.postgres.snapshot.dao -import akka.persistence.SnapshotMetadata -import akka.persistence.postgres.config.SnapshotConfig -import akka.persistence.postgres.snapshot.dao.SnapshotTables.SnapshotRow -import akka.serialization.Serialization -import akka.stream.Materializer +import org.apache.pekko.persistence.SnapshotMetadata +import org.apache.pekko.persistence.postgres.config.SnapshotConfig +import org.apache.pekko.persistence.postgres.snapshot.dao.SnapshotTables.SnapshotRow +import org.apache.pekko.serialization.Serialization +import org.apache.pekko.stream.Materializer import slick.jdbc.JdbcProfile import slick.jdbc.JdbcBackend @@ -20,7 +20,7 @@ class ByteArraySnapshotDao(db: JdbcBackend#Database, snapshotConfig: SnapshotCon implicit ec: ExecutionContext, val mat: Materializer) extends SnapshotDao { - import akka.persistence.postgres.db.ExtendedPostgresProfile.api._ + import org.apache.pekko.persistence.postgres.db.ExtendedPostgresProfile.api._ val queries = new SnapshotQueries(snapshotConfig.snapshotTableConfiguration) diff --git a/core/src/main/scala/akka/persistence/postgres/snapshot/dao/ByteArraySnapshotSerializer.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/snapshot/dao/ByteArraySnapshotSerializer.scala similarity index 80% rename from core/src/main/scala/akka/persistence/postgres/snapshot/dao/ByteArraySnapshotSerializer.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/snapshot/dao/ByteArraySnapshotSerializer.scala index 080ee84b..6f513ea4 100644 --- a/core/src/main/scala/akka/persistence/postgres/snapshot/dao/ByteArraySnapshotSerializer.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/snapshot/dao/ByteArraySnapshotSerializer.scala @@ -3,13 +3,13 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.snapshot.dao +package org.apache.pekko.persistence.postgres.snapshot.dao -import akka.persistence.SnapshotMetadata -import akka.persistence.postgres.serialization.SnapshotSerializer -import akka.persistence.postgres.snapshot.dao.ByteArraySnapshotSerializer.Metadata -import akka.persistence.postgres.snapshot.dao.SnapshotTables.SnapshotRow -import akka.serialization.{ Serialization, Serializers } +import org.apache.pekko.persistence.SnapshotMetadata +import org.apache.pekko.persistence.postgres.serialization.SnapshotSerializer +import org.apache.pekko.persistence.postgres.snapshot.dao.ByteArraySnapshotSerializer.Metadata +import org.apache.pekko.persistence.postgres.snapshot.dao.SnapshotTables.SnapshotRow +import org.apache.pekko.serialization.{ Serialization, Serializers } import io.circe.{ Decoder, Encoder } import scala.util.Try diff --git a/core/src/main/scala/akka/persistence/postgres/snapshot/dao/SnapshotDao.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/snapshot/dao/SnapshotDao.scala similarity index 91% rename from core/src/main/scala/akka/persistence/postgres/snapshot/dao/SnapshotDao.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/snapshot/dao/SnapshotDao.scala index 5501e44d..c5f576fa 100644 --- a/core/src/main/scala/akka/persistence/postgres/snapshot/dao/SnapshotDao.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/snapshot/dao/SnapshotDao.scala @@ -3,9 +3,9 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.snapshot.dao +package org.apache.pekko.persistence.postgres.snapshot.dao -import akka.persistence.SnapshotMetadata +import org.apache.pekko.persistence.SnapshotMetadata import scala.concurrent.Future diff --git a/core/src/main/scala/akka/persistence/postgres/snapshot/dao/SnapshotQueries.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/snapshot/dao/SnapshotQueries.scala similarity index 91% rename from core/src/main/scala/akka/persistence/postgres/snapshot/dao/SnapshotQueries.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/snapshot/dao/SnapshotQueries.scala index 022999c0..155b5f0e 100644 --- a/core/src/main/scala/akka/persistence/postgres/snapshot/dao/SnapshotQueries.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/snapshot/dao/SnapshotQueries.scala @@ -3,13 +3,13 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.snapshot.dao +package org.apache.pekko.persistence.postgres.snapshot.dao -import akka.persistence.postgres.config.SnapshotTableConfiguration -import akka.persistence.postgres.snapshot.dao.SnapshotTables.SnapshotRow +import org.apache.pekko.persistence.postgres.config.SnapshotTableConfiguration +import org.apache.pekko.persistence.postgres.snapshot.dao.SnapshotTables.SnapshotRow class SnapshotQueries(override val snapshotTableCfg: SnapshotTableConfiguration) extends SnapshotTables { - import akka.persistence.postgres.db.ExtendedPostgresProfile.api._ + import org.apache.pekko.persistence.postgres.db.ExtendedPostgresProfile.api._ private val SnapshotTableC = Compiled(SnapshotTable) diff --git a/core/src/main/scala/akka/persistence/postgres/snapshot/dao/SnapshotTables.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/snapshot/dao/SnapshotTables.scala similarity index 82% rename from core/src/main/scala/akka/persistence/postgres/snapshot/dao/SnapshotTables.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/snapshot/dao/SnapshotTables.scala index 141d1547..22355748 100644 --- a/core/src/main/scala/akka/persistence/postgres/snapshot/dao/SnapshotTables.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/snapshot/dao/SnapshotTables.scala @@ -3,10 +3,10 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.snapshot.dao +package org.apache.pekko.persistence.postgres.snapshot.dao -import akka.persistence.postgres.config.SnapshotTableConfiguration -import akka.persistence.postgres.snapshot.dao.SnapshotTables._ +import org.apache.pekko.persistence.postgres.config.SnapshotTableConfiguration +import org.apache.pekko.persistence.postgres.snapshot.dao.SnapshotTables._ import io.circe.Json object SnapshotTables { @@ -19,7 +19,7 @@ object SnapshotTables { } trait SnapshotTables { - import akka.persistence.postgres.db.ExtendedPostgresProfile.api._ + import org.apache.pekko.persistence.postgres.db.ExtendedPostgresProfile.api._ def snapshotTableCfg: SnapshotTableConfiguration diff --git a/core/src/main/scala/org/apache/pekko/persistence/postgres/tag/EventTag.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/tag/EventTag.scala new file mode 100644 index 00000000..e0f0d75e --- /dev/null +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/tag/EventTag.scala @@ -0,0 +1,3 @@ +package org.apache.pekko.persistence.postgres.tag + +case class EventTag(id: Int, name: String) diff --git a/core/src/main/scala/akka/persistence/postgres/tag/EventTagQueries.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/tag/EventTagQueries.scala similarity index 70% rename from core/src/main/scala/akka/persistence/postgres/tag/EventTagQueries.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/tag/EventTagQueries.scala index 433998f6..45114fa9 100644 --- a/core/src/main/scala/akka/persistence/postgres/tag/EventTagQueries.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/tag/EventTagQueries.scala @@ -1,10 +1,10 @@ -package akka.persistence.postgres.tag +package org.apache.pekko.persistence.postgres.tag -import akka.persistence.postgres.config.TagsTableConfiguration +import org.apache.pekko.persistence.postgres.config.TagsTableConfiguration class EventTagQueries(val tagsTableCfg: TagsTableConfiguration) extends TagTables { - import akka.persistence.postgres.db.ExtendedPostgresProfile.api._ + import org.apache.pekko.persistence.postgres.db.ExtendedPostgresProfile.api._ def add(xs: EventTag) = EventTagTable.returning(EventTagTable.map(_.id)) += xs diff --git a/core/src/main/scala/akka/persistence/postgres/tag/TagDao.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/tag/TagDao.scala similarity index 75% rename from core/src/main/scala/akka/persistence/postgres/tag/TagDao.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/tag/TagDao.scala index 49337d7e..705c18d4 100644 --- a/core/src/main/scala/akka/persistence/postgres/tag/TagDao.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/tag/TagDao.scala @@ -1,6 +1,6 @@ -package akka.persistence.postgres.tag +package org.apache.pekko.persistence.postgres.tag -import akka.persistence.postgres.config.TagsTableConfiguration +import org.apache.pekko.persistence.postgres.config.TagsTableConfiguration import slick.jdbc.JdbcBackend.Database import scala.concurrent.{ ExecutionContext, Future } @@ -13,7 +13,7 @@ trait TagDao { } class SimpleTagDao(db: Database, tagsTableCfg: TagsTableConfiguration)(implicit ec: ExecutionContext) extends TagDao { - import akka.persistence.postgres.db.ExtendedPostgresProfile.api._ + import org.apache.pekko.persistence.postgres.db.ExtendedPostgresProfile.api._ private val queries = new EventTagQueries(tagsTableCfg) diff --git a/core/src/main/scala/akka/persistence/postgres/tag/TagIdResolver.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/tag/TagIdResolver.scala similarity index 93% rename from core/src/main/scala/akka/persistence/postgres/tag/TagIdResolver.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/tag/TagIdResolver.scala index e0f1c5ab..8f7b4fbb 100644 --- a/core/src/main/scala/akka/persistence/postgres/tag/TagIdResolver.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/tag/TagIdResolver.scala @@ -1,6 +1,6 @@ -package akka.persistence.postgres.tag +package org.apache.pekko.persistence.postgres.tag -import akka.persistence.postgres.config.TagsConfig +import org.apache.pekko.persistence.postgres.config.TagsConfig import com.github.blemale.scaffeine.{ AsyncLoadingCache, Scaffeine } import scala.concurrent.{ ExecutionContext, Future } diff --git a/core/src/main/scala/akka/persistence/postgres/tag/TagTables.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/tag/TagTables.scala similarity index 76% rename from core/src/main/scala/akka/persistence/postgres/tag/TagTables.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/tag/TagTables.scala index 1c8fe7df..06d4e8a7 100644 --- a/core/src/main/scala/akka/persistence/postgres/tag/TagTables.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/tag/TagTables.scala @@ -1,10 +1,10 @@ -package akka.persistence.postgres.tag +package org.apache.pekko.persistence.postgres.tag -import akka.persistence.postgres.config.TagsTableConfiguration +import org.apache.pekko.persistence.postgres.config.TagsTableConfiguration trait TagTables { - import akka.persistence.postgres.db.ExtendedPostgresProfile.api._ + import org.apache.pekko.persistence.postgres.db.ExtendedPostgresProfile.api._ def tagsTableCfg: TagsTableConfiguration diff --git a/core/src/main/scala/akka/persistence/postgres/util/BlockingOps.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/util/BlockingOps.scala similarity index 92% rename from core/src/main/scala/akka/persistence/postgres/util/BlockingOps.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/util/BlockingOps.scala index 4d35fb6d..ec8d5fc6 100644 --- a/core/src/main/scala/akka/persistence/postgres/util/BlockingOps.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/util/BlockingOps.scala @@ -3,7 +3,7 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.util +package org.apache.pekko.persistence.postgres.util import scala.concurrent.duration.{ FiniteDuration, _ } import scala.concurrent.{ Await, Future } diff --git a/core/src/main/scala/akka/persistence/postgres/util/ByteArrayOps.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/util/ByteArrayOps.scala similarity index 90% rename from core/src/main/scala/akka/persistence/postgres/util/ByteArrayOps.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/util/ByteArrayOps.scala index 69bdd7ac..f02eb3bc 100644 --- a/core/src/main/scala/akka/persistence/postgres/util/ByteArrayOps.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/util/ByteArrayOps.scala @@ -3,7 +3,7 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.util +package org.apache.pekko.persistence.postgres.util import java.io.{ ByteArrayInputStream, InputStream } import java.util.Base64 diff --git a/core/src/main/scala/akka/persistence/postgres/util/ConfigOps.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/util/ConfigOps.scala similarity index 98% rename from core/src/main/scala/akka/persistence/postgres/util/ConfigOps.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/util/ConfigOps.scala index 88c87ee2..2ca2f7a0 100644 --- a/core/src/main/scala/akka/persistence/postgres/util/ConfigOps.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/util/ConfigOps.scala @@ -3,7 +3,7 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.util +package org.apache.pekko.persistence.postgres.util import java.util.Locale import java.util.concurrent.TimeUnit diff --git a/core/src/main/scala/akka/persistence/postgres/util/InputStreamOps.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/util/InputStreamOps.scala similarity index 94% rename from core/src/main/scala/akka/persistence/postgres/util/InputStreamOps.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/util/InputStreamOps.scala index 7e7e6f82..19b33b0a 100644 --- a/core/src/main/scala/akka/persistence/postgres/util/InputStreamOps.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/util/InputStreamOps.scala @@ -3,7 +3,7 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.util +package org.apache.pekko.persistence.postgres.util import java.io.{ ByteArrayOutputStream, InputStream } diff --git a/core/src/main/scala/akka/persistence/postgres/util/StringOps.scala b/core/src/main/scala/org/apache/pekko/persistence/postgres/util/StringOps.scala similarity index 86% rename from core/src/main/scala/akka/persistence/postgres/util/StringOps.scala rename to core/src/main/scala/org/apache/pekko/persistence/postgres/util/StringOps.scala index f2e99851..134d0521 100644 --- a/core/src/main/scala/akka/persistence/postgres/util/StringOps.scala +++ b/core/src/main/scala/org/apache/pekko/persistence/postgres/util/StringOps.scala @@ -3,7 +3,7 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.util +package org.apache.pekko.persistence.postgres.util import java.util.Base64 diff --git a/core/src/test/resources/general.conf b/core/src/test/resources/general.conf index 528e4826..3a0b8bb2 100644 --- a/core/src/test/resources/general.conf +++ b/core/src/test/resources/general.conf @@ -12,17 +12,17 @@ # See the License for the specific language governing permissions and # limitations under the License. -// This file contains the general settings which are shared in all akka-persistence-postgres tests +// This file contains the general settings which are shared in all pekko-persistence-postgres tests -akka { +pekko { stdout-loglevel = off // defaults to WARNING can be disabled with off. The stdout-loglevel is only in effect during system startup and shutdown log-dead-letters-during-shutdown = on loglevel = debug log-dead-letters = on log-config-on-start = off // Log the complete configuration at INFO level when the actor system is started - loggers = ["akka.event.slf4j.Slf4jLogger"] - logging-filter = "akka.event.slf4j.Slf4jLoggingFilter" + loggers = ["org.apache.pekko.event.slf4j.Slf4jLogger"] + logging-filter = "org.apache.pekko.event.slf4j.Slf4jLoggingFilter" actor { allow-java-serialization = on @@ -42,23 +42,23 @@ docker { } postgres-journal { - logicalDelete = ${akka-persistence-postgres.logicalDeletion.enable} + logicalDelete = ${pekko-persistence-postgres.logicalDeletion.enable} event-adapters { - test-write-event-adapter = "akka.persistence.postgres.query.EventAdapterTest$TestWriteEventAdapter" - test-read-event-adapter = "akka.persistence.postgres.query.EventAdapterTest$TestReadEventAdapter" + test-write-event-adapter = "org.apache.pekko.persistence.postgres.query.EventAdapterTest$TestWriteEventAdapter" + test-read-event-adapter = "org.apache.pekko.persistence.postgres.query.EventAdapterTest$TestReadEventAdapter" } event-adapter-bindings { - "akka.persistence.postgres.query.EventAdapterTest$Event" = test-write-event-adapter - "akka.persistence.postgres.query.EventAdapterTest$TaggedEvent" = test-write-event-adapter - "akka.persistence.postgres.query.EventAdapterTest$TaggedAsyncEvent" = test-write-event-adapter - "akka.persistence.postgres.query.EventAdapterTest$EventAdapted" = test-read-event-adapter + "org.apache.pekko.persistence.postgres.query.EventAdapterTest$Event" = test-write-event-adapter + "org.apache.pekko.persistence.postgres.query.EventAdapterTest$TaggedEvent" = test-write-event-adapter + "org.apache.pekko.persistence.postgres.query.EventAdapterTest$TaggedAsyncEvent" = test-write-event-adapter + "org.apache.pekko.persistence.postgres.query.EventAdapterTest$EventAdapted" = test-read-event-adapter } } postgres-read-journal { - includeLogicallyDeleted = ${akka-persistence-postgres.logicalDeletion.enable} + includeLogicallyDeleted = ${pekko-persistence-postgres.logicalDeletion.enable} refresh-interval = "10ms" max-buffer-size = "500" } diff --git a/core/src/test/resources/jndi-application.conf b/core/src/test/resources/jndi-application.conf index 2af83def..87895f6b 100644 --- a/core/src/test/resources/jndi-application.conf +++ b/core/src/test/resources/jndi-application.conf @@ -12,10 +12,10 @@ # See the License for the specific language governing permissions and # limitations under the License. -// general.conf is included only for shared settings used for the akka-persistence-postgres tests +// general.conf is included only for shared settings used for the pekko-persistence-postgres tests include "general.conf" -akka { +pekko { persistence { journal { plugin = "postgres-journal" @@ -34,12 +34,12 @@ postgres-journal { slick = ${slick} } -# the akka-persistence-snapshot-store in use +# the pekko-persistence-snapshot-store in use postgres-snapshot-store { slick = ${slick} } -# the akka-persistence-query provider in use +# the pekko-persistence-query provider in use postgres-read-journal { slick = ${slick} } diff --git a/core/src/test/resources/jndi-shared-db-application.conf b/core/src/test/resources/jndi-shared-db-application.conf index 84741b46..7788a744 100644 --- a/core/src/test/resources/jndi-shared-db-application.conf +++ b/core/src/test/resources/jndi-shared-db-application.conf @@ -14,7 +14,7 @@ include "general.conf" -akka { +pekko { persistence { journal { plugin = "postgres-journal" @@ -29,7 +29,7 @@ akka { } } -akka-persistence-postgres { +pekko-persistence-postgres { shared-databases { slick { profile = "slick.jdbc.PostgresProfile$" @@ -42,12 +42,12 @@ postgres-journal { use-shared-db = "slick" } -# the akka-persistence-snapshot-store in use +# the pekko-persistence-snapshot-store in use postgres-snapshot-store { use-shared-db = "slick" } -# the akka-persistence-query provider in use +# the pekko-persistence-query provider in use postgres-read-journal { use-shared-db = "slick" } diff --git a/core/src/test/resources/logback-test.xml b/core/src/test/resources/logback-test.xml index 909f3ee7..e92249db 100644 --- a/core/src/test/resources/logback-test.xml +++ b/core/src/test/resources/logback-test.xml @@ -10,8 +10,8 @@ - - + + diff --git a/core/src/test/resources/nested-partitions-journal.conf b/core/src/test/resources/nested-partitions-journal.conf index 87f01a8b..3150b51d 100644 --- a/core/src/test/resources/nested-partitions-journal.conf +++ b/core/src/test/resources/nested-partitions-journal.conf @@ -1,4 +1,4 @@ -postgres-journal.dao = "akka.persistence.postgres.journal.dao.NestedPartitionsJournalDao" +postgres-journal.dao = "org.apache.pekko.persistence.postgres.journal.dao.NestedPartitionsJournalDao" postgres-journal.tables.journal.partitions { size = 2000 } diff --git a/core/src/test/resources/partitioned-journal.conf b/core/src/test/resources/partitioned-journal.conf index 3ee01f50..53adca0a 100644 --- a/core/src/test/resources/partitioned-journal.conf +++ b/core/src/test/resources/partitioned-journal.conf @@ -1,4 +1,4 @@ -postgres-journal.dao = "akka.persistence.postgres.journal.dao.PartitionedJournalDao" +postgres-journal.dao = "org.apache.pekko.persistence.postgres.journal.dao.PartitionedJournalDao" postgres-journal.tables.journal.partitions { size = 2000 } diff --git a/core/src/test/resources/plain-application-with-hard-delete.conf b/core/src/test/resources/plain-application-with-hard-delete.conf index 7edb7660..f688e9bc 100644 --- a/core/src/test/resources/plain-application-with-hard-delete.conf +++ b/core/src/test/resources/plain-application-with-hard-delete.conf @@ -12,8 +12,8 @@ # See the License for the specific language governing permissions and # limitations under the License. -// general.conf is included only for shared settings used for the akka-persistence-postgres tests +// general.conf is included only for shared settings used for the pekko-persistence-postgres tests include "general.conf" include "plain-application.conf" -akka-persistence-postgres.logicalDeletion.enable = false +pekko-persistence-postgres.logicalDeletion.enable = false diff --git a/core/src/test/resources/plain-application.conf b/core/src/test/resources/plain-application.conf index b6eaf6df..d620c676 100644 --- a/core/src/test/resources/plain-application.conf +++ b/core/src/test/resources/plain-application.conf @@ -12,10 +12,10 @@ # See the License for the specific language governing permissions and # limitations under the License. -// general.conf is included only for shared settings used for the akka-persistence-postgres tests +// general.conf is included only for shared settings used for the pekko-persistence-postgres tests include "general.conf" -akka { +pekko { persistence { journal { plugin = "postgres-journal" @@ -34,18 +34,18 @@ postgres-journal { slick = ${slick} } -# the akka-persistence-snapshot-store in use +# the pekko-persistence-snapshot-store in use postgres-snapshot-store { slick = ${slick} } -# the akka-persistence-query provider in use +# the pekko-persistence-query provider in use postgres-read-journal { slick = ${slick} } slick { - profile = "akka.persistence.postgres.db.ExtendedPostgresProfile$" + profile = "org.apache.pekko.persistence.postgres.db.ExtendedPostgresProfile$" db { host = "localhost" host = ${?POSTGRES_HOST} diff --git a/core/src/test/resources/plain-shared-db-application.conf b/core/src/test/resources/plain-shared-db-application.conf index ad551e60..89ddc4c8 100644 --- a/core/src/test/resources/plain-shared-db-application.conf +++ b/core/src/test/resources/plain-shared-db-application.conf @@ -14,7 +14,7 @@ include "general.conf" -akka { +pekko { persistence { journal { plugin = "postgres-journal" @@ -29,14 +29,14 @@ akka { } } -akka-persistence-postgres { +pekko-persistence-postgres { shared-databases { slick { profile = "slick.jdbc.PostgresProfile$" db { host = "localhost" host = ${?POSTGRES_HOST} - url = "jdbc:postgresql://"${akka-persistence-postgres.shared-databases.slick.db.host}":5432/docker?reWriteBatchedInserts=true" + url = "jdbc:postgresql://"${pekko-persistence-postgres.shared-databases.slick.db.host}":5432/docker?reWriteBatchedInserts=true" user = "docker" user = ${?POSTGRES_USER} password = "docker" @@ -54,12 +54,12 @@ postgres-journal { use-shared-db = "slick" } -# the akka-persistence-snapshot-store in use +# the pekko-persistence-snapshot-store in use postgres-snapshot-store { use-shared-db = "slick" } -# the akka-persistence-query provider in use +# the pekko-persistence-query provider in use postgres-read-journal { use-shared-db = "slick" } diff --git a/core/src/test/scala/akka/persistence/postgres/SharedActorSystemTestSpec.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/SharedActorSystemTestSpec.scala similarity index 73% rename from core/src/test/scala/akka/persistence/postgres/SharedActorSystemTestSpec.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/SharedActorSystemTestSpec.scala index 41b346b9..51f8d7d2 100644 --- a/core/src/test/scala/akka/persistence/postgres/SharedActorSystemTestSpec.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/SharedActorSystemTestSpec.scala @@ -3,16 +3,16 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres - -import akka.actor.ActorSystem -import akka.persistence.postgres.config.{ JournalConfig, ReadJournalConfig } -import akka.persistence.postgres.db.SlickExtension -import akka.persistence.postgres.query.javadsl.PostgresReadJournal -import akka.persistence.postgres.util.DropCreate -import akka.serialization.SerializationExtension -import akka.stream.{ Materializer, SystemMaterializer } -import akka.util.Timeout +package org.apache.pekko.persistence.postgres + +import org.apache.pekko.actor.ActorSystem +import org.apache.pekko.persistence.postgres.config.{ JournalConfig, ReadJournalConfig } +import org.apache.pekko.persistence.postgres.db.SlickExtension +import org.apache.pekko.persistence.postgres.query.javadsl.PostgresReadJournal +import org.apache.pekko.persistence.postgres.util.DropCreate +import org.apache.pekko.serialization.SerializationExtension +import org.apache.pekko.stream.{ Materializer, SystemMaterializer } +import org.apache.pekko.util.Timeout import com.typesafe.config.{ Config, ConfigFactory, ConfigValue } import org.scalatest.BeforeAndAfterAll diff --git a/core/src/test/scala/akka/persistence/postgres/SimpleSpec.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/SimpleSpec.scala similarity index 80% rename from core/src/test/scala/akka/persistence/postgres/SimpleSpec.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/SimpleSpec.scala index 8ff20142..244206b4 100644 --- a/core/src/test/scala/akka/persistence/postgres/SimpleSpec.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/SimpleSpec.scala @@ -3,11 +3,11 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres +package org.apache.pekko.persistence.postgres -import akka.actor.{ ActorRef, ActorSystem } -import akka.persistence.postgres.util.ClasspathResources -import akka.testkit.TestProbe +import org.apache.pekko.actor.{ ActorRef, ActorSystem } +import org.apache.pekko.persistence.postgres.util.ClasspathResources +import org.apache.pekko.testkit.TestProbe import org.scalatest._ import org.scalatest.concurrent.{ Eventually, ScalaFutures } import org.scalatest.flatspec.AnyFlatSpec diff --git a/core/src/test/scala/akka/persistence/postgres/SingleActorSystemPerTestSpec.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/SingleActorSystemPerTestSpec.scala similarity index 77% rename from core/src/test/scala/akka/persistence/postgres/SingleActorSystemPerTestSpec.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/SingleActorSystemPerTestSpec.scala index 2232cd9a..6695c678 100644 --- a/core/src/test/scala/akka/persistence/postgres/SingleActorSystemPerTestSpec.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/SingleActorSystemPerTestSpec.scala @@ -3,14 +3,14 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres +package org.apache.pekko.persistence.postgres -import akka.actor.ActorSystem -import akka.persistence.postgres.config.{ JournalConfig, ReadJournalConfig, SlickConfiguration } -import akka.persistence.postgres.db.SlickDatabase -import akka.persistence.postgres.query.javadsl.PostgresReadJournal -import akka.persistence.postgres.util.DropCreate -import akka.util.Timeout +import org.apache.pekko.actor.ActorSystem +import org.apache.pekko.persistence.postgres.config.{ JournalConfig, ReadJournalConfig, SlickConfiguration } +import org.apache.pekko.persistence.postgres.db.SlickDatabase +import org.apache.pekko.persistence.postgres.query.javadsl.PostgresReadJournal +import org.apache.pekko.persistence.postgres.util.DropCreate +import org.apache.pekko.util.Timeout import com.typesafe.config.{ Config, ConfigFactory, ConfigValue } import org.scalatest.BeforeAndAfterEach import slick.jdbc.JdbcBackend.Database @@ -42,8 +42,8 @@ abstract class SingleActorSystemPerTestSpec(val config: Config) } else SlickDatabase.database( config, - new SlickConfiguration(config.getConfig("akka-persistence-postgres.shared-databases.slick")), - "akka-persistence-postgres.shared-databases.slick.db") + new SlickConfiguration(config.getConfig("pekko-persistence-postgres.shared-databases.slick")), + "pekko-persistence-postgres.shared-databases.slick.db") dbOpt = Some(newDb) newDb diff --git a/core/src/test/scala/akka/persistence/postgres/TablesTestSpec.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/TablesTestSpec.scala similarity index 91% rename from core/src/test/scala/akka/persistence/postgres/TablesTestSpec.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/TablesTestSpec.scala index 8d24dd32..b95e2e23 100644 --- a/core/src/test/scala/akka/persistence/postgres/TablesTestSpec.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/TablesTestSpec.scala @@ -3,9 +3,9 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres +package org.apache.pekko.persistence.postgres -import akka.persistence.postgres.config._ +import org.apache.pekko.persistence.postgres.config._ import com.typesafe.config.ConfigFactory import org.scalatest.flatspec.AnyFlatSpec import org.scalatest.matchers.should.Matchers @@ -15,7 +15,7 @@ abstract class TablesTestSpec extends AnyFlatSpec with Matchers { val config = ConfigFactory.parseString(""" |postgres-journal { - | class = "akka.persistence.postgres.journal.PostgresAsyncWriteJournal" + | class = "org.apache.pekko.persistence.postgres.journal.PostgresAsyncWriteJournal" | | tables { | journal { @@ -42,7 +42,7 @@ abstract class TablesTestSpec extends AnyFlatSpec with Matchers { | | serialization = on // alter only when using a custom dao | - | dao = "akka.persistence.postgres.dao.bytea.FlatJournalDao" + | dao = "org.apache.pekko.persistence.postgres.dao.bytea.FlatJournalDao" | | slick { | profile = "slick.jdbc.PostgresProfile" @@ -53,7 +53,7 @@ abstract class TablesTestSpec extends AnyFlatSpec with Matchers { | port = ${?POSTGRES_PORT} | name = "docker" | - | url = "jdbc:postgresql://"${akka-persistence-postgres.slick.db.host}":"${akka-persistence-postgres.slick.db.port}"/"${akka-persistence-postgres.slick.db.name} + | url = "jdbc:postgresql://"${pekko-persistence-postgres.slick.db.host}":"${pekko-persistence-postgres.slick.db.port}"/"${pekko-persistence-postgres.slick.db.name} | user = "docker" | password = "docker" | driver = "org.postgresql.Driver" @@ -83,9 +83,9 @@ abstract class TablesTestSpec extends AnyFlatSpec with Matchers { | } |} | - |# the akka-persistence-snapshot-store in use + |# the pekko-persistence-snapshot-store in use |postgres-snapshot-store { - | class = "akka.persistence.postgres.snapshot.PostgresSnapshotStore" + | class = "org.apache.pekko.persistence.postgres.snapshot.PostgresSnapshotStore" | | tables { | snapshot { @@ -102,7 +102,7 @@ abstract class TablesTestSpec extends AnyFlatSpec with Matchers { | | serialization = on // alter only when using a custom dao | - | dao = "akka.persistence.postgres.dao.bytea.ByteArraySnapshotDao" + | dao = "org.apache.pekko.persistence.postgres.dao.bytea.ByteArraySnapshotDao" | | slick { | profile = "slick.jdbc.PostgresProfile" @@ -113,7 +113,7 @@ abstract class TablesTestSpec extends AnyFlatSpec with Matchers { | port = ${?POSTGRES_PORT} | name = "docker" | - | url = "jdbc:postgresql://"${akka-persistence-postgres.slick.db.host}":"${akka-persistence-postgres.slick.db.port}"/"${akka-persistence-postgres.slick.db.name} + | url = "jdbc:postgresql://"${pekko-persistence-postgres.slick.db.host}":"${pekko-persistence-postgres.slick.db.port}"/"${pekko-persistence-postgres.slick.db.name} | user = "docker" | password = "docker" | driver = "org.postgresql.Driver" @@ -143,9 +143,9 @@ abstract class TablesTestSpec extends AnyFlatSpec with Matchers { | } |} | - |# the akka-persistence-query provider in use + |# the pekko-persistence-query provider in use |postgres-read-journal { - | class = "akka.persistence.postgres.query.PostgresReadJournalProvider" + | class = "org.apache.pekko.persistence.postgres.query.PostgresReadJournalProvider" | | # New events are retrieved (polled) with this interval. | refresh-interval = "1s" @@ -156,7 +156,7 @@ abstract class TablesTestSpec extends AnyFlatSpec with Matchers { | | serialization = on // alter only when using a custom dao | - | dao = "akka.persistence.postgres.dao.bytea.FlatJournalDao" + | dao = "org.apache.pekko.persistence.postgres.dao.bytea.FlatJournalDao" | | tables { | journal { @@ -181,7 +181,7 @@ abstract class TablesTestSpec extends AnyFlatSpec with Matchers { | port = ${?POSTGRES_PORT} | name = "docker" | - | url = "jdbc:postgresql://"${akka-persistence-postgres.slick.db.host}":"${akka-persistence-postgres.slick.db.port}"/"${akka-persistence-postgres.slick.db.name} + | url = "jdbc:postgresql://"${pekko-persistence-postgres.slick.db.host}":"${pekko-persistence-postgres.slick.db.port}"/"${pekko-persistence-postgres.slick.db.name} | user = "docker" | password = "docker" | driver = "org.postgresql.Driver" diff --git a/core/src/test/scala/akka/persistence/postgres/configuration/ConfigOpsTest.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/configuration/ConfigOpsTest.scala similarity index 93% rename from core/src/test/scala/akka/persistence/postgres/configuration/ConfigOpsTest.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/configuration/ConfigOpsTest.scala index 8f8078b1..1ea0cf3f 100644 --- a/core/src/test/scala/akka/persistence/postgres/configuration/ConfigOpsTest.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/configuration/ConfigOpsTest.scala @@ -3,10 +3,10 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.configuration +package org.apache.pekko.persistence.postgres.configuration -import akka.persistence.postgres.SimpleSpec -import akka.persistence.postgres.util.ConfigOps +import org.apache.pekko.persistence.postgres.SimpleSpec +import org.apache.pekko.persistence.postgres.util.ConfigOps import ConfigOps._ import com.typesafe.config.ConfigFactory diff --git a/core/src/test/scala/akka/persistence/postgres/configuration/JNDIConfigTest.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/configuration/JNDIConfigTest.scala similarity index 89% rename from core/src/test/scala/akka/persistence/postgres/configuration/JNDIConfigTest.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/configuration/JNDIConfigTest.scala index 73816cbc..80ab20c7 100644 --- a/core/src/test/scala/akka/persistence/postgres/configuration/JNDIConfigTest.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/configuration/JNDIConfigTest.scala @@ -3,11 +3,11 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.configuration +package org.apache.pekko.persistence.postgres.configuration -import akka.actor.ActorSystem -import akka.persistence.postgres.SimpleSpec -import akka.persistence.postgres.db.SlickExtension +import org.apache.pekko.actor.ActorSystem +import org.apache.pekko.persistence.postgres.SimpleSpec +import org.apache.pekko.persistence.postgres.db.SlickExtension import com.typesafe.config.ConfigFactory class JNDIConfigTest extends SimpleSpec { diff --git a/core/src/test/scala/akka/persistence/postgres/configuration/AkkaPersistenceConfigTest.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/configuration/PekkoPersistenceConfigTest.scala similarity index 91% rename from core/src/test/scala/akka/persistence/postgres/configuration/AkkaPersistenceConfigTest.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/configuration/PekkoPersistenceConfigTest.scala index 269bf6c9..b5d2b4fe 100644 --- a/core/src/test/scala/akka/persistence/postgres/configuration/AkkaPersistenceConfigTest.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/configuration/PekkoPersistenceConfigTest.scala @@ -3,9 +3,9 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.configuration +package org.apache.pekko.persistence.postgres.configuration -import akka.persistence.postgres.config._ +import org.apache.pekko.persistence.postgres.config._ import com.typesafe.config.{ Config, ConfigFactory } import org.scalatest.OptionValues import org.scalatest.flatspec.AnyFlatSpec @@ -13,10 +13,10 @@ import org.scalatest.matchers.should.Matchers import scala.concurrent.duration._ -class AkkaPersistenceConfigTest extends AnyFlatSpec with Matchers with OptionValues { +class PekkoPersistenceConfigTest extends AnyFlatSpec with Matchers with OptionValues { val config: Config = ConfigFactory.parseString(""" |postgres-journal { - | class = "akka.persistence.postgres.journal.PostgresAsyncWriteJournal" + | class = "org.apache.pekko.persistence.postgres.journal.PostgresAsyncWriteJournal" | | tables { | journal { @@ -46,7 +46,7 @@ class AkkaPersistenceConfigTest extends AnyFlatSpec with Matchers with OptionVal | } | } | - | dao = "akka.persistence.postgres.journal.dao.FlatJournalDao" + | dao = "org.apache.pekko.persistence.postgres.journal.dao.FlatJournalDao" | | logicalDelete = true | @@ -64,7 +64,7 @@ class AkkaPersistenceConfigTest extends AnyFlatSpec with Matchers with OptionVal | port = ${?POSTGRES_PORT} | name = "docker" | - | url = "jdbc:postgresql://"${akka-persistence-postgres.slick.db.host}":"${akka-persistence-postgres.slick.db.port}"/"${akka-persistence-postgres.slick.db.name} + | url = "jdbc:postgresql://"${pekko-persistence-postgres.slick.db.host}":"${pekko-persistence-postgres.slick.db.port}"/"${pekko-persistence-postgres.slick.db.name} | user = "docker" | password = "docker" | driver = "org.postgresql.Driver$" @@ -94,9 +94,9 @@ class AkkaPersistenceConfigTest extends AnyFlatSpec with Matchers with OptionVal | } |} | - |# the akka-persistence-snapshot-store in use + |# the pekko-persistence-snapshot-store in use |postgres-snapshot-store { - | class = "akka.persistence.postgres.snapshot.PostgresSnapshotStore" + | class = "org.apache.pekko.persistence.postgres.snapshot.PostgresSnapshotStore" | | tables { | snapshot { @@ -111,7 +111,7 @@ class AkkaPersistenceConfigTest extends AnyFlatSpec with Matchers with OptionVal | } | } | - | dao = "akka.persistence.postgres.snapshot.dao.ByteArraySnapshotDao" + | dao = "org.apache.pekko.persistence.postgres.snapshot.dao.ByteArraySnapshotDao" | | slick { | profile = "slick.jdbc.MySQLProfile$" @@ -122,7 +122,7 @@ class AkkaPersistenceConfigTest extends AnyFlatSpec with Matchers with OptionVal | port = ${?POSTGRES_PORT} | name = "docker" | - | url = "jdbc:postgresql://"${akka-persistence-postgres.slick.db.host}":"${akka-persistence-postgres.slick.db.port}"/"${akka-persistence-postgres.slick.db.name} + | url = "jdbc:postgresql://"${pekko-persistence-postgres.slick.db.host}":"${pekko-persistence-postgres.slick.db.port}"/"${pekko-persistence-postgres.slick.db.name} | user = "docker" | password = "docker" | driver = "org.postgresql.Driver" @@ -152,9 +152,9 @@ class AkkaPersistenceConfigTest extends AnyFlatSpec with Matchers with OptionVal | } |} | - |# the akka-persistence-query provider in use + |# the pekko-persistence-query provider in use |postgres-read-journal { - | class = "akka.persistence.postgres.query.PostgresReadJournalProvider" + | class = "org.apache.pekko.persistence.postgres.query.PostgresReadJournalProvider" | | # New events are retrieved (polled) with this interval. | refresh-interval = "300ms" @@ -163,7 +163,7 @@ class AkkaPersistenceConfigTest extends AnyFlatSpec with Matchers with OptionVal | # are delivered downstreams. | max-buffer-size = "10" | - | dao = "akka.persistence.postgres.query.dao.FlatReadJournalDao" + | dao = "org.apache.pekko.persistence.postgres.query.dao.FlatReadJournalDao" | | tags { | cacheTtl = 12 hours @@ -201,7 +201,7 @@ class AkkaPersistenceConfigTest extends AnyFlatSpec with Matchers with OptionVal | port = ${?POSTGRES_PORT} | name = "docker" | - | url = "jdbc:postgresql://"${akka-persistence-postgres.slick.db.host}":"${akka-persistence-postgres.slick.db.port}"/"${akka-persistence-postgres.slick.db.name} + | url = "jdbc:postgresql://"${pekko-persistence-postgres.slick.db.host}":"${pekko-persistence-postgres.slick.db.port}"/"${pekko-persistence-postgres.slick.db.name} | user = "docker" | password = "docker" | driver = "org.postgresql.Driver" @@ -238,7 +238,7 @@ class AkkaPersistenceConfigTest extends AnyFlatSpec with Matchers with OptionVal slickConfiguration.jndiName shouldBe None slickConfiguration.jndiDbName shouldBe None - cfg.pluginConfig.dao shouldBe "akka.persistence.postgres.journal.dao.FlatJournalDao" + cfg.pluginConfig.dao shouldBe "org.apache.pekko.persistence.postgres.journal.dao.FlatJournalDao" cfg.journalTableConfiguration.tableName shouldBe "journal" cfg.journalTableConfiguration.schemaName shouldBe None @@ -267,7 +267,7 @@ class AkkaPersistenceConfigTest extends AnyFlatSpec with Matchers with OptionVal slickConfiguration.jndiName shouldBe None slickConfiguration.jndiDbName shouldBe None - cfg.pluginConfig.dao shouldBe "akka.persistence.postgres.snapshot.dao.ByteArraySnapshotDao" + cfg.pluginConfig.dao shouldBe "org.apache.pekko.persistence.postgres.snapshot.dao.ByteArraySnapshotDao" cfg.snapshotTableConfiguration.tableName shouldBe "snapshot" cfg.snapshotTableConfiguration.schemaName shouldBe None @@ -284,7 +284,7 @@ class AkkaPersistenceConfigTest extends AnyFlatSpec with Matchers with OptionVal slickConfiguration.jndiName shouldBe None slickConfiguration.jndiDbName shouldBe None - cfg.pluginConfig.dao shouldBe "akka.persistence.postgres.query.dao.FlatReadJournalDao" + cfg.pluginConfig.dao shouldBe "org.apache.pekko.persistence.postgres.query.dao.FlatReadJournalDao" cfg.refreshInterval shouldBe 1.second cfg.maxBufferSize shouldBe 500 @@ -313,7 +313,7 @@ class AkkaPersistenceConfigTest extends AnyFlatSpec with Matchers with OptionVal slickConfiguration.jndiName shouldBe None slickConfiguration.jndiDbName shouldBe None - cfg.pluginConfig.dao shouldBe "akka.persistence.postgres.journal.dao.FlatJournalDao" + cfg.pluginConfig.dao shouldBe "org.apache.pekko.persistence.postgres.journal.dao.FlatJournalDao" cfg.journalTableConfiguration.tableName shouldBe "journal" cfg.journalTableConfiguration.schemaName shouldBe None @@ -343,7 +343,7 @@ class AkkaPersistenceConfigTest extends AnyFlatSpec with Matchers with OptionVal slickConfiguration.jndiName shouldBe None slickConfiguration.jndiDbName shouldBe None - cfg.pluginConfig.dao shouldBe "akka.persistence.postgres.snapshot.dao.ByteArraySnapshotDao" + cfg.pluginConfig.dao shouldBe "org.apache.pekko.persistence.postgres.snapshot.dao.ByteArraySnapshotDao" cfg.snapshotTableConfiguration.tableName shouldBe "snapshot" cfg.snapshotTableConfiguration.schemaName shouldBe None @@ -360,7 +360,7 @@ class AkkaPersistenceConfigTest extends AnyFlatSpec with Matchers with OptionVal slickConfiguration.jndiName shouldBe None slickConfiguration.jndiDbName shouldBe None - cfg.pluginConfig.dao shouldBe "akka.persistence.postgres.query.dao.FlatReadJournalDao" + cfg.pluginConfig.dao shouldBe "org.apache.pekko.persistence.postgres.query.dao.FlatReadJournalDao" cfg.refreshInterval shouldBe 300.millis cfg.maxBufferSize shouldBe 10 diff --git a/core/src/test/scala/akka/persistence/postgres/journal/JournalPartitioningSpec.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/journal/JournalPartitioningSpec.scala similarity index 90% rename from core/src/test/scala/akka/persistence/postgres/journal/JournalPartitioningSpec.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/journal/JournalPartitioningSpec.scala index 9a89e18d..753b1250 100644 --- a/core/src/test/scala/akka/persistence/postgres/journal/JournalPartitioningSpec.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/journal/JournalPartitioningSpec.scala @@ -1,16 +1,16 @@ -package akka.persistence.postgres.journal +package org.apache.pekko.persistence.postgres.journal import java.util.UUID -import akka.actor.{ Actor, ActorRef, ActorSystem } -import akka.persistence.JournalProtocol._ -import akka.persistence.postgres.config._ -import akka.persistence.postgres.db.SlickExtension -import akka.persistence.postgres.journal.JournalPartitioningSpec.HugeBatchSmallPartitionConfig -import akka.persistence.postgres.util.Schema._ -import akka.persistence.postgres.util.{ ClasspathResources, DropCreate } -import akka.persistence.{ AtomicWrite, Persistence, PersistentImpl, PersistentRepr } -import akka.testkit.TestProbe +import org.apache.pekko.actor.{ Actor, ActorRef, ActorSystem } +import org.apache.pekko.persistence.JournalProtocol._ +import org.apache.pekko.persistence.postgres.config._ +import org.apache.pekko.persistence.postgres.db.SlickExtension +import org.apache.pekko.persistence.postgres.journal.JournalPartitioningSpec.HugeBatchSmallPartitionConfig +import org.apache.pekko.persistence.postgres.util.Schema._ +import org.apache.pekko.persistence.postgres.util.{ ClasspathResources, DropCreate } +import org.apache.pekko.persistence.{ AtomicWrite, Persistence, PersistentImpl, PersistentRepr } +import org.apache.pekko.testkit.TestProbe import com.typesafe.config.{ Config, ConfigFactory } import org.scalatest.concurrent.ScalaFutures import org.scalatest.matchers.should.Matchers @@ -55,7 +55,7 @@ abstract class JournalPartitioningSpec(schemaType: SchemaType) lazy val db = SlickExtension(system).database(cfg).database def withFreshSchemaAndPlugin(f: (ActorRef, String) => Unit): Unit = { - import akka.testkit._ + import org.apache.pekko.testkit._ dropCreate(schemaType) implicit val system: ActorSystem = ActorSystem("JournalPartitioningSpec", config) val journal = Persistence(system).journalFor(null) diff --git a/core/src/test/scala/akka/persistence/postgres/journal/PostgresJournalPerfSpec.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/journal/PostgresJournalPerfSpec.scala similarity index 88% rename from core/src/test/scala/akka/persistence/postgres/journal/PostgresJournalPerfSpec.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/journal/PostgresJournalPerfSpec.scala index c7d8d2c7..3a646b9c 100644 --- a/core/src/test/scala/akka/persistence/postgres/journal/PostgresJournalPerfSpec.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/journal/PostgresJournalPerfSpec.scala @@ -3,17 +3,17 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.journal - -import akka.actor.Props -import akka.persistence.CapabilityFlag -import akka.persistence.journal.JournalPerfSpec -import akka.persistence.journal.JournalPerfSpec.{ BenchActor, Cmd, ResetCounter } -import akka.persistence.postgres.config._ -import akka.persistence.postgres.db.SlickExtension -import akka.persistence.postgres.util.Schema._ -import akka.persistence.postgres.util.{ ClasspathResources, DropCreate } -import akka.testkit.TestProbe +package org.apache.pekko.persistence.postgres.journal + +import org.apache.pekko.actor.Props +import org.apache.pekko.persistence.CapabilityFlag +import org.apache.pekko.persistence.journal.JournalPerfSpec +import org.apache.pekko.persistence.journal.JournalPerfSpec.{ BenchActor, Cmd, ResetCounter } +import org.apache.pekko.persistence.postgres.config._ +import org.apache.pekko.persistence.postgres.db.SlickExtension +import org.apache.pekko.persistence.postgres.util.Schema._ +import org.apache.pekko.persistence.postgres.util.{ ClasspathResources, DropCreate } +import org.apache.pekko.testkit.TestProbe import com.typesafe.config.ConfigFactory import org.scalatest.concurrent.ScalaFutures import org.scalatest.{ BeforeAndAfterAll, BeforeAndAfterEach } diff --git a/core/src/test/scala/akka/persistence/postgres/journal/PostgresJournalSpec.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/journal/PostgresJournalSpec.scala similarity index 90% rename from core/src/test/scala/akka/persistence/postgres/journal/PostgresJournalSpec.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/journal/PostgresJournalSpec.scala index f436e48b..e0dd7fe2 100644 --- a/core/src/test/scala/akka/persistence/postgres/journal/PostgresJournalSpec.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/journal/PostgresJournalSpec.scala @@ -3,20 +3,20 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.journal - -import akka.actor.{ Actor, ActorRef } -import akka.persistence.JournalProtocol.{ ReplayedMessage, WriteMessages, WriteMessagesFailed, WriteMessagesSuccessful } -import akka.persistence.journal.JournalSpec -import akka.persistence.postgres.config._ -import akka.persistence.postgres.db.SlickExtension -import akka.persistence.postgres.journal.dao.JournalMetadataTable -import akka.persistence.postgres.query.ScalaPostgresReadJournalOperations -import akka.persistence.postgres.util.Schema._ -import akka.persistence.postgres.util.{ ClasspathResources, DropCreate } -import akka.persistence.query.Sequence -import akka.persistence.{ AtomicWrite, CapabilityFlag, PersistentImpl, PersistentRepr } -import akka.testkit.TestProbe +package org.apache.pekko.persistence.postgres.journal + +import org.apache.pekko.actor.{ Actor, ActorRef } +import org.apache.pekko.persistence.JournalProtocol.{ ReplayedMessage, WriteMessages, WriteMessagesFailed, WriteMessagesSuccessful } +import org.apache.pekko.persistence.journal.JournalSpec +import org.apache.pekko.persistence.postgres.config._ +import org.apache.pekko.persistence.postgres.db.SlickExtension +import org.apache.pekko.persistence.postgres.journal.dao.JournalMetadataTable +import org.apache.pekko.persistence.postgres.query.ScalaPostgresReadJournalOperations +import org.apache.pekko.persistence.postgres.util.Schema._ +import org.apache.pekko.persistence.postgres.util.{ ClasspathResources, DropCreate } +import org.apache.pekko.persistence.query.Sequence +import org.apache.pekko.persistence.{ AtomicWrite, CapabilityFlag, PersistentImpl, PersistentRepr } +import org.apache.pekko.testkit.TestProbe import com.typesafe.config.{ Config, ConfigFactory } import org.scalatest.concurrent.PatienceConfiguration.Timeout import org.scalatest.concurrent.ScalaFutures @@ -94,7 +94,7 @@ abstract class PostgresJournalSpec(config: String, schemaType: SchemaType) } "An insert on the journal" must { - import akka.persistence.postgres.db.ExtendedPostgresProfile.api._ + import org.apache.pekko.persistence.postgres.db.ExtendedPostgresProfile.api._ val metadataTable = JournalMetadataTable(journalConfig.journalMetadataTableConfiguration) val UNSET_MIN_ORDERING = -1 diff --git a/core/src/test/scala/akka/persistence/postgres/journal/dao/ByteArrayJournalSerializerTest.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/journal/dao/ByteArrayJournalSerializerTest.scala similarity index 95% rename from core/src/test/scala/akka/persistence/postgres/journal/dao/ByteArrayJournalSerializerTest.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/journal/dao/ByteArrayJournalSerializerTest.scala index 1b052e53..b2c714b0 100644 --- a/core/src/test/scala/akka/persistence/postgres/journal/dao/ByteArrayJournalSerializerTest.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/journal/dao/ByteArrayJournalSerializerTest.scala @@ -3,18 +3,18 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres +package org.apache.pekko.persistence.postgres package journal.dao import java.nio.charset.Charset import java.time.{ LocalDateTime, ZoneOffset } import java.util.UUID -import akka.persistence.journal.Tagged -import akka.persistence.postgres.journal.dao.FakeTagIdResolver.unwanted1 -import akka.persistence.postgres.tag.TagIdResolver -import akka.persistence.{ AtomicWrite, PersistentRepr } -import akka.serialization.{ Serializer, Serializers } +import org.apache.pekko.persistence.journal.Tagged +import org.apache.pekko.persistence.postgres.journal.dao.FakeTagIdResolver.unwanted1 +import org.apache.pekko.persistence.postgres.tag.TagIdResolver +import org.apache.pekko.persistence.{ AtomicWrite, PersistentRepr } +import org.apache.pekko.serialization.{ Serializer, Serializers } import io.circe.Json import org.scalatest.concurrent.ScalaFutures import org.scalatest.matchers.must.Matchers diff --git a/core/src/test/scala/akka/persistence/postgres/journal/dao/JournalMetadataQueriesTest.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/journal/dao/JournalMetadataQueriesTest.scala similarity index 87% rename from core/src/test/scala/akka/persistence/postgres/journal/dao/JournalMetadataQueriesTest.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/journal/dao/JournalMetadataQueriesTest.scala index 5c0c9378..876114ea 100644 --- a/core/src/test/scala/akka/persistence/postgres/journal/dao/JournalMetadataQueriesTest.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/journal/dao/JournalMetadataQueriesTest.scala @@ -1,6 +1,6 @@ -package akka.persistence.postgres.journal.dao +package org.apache.pekko.persistence.postgres.journal.dao -import akka.persistence.postgres.util.BaseQueryTest +import org.apache.pekko.persistence.postgres.util.BaseQueryTest class JournalMetadataQueriesTest extends BaseQueryTest { diff --git a/core/src/test/scala/akka/persistence/postgres/journal/dao/JournalQueriesTest.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/journal/dao/JournalQueriesTest.scala similarity index 94% rename from core/src/test/scala/akka/persistence/postgres/journal/dao/JournalQueriesTest.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/journal/dao/JournalQueriesTest.scala index 017df738..d6f37649 100644 --- a/core/src/test/scala/akka/persistence/postgres/journal/dao/JournalQueriesTest.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/journal/dao/JournalQueriesTest.scala @@ -1,7 +1,7 @@ -package akka.persistence.postgres.journal.dao +package org.apache.pekko.persistence.postgres.journal.dao -import akka.persistence.postgres.JournalRow -import akka.persistence.postgres.util.BaseQueryTest +import org.apache.pekko.persistence.postgres.JournalRow +import org.apache.pekko.persistence.postgres.util.BaseQueryTest import io.circe.{ Json, JsonObject } class JournalQueriesTest extends BaseQueryTest { diff --git a/core/src/test/scala/akka/persistence/postgres/journal/dao/JournalTablesTest.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/journal/dao/JournalTablesTest.scala similarity index 95% rename from core/src/test/scala/akka/persistence/postgres/journal/dao/JournalTablesTest.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/journal/dao/JournalTablesTest.scala index d57ed78f..c3c968f5 100644 --- a/core/src/test/scala/akka/persistence/postgres/journal/dao/JournalTablesTest.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/journal/dao/JournalTablesTest.scala @@ -3,9 +3,9 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.journal.dao +package org.apache.pekko.persistence.postgres.journal.dao -import akka.persistence.postgres.TablesTestSpec +import org.apache.pekko.persistence.postgres.TablesTestSpec class JournalTablesTest extends TablesTestSpec { val journalTableConfiguration = journalConfig.journalTableConfiguration diff --git a/core/src/test/scala/akka/persistence/postgres/journal/dao/TagsSerializationTest.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/journal/dao/TagsSerializationTest.scala similarity index 90% rename from core/src/test/scala/akka/persistence/postgres/journal/dao/TagsSerializationTest.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/journal/dao/TagsSerializationTest.scala index fe0a4aac..34a8ac62 100644 --- a/core/src/test/scala/akka/persistence/postgres/journal/dao/TagsSerializationTest.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/journal/dao/TagsSerializationTest.scala @@ -3,9 +3,9 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.journal.dao +package org.apache.pekko.persistence.postgres.journal.dao -import akka.persistence.postgres.SharedActorSystemTestSpec +import org.apache.pekko.persistence.postgres.SharedActorSystemTestSpec class TagsSerializationTest extends SharedActorSystemTestSpec { "Encode" should "no tags" in { diff --git a/core/src/test/scala/akka/persistence/postgres/query/AllPersistenceIdsTest.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/query/AllPersistenceIdsTest.scala similarity index 91% rename from core/src/test/scala/akka/persistence/postgres/query/AllPersistenceIdsTest.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/query/AllPersistenceIdsTest.scala index 5e0124b3..8f89e35a 100644 --- a/core/src/test/scala/akka/persistence/postgres/query/AllPersistenceIdsTest.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/query/AllPersistenceIdsTest.scala @@ -3,9 +3,9 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.query +package org.apache.pekko.persistence.postgres.query -import akka.persistence.postgres.util.Schema.{ NestedPartitions, Partitioned, Plain, SchemaType } +import org.apache.pekko.persistence.postgres.util.Schema.{ NestedPartitions, Partitioned, Plain, SchemaType } import scala.concurrent.duration._ diff --git a/core/src/test/scala/akka/persistence/postgres/query/CurrentEventsByPersistenceIdTest.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/query/CurrentEventsByPersistenceIdTest.scala similarity index 94% rename from core/src/test/scala/akka/persistence/postgres/query/CurrentEventsByPersistenceIdTest.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/query/CurrentEventsByPersistenceIdTest.scala index a6efd8c6..2f5b4c8d 100644 --- a/core/src/test/scala/akka/persistence/postgres/query/CurrentEventsByPersistenceIdTest.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/query/CurrentEventsByPersistenceIdTest.scala @@ -3,14 +3,14 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.query - -import akka.Done -import akka.persistence.Persistence -import akka.persistence.postgres.journal.PostgresAsyncWriteJournal -import akka.persistence.postgres.util.Schema.{ NestedPartitions, Partitioned, Plain, SchemaType } -import akka.persistence.query.{ EventEnvelope, Offset, Sequence } -import akka.testkit.TestProbe +package org.apache.pekko.persistence.postgres.query + +import org.apache.pekko.Done +import org.apache.pekko.persistence.Persistence +import org.apache.pekko.persistence.postgres.journal.PostgresAsyncWriteJournal +import org.apache.pekko.persistence.postgres.util.Schema.{ NestedPartitions, Partitioned, Plain, SchemaType } +import org.apache.pekko.persistence.query.{ EventEnvelope, Offset, Sequence } +import org.apache.pekko.testkit.TestProbe abstract class CurrentEventsByPersistenceIdTest(val schemaType: SchemaType) extends QueryTestSpec(s"${schemaType.resourceNamePrefix}-shared-db-application.conf") { diff --git a/core/src/test/scala/akka/persistence/postgres/query/CurrentEventsByTagTest.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/query/CurrentEventsByTagTest.scala similarity index 95% rename from core/src/test/scala/akka/persistence/postgres/query/CurrentEventsByTagTest.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/query/CurrentEventsByTagTest.scala index 234228a0..def761ab 100644 --- a/core/src/test/scala/akka/persistence/postgres/query/CurrentEventsByTagTest.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/query/CurrentEventsByTagTest.scala @@ -3,14 +3,14 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.query - -import akka.Done -import akka.pattern.ask -import akka.persistence.postgres.query.CurrentEventsByTagTest._ -import akka.persistence.postgres.query.EventAdapterTest.{ Event, TaggedAsyncEvent } -import akka.persistence.postgres.util.Schema.{ NestedPartitions, Partitioned, Plain, SchemaType } -import akka.persistence.query.{ EventEnvelope, NoOffset, Sequence } +package org.apache.pekko.persistence.postgres.query + +import org.apache.pekko.Done +import org.apache.pekko.pattern.ask +import org.apache.pekko.persistence.postgres.query.CurrentEventsByTagTest._ +import org.apache.pekko.persistence.postgres.query.EventAdapterTest.{ Event, TaggedAsyncEvent } +import org.apache.pekko.persistence.postgres.util.Schema.{ NestedPartitions, Partitioned, Plain, SchemaType } +import org.apache.pekko.persistence.query.{ EventEnvelope, NoOffset, Sequence } import com.typesafe.config.{ Config, ConfigFactory, ConfigValue, ConfigValueFactory } import scala.concurrent.Future diff --git a/core/src/test/scala/akka/persistence/postgres/query/CurrentEventsByTagWithGapsTest.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/query/CurrentEventsByTagWithGapsTest.scala similarity index 80% rename from core/src/test/scala/akka/persistence/postgres/query/CurrentEventsByTagWithGapsTest.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/query/CurrentEventsByTagWithGapsTest.scala index 539c36b5..3929af84 100644 --- a/core/src/test/scala/akka/persistence/postgres/query/CurrentEventsByTagWithGapsTest.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/query/CurrentEventsByTagWithGapsTest.scala @@ -1,14 +1,14 @@ -package akka.persistence.postgres.query +package org.apache.pekko.persistence.postgres.query -import akka.actor.ActorSystem -import akka.persistence.PersistentRepr -import akka.persistence.postgres.journal.dao.{ ByteArrayJournalSerializer, JournalQueries } -import akka.persistence.postgres.tag.{ CachedTagIdResolver, SimpleTagDao } -import akka.persistence.postgres.util.Schema -import akka.persistence.postgres.util.Schema.SchemaType -import akka.persistence.query.NoOffset -import akka.serialization.SerializationExtension -import akka.stream.scaladsl.{ Sink, Source } +import org.apache.pekko.actor.ActorSystem +import org.apache.pekko.persistence.PersistentRepr +import org.apache.pekko.persistence.postgres.journal.dao.{ ByteArrayJournalSerializer, JournalQueries } +import org.apache.pekko.persistence.postgres.tag.{ CachedTagIdResolver, SimpleTagDao } +import org.apache.pekko.persistence.postgres.util.Schema +import org.apache.pekko.persistence.postgres.util.Schema.SchemaType +import org.apache.pekko.persistence.query.NoOffset +import org.apache.pekko.serialization.SerializationExtension +import org.apache.pekko.stream.scaladsl.{ Sink, Source } import com.typesafe.config.{ ConfigValue, ConfigValueFactory } import scala.concurrent.duration._ @@ -35,7 +35,7 @@ class CurrentEventsByTagWithGapsTest withActorSystem { implicit system: ActorSystem => import system.dispatcher withDatabase { db => - import akka.persistence.postgres.db.ExtendedPostgresProfile.api._ + import org.apache.pekko.persistence.postgres.db.ExtendedPostgresProfile.api._ db.run { val tableConf = journalConfig.journalTableConfiguration val schema = tableConf.schemaName.getOrElse("public") diff --git a/core/src/test/scala/akka/persistence/postgres/query/CurrentPersistenceIdsTest.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/query/CurrentPersistenceIdsTest.scala similarity index 90% rename from core/src/test/scala/akka/persistence/postgres/query/CurrentPersistenceIdsTest.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/query/CurrentPersistenceIdsTest.scala index 0bf3fbf9..57e42d09 100644 --- a/core/src/test/scala/akka/persistence/postgres/query/CurrentPersistenceIdsTest.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/query/CurrentPersistenceIdsTest.scala @@ -3,9 +3,9 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.query +package org.apache.pekko.persistence.postgres.query -import akka.persistence.postgres.util.Schema.{ NestedPartitions, Partitioned, Plain, SchemaType } +import org.apache.pekko.persistence.postgres.util.Schema.{ NestedPartitions, Partitioned, Plain, SchemaType } abstract class CurrentPersistenceIdsTest(val schemaType: SchemaType) extends QueryTestSpec(s"${schemaType.resourceNamePrefix}-shared-db-application.conf") { diff --git a/core/src/test/scala/akka/persistence/postgres/query/EventAdapterTest.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/query/EventAdapterTest.scala similarity index 94% rename from core/src/test/scala/akka/persistence/postgres/query/EventAdapterTest.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/query/EventAdapterTest.scala index 9a42f954..9859526c 100644 --- a/core/src/test/scala/akka/persistence/postgres/query/EventAdapterTest.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/query/EventAdapterTest.scala @@ -3,12 +3,12 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.query +package org.apache.pekko.persistence.postgres.query -import akka.pattern.ask -import akka.persistence.journal.{ EventSeq, ReadEventAdapter, Tagged, WriteEventAdapter } -import akka.persistence.postgres.util.Schema.{ NestedPartitions, Partitioned, Plain, SchemaType } -import akka.persistence.query.{ EventEnvelope, NoOffset, Sequence } +import org.apache.pekko.pattern.ask +import org.apache.pekko.persistence.journal.{ EventSeq, ReadEventAdapter, Tagged, WriteEventAdapter } +import org.apache.pekko.persistence.postgres.util.Schema.{ NestedPartitions, Partitioned, Plain, SchemaType } +import org.apache.pekko.persistence.query.{ EventEnvelope, NoOffset, Sequence } import scala.concurrent.duration._ diff --git a/core/src/test/scala/akka/persistence/postgres/query/EventsByPersistenceIdTest.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/query/EventsByPersistenceIdTest.scala similarity index 96% rename from core/src/test/scala/akka/persistence/postgres/query/EventsByPersistenceIdTest.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/query/EventsByPersistenceIdTest.scala index 4d8876ca..f84178c7 100644 --- a/core/src/test/scala/akka/persistence/postgres/query/EventsByPersistenceIdTest.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/query/EventsByPersistenceIdTest.scala @@ -3,13 +3,13 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.query +package org.apache.pekko.persistence.postgres.query -import akka.Done -import akka.pattern.ask -import akka.persistence.postgres.query.EventAdapterTest.{ Event, TaggedAsyncEvent } -import akka.persistence.postgres.util.Schema.{ NestedPartitions, Partitioned, Plain, SchemaType } -import akka.persistence.query.{ EventEnvelope, Offset, Sequence } +import org.apache.pekko.Done +import org.apache.pekko.pattern.ask +import org.apache.pekko.persistence.postgres.query.EventAdapterTest.{ Event, TaggedAsyncEvent } +import org.apache.pekko.persistence.postgres.util.Schema.{ NestedPartitions, Partitioned, Plain, SchemaType } +import org.apache.pekko.persistence.query.{ EventEnvelope, Offset, Sequence } import scala.concurrent.Future import scala.concurrent.duration._ @@ -305,7 +305,7 @@ abstract class EventsByPersistenceIdTest(val schemaType: SchemaType) extends Que } it should "find a large number of events quickly" in withActorSystem { implicit system => - import akka.pattern.ask + import org.apache.pekko.pattern.ask import system.dispatcher val journalOps = new JavaDslPostgresReadJournalOperations(system) withTestActors(replyToMessages = true) { (actor1, _, _) => diff --git a/core/src/test/scala/akka/persistence/postgres/query/EventsByTagTest.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/query/EventsByTagTest.scala similarity index 97% rename from core/src/test/scala/akka/persistence/postgres/query/EventsByTagTest.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/query/EventsByTagTest.scala index 4bf07b1c..64ec60d6 100644 --- a/core/src/test/scala/akka/persistence/postgres/query/EventsByTagTest.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/query/EventsByTagTest.scala @@ -3,14 +3,14 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.query - -import akka.Done -import akka.pattern.ask -import akka.persistence.postgres.query.EventAdapterTest.{ Event, EventRestored, TaggedAsyncEvent, TaggedEvent } -import akka.persistence.postgres.query.EventsByTagTest._ -import akka.persistence.postgres.util.Schema.{ NestedPartitions, Partitioned, Plain, SchemaType } -import akka.persistence.query.{ EventEnvelope, NoOffset, Sequence } +package org.apache.pekko.persistence.postgres.query + +import org.apache.pekko.Done +import org.apache.pekko.pattern.ask +import org.apache.pekko.persistence.postgres.query.EventAdapterTest.{ Event, EventRestored, TaggedAsyncEvent, TaggedEvent } +import org.apache.pekko.persistence.postgres.query.EventsByTagTest._ +import org.apache.pekko.persistence.postgres.util.Schema.{ NestedPartitions, Partitioned, Plain, SchemaType } +import org.apache.pekko.persistence.query.{ EventEnvelope, NoOffset, Sequence } import com.typesafe.config.{ ConfigValue, ConfigValueFactory } import scala.concurrent.Future diff --git a/core/src/test/scala/akka/persistence/postgres/query/HardDeleteQueryTest.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/query/HardDeleteQueryTest.scala similarity index 94% rename from core/src/test/scala/akka/persistence/postgres/query/HardDeleteQueryTest.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/query/HardDeleteQueryTest.scala index 8a1e3b3f..d7d1b540 100644 --- a/core/src/test/scala/akka/persistence/postgres/query/HardDeleteQueryTest.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/query/HardDeleteQueryTest.scala @@ -3,11 +3,11 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.query +package org.apache.pekko.persistence.postgres.query -import akka.pattern._ -import akka.persistence.postgres.util.Schema.{ NestedPartitions, Partitioned, Plain, SchemaType } -import akka.persistence.query.NoOffset +import org.apache.pekko.pattern._ +import org.apache.pekko.persistence.postgres.util.Schema.{ NestedPartitions, Partitioned, Plain, SchemaType } +import org.apache.pekko.persistence.query.NoOffset import org.scalatest.matchers.should.Matchers import scala.concurrent.duration._ diff --git a/core/src/test/scala/akka/persistence/postgres/query/JournalDaoStreamMessagesMemoryTest.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/query/JournalDaoStreamMessagesMemoryTest.scala similarity index 89% rename from core/src/test/scala/akka/persistence/postgres/query/JournalDaoStreamMessagesMemoryTest.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/query/JournalDaoStreamMessagesMemoryTest.scala index aa4d1679..9d14ece6 100644 --- a/core/src/test/scala/akka/persistence/postgres/query/JournalDaoStreamMessagesMemoryTest.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/query/JournalDaoStreamMessagesMemoryTest.scala @@ -3,20 +3,20 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.query +package org.apache.pekko.persistence.postgres.query import java.lang.management.{ ManagementFactory, MemoryMXBean } import java.util.UUID -import akka.actor.{ ActorSystem, ExtendedActorSystem } -import akka.persistence.postgres.config.JournalConfig -import akka.persistence.postgres.journal.dao.JournalDao -import akka.persistence.postgres.util.Schema.{ NestedPartitions, Partitioned, Plain, SchemaType } -import akka.persistence.{ AtomicWrite, PersistentRepr } -import akka.serialization.{ Serialization, SerializationExtension } -import akka.stream.scaladsl.{ Sink, Source } -import akka.stream.testkit.scaladsl.TestSink -import akka.stream.{ Materializer, SystemMaterializer } +import org.apache.pekko.actor.{ ActorSystem, ExtendedActorSystem } +import org.apache.pekko.persistence.postgres.config.JournalConfig +import org.apache.pekko.persistence.postgres.journal.dao.JournalDao +import org.apache.pekko.persistence.postgres.util.Schema.{ NestedPartitions, Partitioned, Plain, SchemaType } +import org.apache.pekko.persistence.{ AtomicWrite, PersistentRepr } +import org.apache.pekko.serialization.{ Serialization, SerializationExtension } +import org.apache.pekko.stream.scaladsl.{ Sink, Source } +import org.apache.pekko.stream.testkit.scaladsl.TestSink +import org.apache.pekko.stream.{ Materializer, SystemMaterializer } import com.typesafe.config.{ ConfigValue, ConfigValueFactory } import org.scalatest.concurrent.PatienceConfiguration.Timeout import org.scalatest.matchers.should diff --git a/core/src/test/scala/akka/persistence/postgres/query/JournalSequenceActorTest.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/query/JournalSequenceActorTest.scala similarity index 90% rename from core/src/test/scala/akka/persistence/postgres/query/JournalSequenceActorTest.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/query/JournalSequenceActorTest.scala index 201d8437..23752062 100644 --- a/core/src/test/scala/akka/persistence/postgres/query/JournalSequenceActorTest.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/query/JournalSequenceActorTest.scala @@ -3,22 +3,22 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.query +package org.apache.pekko.persistence.postgres.query import java.util.concurrent.atomic.AtomicLong -import akka.actor.{ ActorRef, ActorSystem } -import akka.pattern.ask -import akka.persistence.postgres.config.JournalSequenceRetrievalConfig -import akka.persistence.postgres.db.ExtendedPostgresProfile -import akka.persistence.postgres.query.JournalSequenceActor.{ GetMaxOrderingId, MaxOrderingId } -import akka.persistence.postgres.query.dao.{ FlatReadJournalDao, PartitionedReadJournalDao, TestProbeReadJournalDao } -import akka.persistence.postgres.tag.{ CachedTagIdResolver, SimpleTagDao } -import akka.persistence.postgres.util.Schema.{ NestedPartitions, Partitioned, Plain, SchemaType } -import akka.persistence.postgres.{ JournalRow, SharedActorSystemTestSpec } -import akka.serialization.SerializationExtension -import akka.stream.scaladsl.{ Sink, Source } -import akka.stream.{ Materializer, SystemMaterializer } -import akka.testkit.TestProbe +import org.apache.pekko.actor.{ ActorRef, ActorSystem } +import org.apache.pekko.pattern.ask +import org.apache.pekko.persistence.postgres.config.JournalSequenceRetrievalConfig +import org.apache.pekko.persistence.postgres.db.ExtendedPostgresProfile +import org.apache.pekko.persistence.postgres.query.JournalSequenceActor.{ GetMaxOrderingId, MaxOrderingId } +import org.apache.pekko.persistence.postgres.query.dao.{ FlatReadJournalDao, PartitionedReadJournalDao, TestProbeReadJournalDao } +import org.apache.pekko.persistence.postgres.tag.{ CachedTagIdResolver, SimpleTagDao } +import org.apache.pekko.persistence.postgres.util.Schema.{ NestedPartitions, Partitioned, Plain, SchemaType } +import org.apache.pekko.persistence.postgres.{ JournalRow, SharedActorSystemTestSpec } +import org.apache.pekko.serialization.SerializationExtension +import org.apache.pekko.stream.scaladsl.{ Sink, Source } +import org.apache.pekko.stream.{ Materializer, SystemMaterializer } +import org.apache.pekko.testkit.TestProbe import io.circe.{ Json, JsonObject } import org.scalatest.time.Span import org.slf4j.LoggerFactory @@ -34,7 +34,7 @@ abstract class JournalSequenceActorTest(val schemaType: SchemaType) extends Quer private val journalSequenceActorConfig = readJournalConfig.journalSequenceRetrievalConfiguration private val journalTable = schemaType.table(journalConfig.journalTableConfiguration) - import akka.persistence.postgres.db.ExtendedPostgresProfile.api._ + import org.apache.pekko.persistence.postgres.db.ExtendedPostgresProfile.api._ implicit val askTimeout: FiniteDuration = 50.millis @@ -295,7 +295,7 @@ class MockDaoJournalSequenceActorTest extends SharedActorSystemTestSpec { class NestedPartitionsJournalSequenceActorTest extends JournalSequenceActorTest(NestedPartitions) { override def beforeEach(): Unit = { super.beforeEach() - import akka.persistence.postgres.db.ExtendedPostgresProfile.api._ + import org.apache.pekko.persistence.postgres.db.ExtendedPostgresProfile.api._ withActorSystem { implicit system: ActorSystem => withDatabase { db => db.run(sqlu""" @@ -309,7 +309,7 @@ class NestedPartitionsJournalSequenceActorTest extends JournalSequenceActorTest( class PartitionedJournalSequenceActorTest extends JournalSequenceActorTest(Partitioned) { override def beforeEach(): Unit = { super.beforeEach() - import akka.persistence.postgres.db.ExtendedPostgresProfile.api._ + import org.apache.pekko.persistence.postgres.db.ExtendedPostgresProfile.api._ withActorSystem { implicit system: ActorSystem => withDatabase { db => db.run(sqlu"""CREATE TABLE IF NOT EXISTS j_1 PARTITION OF journal FOR VALUES FROM (0) TO (1000000000);""") diff --git a/core/src/test/scala/akka/persistence/postgres/query/LogicalDeleteQueryTest.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/query/LogicalDeleteQueryTest.scala similarity index 93% rename from core/src/test/scala/akka/persistence/postgres/query/LogicalDeleteQueryTest.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/query/LogicalDeleteQueryTest.scala index c6be56c3..183ceffd 100644 --- a/core/src/test/scala/akka/persistence/postgres/query/LogicalDeleteQueryTest.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/query/LogicalDeleteQueryTest.scala @@ -3,11 +3,11 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.query +package org.apache.pekko.persistence.postgres.query -import akka.pattern._ -import akka.persistence.postgres.util.Schema.{ NestedPartitions, Partitioned, Plain, SchemaType } -import akka.persistence.query.{ EventEnvelope, NoOffset, Sequence } +import org.apache.pekko.pattern._ +import org.apache.pekko.persistence.postgres.util.Schema.{ NestedPartitions, Partitioned, Plain, SchemaType } +import org.apache.pekko.persistence.query.{ EventEnvelope, NoOffset, Sequence } import scala.concurrent.duration._ diff --git a/core/src/test/scala/akka/persistence/postgres/query/QueryTestSpec.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/query/QueryTestSpec.scala similarity index 81% rename from core/src/test/scala/akka/persistence/postgres/query/QueryTestSpec.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/query/QueryTestSpec.scala index ef2ff5b3..7c67d0fa 100644 --- a/core/src/test/scala/akka/persistence/postgres/query/QueryTestSpec.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/query/QueryTestSpec.scala @@ -3,23 +3,23 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.query - -import akka.actor.{ ActorRef, ActorSystem, Props, Stash, Status } -import akka.event.LoggingReceive -import akka.persistence.journal.Tagged -import akka.persistence.postgres.SingleActorSystemPerTestSpec -import akka.persistence.postgres.query.EventAdapterTest.{ Event, TaggedAsyncEvent, TaggedEvent } -import akka.persistence.postgres.query.javadsl.{ PostgresReadJournal => JavaPostgresReadJournal } -import akka.persistence.postgres.query.scaladsl.PostgresReadJournal -import akka.persistence.postgres.util.Schema.SchemaType -import akka.persistence.query.{ EventEnvelope, Offset, PersistenceQuery } -import akka.persistence.{ DeleteMessagesFailure, DeleteMessagesSuccess, PersistentActor } -import akka.stream.scaladsl.Sink -import akka.stream.testkit.TestSubscriber -import akka.stream.testkit.javadsl.{ TestSink => JavaSink } -import akka.stream.testkit.scaladsl.TestSink -import akka.stream.{ Materializer, SystemMaterializer } +package org.apache.pekko.persistence.postgres.query + +import org.apache.pekko.actor.{ ActorRef, ActorSystem, Props, Stash, Status } +import org.apache.pekko.event.LoggingReceive +import org.apache.pekko.persistence.journal.Tagged +import org.apache.pekko.persistence.postgres.SingleActorSystemPerTestSpec +import org.apache.pekko.persistence.postgres.query.EventAdapterTest.{ Event, TaggedAsyncEvent, TaggedEvent } +import org.apache.pekko.persistence.postgres.query.javadsl.{ PostgresReadJournal => JavaPostgresReadJournal } +import org.apache.pekko.persistence.postgres.query.scaladsl.PostgresReadJournal +import org.apache.pekko.persistence.postgres.util.Schema.SchemaType +import org.apache.pekko.persistence.query.{ EventEnvelope, Offset, PersistenceQuery } +import org.apache.pekko.persistence.{ DeleteMessagesFailure, DeleteMessagesSuccess, PersistentActor } +import org.apache.pekko.stream.scaladsl.Sink +import org.apache.pekko.stream.testkit.TestSubscriber +import org.apache.pekko.stream.testkit.javadsl.{ TestSink => JavaSink } +import org.apache.pekko.stream.testkit.scaladsl.TestSink +import org.apache.pekko.stream.{ Materializer, SystemMaterializer } import com.typesafe.config.ConfigValue import slick.jdbc.PostgresProfile.api._ @@ -121,13 +121,13 @@ class JavaDslPostgresReadJournalOperations(readJournal: javadsl.PostgresReadJour import system.dispatcher def withCurrentPersistenceIds(within: FiniteDuration)(f: TestSubscriber.Probe[String] => Unit): Unit = { - val sink: akka.stream.javadsl.Sink[String, TestSubscriber.Probe[String]] = JavaSink.probe(system) + val sink: org.apache.pekko.stream.javadsl.Sink[String, TestSubscriber.Probe[String]] = JavaSink.probe(system) val tp = readJournal.currentPersistenceIds().runWith(sink, mat) tp.within(within)(f(tp)) } def withPersistenceIds(within: FiniteDuration)(f: TestSubscriber.Probe[String] => Unit): Unit = { - val sink: akka.stream.javadsl.Sink[String, TestSubscriber.Probe[String]] = JavaSink.probe(system) + val sink: org.apache.pekko.stream.javadsl.Sink[String, TestSubscriber.Probe[String]] = JavaSink.probe(system) val tp = readJournal.persistenceIds().runWith(sink, mat) tp.within(within)(f(tp)) } @@ -135,7 +135,7 @@ class JavaDslPostgresReadJournalOperations(readJournal: javadsl.PostgresReadJour def withCurrentEventsByPersistenceId( within: FiniteDuration)(persistenceId: String, fromSequenceNr: Long = 0, toSequenceNr: Long = Long.MaxValue)( f: TestSubscriber.Probe[EventEnvelope] => Unit): Unit = { - val sink: akka.stream.javadsl.Sink[EventEnvelope, TestSubscriber.Probe[EventEnvelope]] = JavaSink.probe(system) + val sink: org.apache.pekko.stream.javadsl.Sink[EventEnvelope, TestSubscriber.Probe[EventEnvelope]] = JavaSink.probe(system) val tp = readJournal.currentEventsByPersistenceId(persistenceId, fromSequenceNr, toSequenceNr).runWith(sink, mat) tp.within(within)(f(tp)) } @@ -143,21 +143,21 @@ class JavaDslPostgresReadJournalOperations(readJournal: javadsl.PostgresReadJour def withEventsByPersistenceId( within: FiniteDuration)(persistenceId: String, fromSequenceNr: Long, toSequenceNr: Long)( f: TestSubscriber.Probe[EventEnvelope] => Unit): Unit = { - val sink: akka.stream.javadsl.Sink[EventEnvelope, TestSubscriber.Probe[EventEnvelope]] = JavaSink.probe(system) + val sink: org.apache.pekko.stream.javadsl.Sink[EventEnvelope, TestSubscriber.Probe[EventEnvelope]] = JavaSink.probe(system) val tp = readJournal.eventsByPersistenceId(persistenceId, fromSequenceNr, toSequenceNr).runWith(sink, mat) tp.within(within)(f(tp)) } def withCurrentEventsByTag(within: FiniteDuration)(tag: String, offset: Offset)( f: TestSubscriber.Probe[EventEnvelope] => Unit): Unit = { - val sink: akka.stream.javadsl.Sink[EventEnvelope, TestSubscriber.Probe[EventEnvelope]] = JavaSink.probe(system) + val sink: org.apache.pekko.stream.javadsl.Sink[EventEnvelope, TestSubscriber.Probe[EventEnvelope]] = JavaSink.probe(system) val tp = readJournal.currentEventsByTag(tag, offset).runWith(sink, mat) tp.within(within)(f(tp)) } def withEventsByTag(within: FiniteDuration)(tag: String, offset: Offset)( f: TestSubscriber.Probe[EventEnvelope] => Unit): Unit = { - val sink: akka.stream.javadsl.Sink[EventEnvelope, TestSubscriber.Probe[EventEnvelope]] = JavaSink.probe(system) + val sink: org.apache.pekko.stream.javadsl.Sink[EventEnvelope, TestSubscriber.Probe[EventEnvelope]] = JavaSink.probe(system) val tp = readJournal.eventsByTag(tag, offset).runWith(sink, mat) tp.within(within)(f(tp)) } @@ -249,26 +249,26 @@ abstract class QueryTestSpec(config: String, configOverrides: Map[String, Config case event: Int => persist(event) { (event: Int) => updateState(event) - if (replyToMessages) sender() ! akka.actor.Status.Success(event) + if (replyToMessages) sender() ! org.apache.pekko.actor.Status.Success(event) } case event @ Tagged(payload: Int, tags) => persist(event) { (event: Tagged) => updateState(payload) - if (replyToMessages) sender() ! akka.actor.Status.Success((payload, tags)) + if (replyToMessages) sender() ! org.apache.pekko.actor.Status.Success((payload, tags)) } case event: Event => persist(event) { evt => - if (replyToMessages) sender() ! akka.actor.Status.Success(evt) + if (replyToMessages) sender() ! org.apache.pekko.actor.Status.Success(evt) } case event @ TaggedEvent(payload: Event, tag) => persist(event) { evt => - if (replyToMessages) sender() ! akka.actor.Status.Success((payload, tag)) + if (replyToMessages) sender() ! org.apache.pekko.actor.Status.Success((payload, tag)) } case event @ TaggedAsyncEvent(payload: Event, tag) => persistAsync(event) { evt => - if (replyToMessages) sender() ! akka.actor.Status.Success((payload, tag)) + if (replyToMessages) sender() ! org.apache.pekko.actor.Status.Success((payload, tag)) } } diff --git a/core/src/test/scala/akka/persistence/postgres/query/TaggingEventAdapter.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/query/TaggingEventAdapter.scala similarity index 73% rename from core/src/test/scala/akka/persistence/postgres/query/TaggingEventAdapter.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/query/TaggingEventAdapter.scala index 6b0fc936..e2ca0d65 100644 --- a/core/src/test/scala/akka/persistence/postgres/query/TaggingEventAdapter.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/query/TaggingEventAdapter.scala @@ -3,10 +3,10 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.query +package org.apache.pekko.persistence.postgres.query -import akka.persistence.postgres.query.TaggingEventAdapter.TagEvent -import akka.persistence.journal.{ Tagged, WriteEventAdapter } +import org.apache.pekko.persistence.postgres.query.TaggingEventAdapter.TagEvent +import org.apache.pekko.persistence.journal.{ Tagged, WriteEventAdapter } object TaggingEventAdapter { case class TagEvent(payload: Any, tags: Set[String]) diff --git a/core/src/test/scala/akka/persistence/postgres/query/dao/ReadJournalMetadataQueriesTest.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/query/dao/ReadJournalMetadataQueriesTest.scala similarity index 75% rename from core/src/test/scala/akka/persistence/postgres/query/dao/ReadJournalMetadataQueriesTest.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/query/dao/ReadJournalMetadataQueriesTest.scala index bef12342..638f8e1c 100644 --- a/core/src/test/scala/akka/persistence/postgres/query/dao/ReadJournalMetadataQueriesTest.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/query/dao/ReadJournalMetadataQueriesTest.scala @@ -1,7 +1,7 @@ -package akka.persistence.postgres.query.dao +package org.apache.pekko.persistence.postgres.query.dao -import akka.persistence.postgres.journal.dao.JournalMetadataTable -import akka.persistence.postgres.util.BaseQueryTest +import org.apache.pekko.persistence.postgres.journal.dao.JournalMetadataTable +import org.apache.pekko.persistence.postgres.util.BaseQueryTest class ReadJournalMetadataQueriesTest extends BaseQueryTest { it should "create SQL query for minAndMaxOrderingForPersistenceId" in withReadJournalMetadataQueries { queries => diff --git a/core/src/test/scala/akka/persistence/postgres/query/dao/ReadJournalQueriesTest.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/query/dao/ReadJournalQueriesTest.scala similarity index 92% rename from core/src/test/scala/akka/persistence/postgres/query/dao/ReadJournalQueriesTest.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/query/dao/ReadJournalQueriesTest.scala index 33d751eb..6945fc14 100644 --- a/core/src/test/scala/akka/persistence/postgres/query/dao/ReadJournalQueriesTest.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/query/dao/ReadJournalQueriesTest.scala @@ -1,7 +1,7 @@ -package akka.persistence.postgres.query.dao +package org.apache.pekko.persistence.postgres.query.dao -import akka.persistence.postgres.journal.dao.FlatJournalTable -import akka.persistence.postgres.util.BaseQueryTest +import org.apache.pekko.persistence.postgres.journal.dao.FlatJournalTable +import org.apache.pekko.persistence.postgres.util.BaseQueryTest class ReadJournalQueriesTest extends BaseQueryTest { diff --git a/core/src/test/scala/akka/persistence/postgres/query/dao/ReadJournalTablesTest.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/query/dao/ReadJournalTablesTest.scala similarity index 85% rename from core/src/test/scala/akka/persistence/postgres/query/dao/ReadJournalTablesTest.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/query/dao/ReadJournalTablesTest.scala index 1cf9f778..3cfc75d5 100644 --- a/core/src/test/scala/akka/persistence/postgres/query/dao/ReadJournalTablesTest.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/query/dao/ReadJournalTablesTest.scala @@ -3,10 +3,10 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.query.dao +package org.apache.pekko.persistence.postgres.query.dao -import akka.persistence.postgres.TablesTestSpec -import akka.persistence.postgres.journal.dao.{ FlatJournalTable, NestedPartitionsJournalTable, PartitionedJournalTable } +import org.apache.pekko.persistence.postgres.TablesTestSpec +import org.apache.pekko.persistence.postgres.journal.dao.{ FlatJournalTable, NestedPartitionsJournalTable, PartitionedJournalTable } class ReadJournalTablesTest extends TablesTestSpec { val readJournalTableConfiguration = readJournalConfig.journalTableConfiguration diff --git a/core/src/test/scala/akka/persistence/postgres/query/dao/TestProbeReadJournalDao.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/query/dao/TestProbeReadJournalDao.scala similarity index 83% rename from core/src/test/scala/akka/persistence/postgres/query/dao/TestProbeReadJournalDao.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/query/dao/TestProbeReadJournalDao.scala index 42744f69..cd626a42 100644 --- a/core/src/test/scala/akka/persistence/postgres/query/dao/TestProbeReadJournalDao.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/query/dao/TestProbeReadJournalDao.scala @@ -3,16 +3,16 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.query.dao +package org.apache.pekko.persistence.postgres.query.dao -import akka.NotUsed -import akka.actor.Scheduler -import akka.pattern.ask -import akka.persistence.PersistentRepr -import akka.persistence.postgres.query.dao.TestProbeReadJournalDao.JournalSequence -import akka.stream.scaladsl.Source -import akka.testkit.TestProbe -import akka.util.Timeout +import org.apache.pekko.NotUsed +import org.apache.pekko.actor.Scheduler +import org.apache.pekko.pattern.ask +import org.apache.pekko.persistence.PersistentRepr +import org.apache.pekko.persistence.postgres.query.dao.TestProbeReadJournalDao.JournalSequence +import org.apache.pekko.stream.scaladsl.Source +import org.apache.pekko.testkit.TestProbe +import org.apache.pekko.util.Timeout import scala.concurrent.Future import scala.concurrent.duration._ diff --git a/core/src/test/scala/akka/persistence/postgres/serialization/StoreOnlySerializableMessagesTest.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/serialization/StoreOnlySerializableMessagesTest.scala similarity index 88% rename from core/src/test/scala/akka/persistence/postgres/serialization/StoreOnlySerializableMessagesTest.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/serialization/StoreOnlySerializableMessagesTest.scala index 327bead5..748008ec 100644 --- a/core/src/test/scala/akka/persistence/postgres/serialization/StoreOnlySerializableMessagesTest.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/serialization/StoreOnlySerializableMessagesTest.scala @@ -3,14 +3,14 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.serialization +package org.apache.pekko.persistence.postgres.serialization -import akka.actor.{ ActorRef, Props } -import akka.event.LoggingReceive -import akka.persistence.postgres.SharedActorSystemTestSpec -import akka.persistence.postgres.util.Schema._ -import akka.persistence.{ PersistentActor, RecoveryCompleted } -import akka.testkit.TestProbe +import org.apache.pekko.actor.{ ActorRef, Props } +import org.apache.pekko.event.LoggingReceive +import org.apache.pekko.persistence.postgres.SharedActorSystemTestSpec +import org.apache.pekko.persistence.postgres.util.Schema._ +import org.apache.pekko.persistence.{ PersistentActor, RecoveryCompleted } +import org.apache.pekko.testkit.TestProbe import scala.concurrent.duration._ @@ -31,7 +31,7 @@ abstract class StoreOnlySerializableMessagesTest(schemaType: SchemaType) override val receiveCommand: Receive = LoggingReceive { case msg => persist(msg) { _ => - sender() ! akka.actor.Status.Success("") + sender() ! org.apache.pekko.actor.Status.Success("") } } @@ -62,7 +62,7 @@ abstract class StoreOnlySerializableMessagesTest(schemaType: SchemaType) val tp = TestProbe() recover.expectMsg(RecoveryCompleted) tp.send(actor, "foo") // strings are serializable - tp.expectMsg(akka.actor.Status.Success("")) + tp.expectMsg(org.apache.pekko.actor.Status.Success("")) failure.expectNoMessage(100.millis) rejected.expectNoMessage(100.millis) } @@ -101,7 +101,7 @@ abstract class StoreOnlySerializableMessagesTest(schemaType: SchemaType) val tp = TestProbe() recover.expectMsg(RecoveryCompleted) tp.send(actor, "foo") - tp.expectMsg(akka.actor.Status.Success("")) + tp.expectMsg(org.apache.pekko.actor.Status.Success("")) tp.send(actor, new NotSerializable) // the NotSerializable class cannot be serialized tp.expectNoMessage(300.millis) // the handler should not have been called, because persist has failed // the actor should call the OnPersistRejected diff --git a/core/src/test/scala/akka/persistence/postgres/snapshot/PostgresSnapshotStoreSpec.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/snapshot/PostgresSnapshotStoreSpec.scala similarity index 76% rename from core/src/test/scala/akka/persistence/postgres/snapshot/PostgresSnapshotStoreSpec.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/snapshot/PostgresSnapshotStoreSpec.scala index 67768859..1c32d210 100644 --- a/core/src/test/scala/akka/persistence/postgres/snapshot/PostgresSnapshotStoreSpec.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/snapshot/PostgresSnapshotStoreSpec.scala @@ -3,13 +3,13 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.snapshot +package org.apache.pekko.persistence.postgres.snapshot -import akka.persistence.postgres.config._ -import akka.persistence.postgres.db.SlickDatabase -import akka.persistence.postgres.util.Schema._ -import akka.persistence.postgres.util.{ClasspathResources, DropCreate} -import akka.persistence.snapshot.SnapshotStoreSpec +import org.apache.pekko.persistence.postgres.config._ +import org.apache.pekko.persistence.postgres.db.SlickDatabase +import org.apache.pekko.persistence.postgres.util.Schema._ +import org.apache.pekko.persistence.postgres.util.{ClasspathResources, DropCreate} +import org.apache.pekko.persistence.snapshot.SnapshotStoreSpec import com.typesafe.config.ConfigFactory import org.scalatest.BeforeAndAfterAll import org.scalatest.concurrent.ScalaFutures diff --git a/core/src/test/scala/akka/persistence/postgres/snapshot/dao/ByteArraySnapshotSerializerTest.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/snapshot/dao/ByteArraySnapshotSerializerTest.scala similarity index 89% rename from core/src/test/scala/akka/persistence/postgres/snapshot/dao/ByteArraySnapshotSerializerTest.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/snapshot/dao/ByteArraySnapshotSerializerTest.scala index f25ad484..1697c8ad 100644 --- a/core/src/test/scala/akka/persistence/postgres/snapshot/dao/ByteArraySnapshotSerializerTest.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/snapshot/dao/ByteArraySnapshotSerializerTest.scala @@ -1,11 +1,11 @@ -package akka.persistence.postgres.snapshot.dao +package org.apache.pekko.persistence.postgres.snapshot.dao import java.time.{ LocalDateTime, ZoneOffset } -import akka.persistence.SnapshotMetadata -import akka.persistence.postgres.SharedActorSystemTestSpec -import akka.persistence.postgres.snapshot.dao.SnapshotTables.SnapshotRow -import akka.serialization.Serializers +import org.apache.pekko.persistence.SnapshotMetadata +import org.apache.pekko.persistence.postgres.SharedActorSystemTestSpec +import org.apache.pekko.persistence.postgres.snapshot.dao.SnapshotTables.SnapshotRow +import org.apache.pekko.serialization.Serializers import io.circe.Json import org.scalatest.TryValues diff --git a/core/src/test/scala/akka/persistence/postgres/snapshot/dao/SnapshotQueriesTest.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/snapshot/dao/SnapshotQueriesTest.scala similarity index 94% rename from core/src/test/scala/akka/persistence/postgres/snapshot/dao/SnapshotQueriesTest.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/snapshot/dao/SnapshotQueriesTest.scala index 74d798b3..62608d30 100644 --- a/core/src/test/scala/akka/persistence/postgres/snapshot/dao/SnapshotQueriesTest.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/snapshot/dao/SnapshotQueriesTest.scala @@ -1,12 +1,12 @@ -package akka.persistence.postgres.snapshot.dao +package org.apache.pekko.persistence.postgres.snapshot.dao -import akka.persistence.postgres.config.SnapshotConfig -import akka.persistence.postgres.snapshot.dao.SnapshotTables.SnapshotRow -import akka.persistence.postgres.util.BaseQueryTest +import org.apache.pekko.persistence.postgres.config.SnapshotConfig +import org.apache.pekko.persistence.postgres.snapshot.dao.SnapshotTables.SnapshotRow +import org.apache.pekko.persistence.postgres.util.BaseQueryTest import io.circe.{ Json, JsonObject } class SnapshotQueriesTest extends BaseQueryTest { - import akka.persistence.postgres.db.ExtendedPostgresProfile.api._ + import org.apache.pekko.persistence.postgres.db.ExtendedPostgresProfile.api._ it should "create SQL query for selectAllByPersistenceId.delete" in withSnapshotQueries { queries => queries diff --git a/core/src/test/scala/akka/persistence/postgres/snapshot/dao/SnapshotTablesTest.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/snapshot/dao/SnapshotTablesTest.scala similarity index 92% rename from core/src/test/scala/akka/persistence/postgres/snapshot/dao/SnapshotTablesTest.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/snapshot/dao/SnapshotTablesTest.scala index 842a4e08..5eaa1675 100644 --- a/core/src/test/scala/akka/persistence/postgres/snapshot/dao/SnapshotTablesTest.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/snapshot/dao/SnapshotTablesTest.scala @@ -3,9 +3,9 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.snapshot.dao +package org.apache.pekko.persistence.postgres.snapshot.dao -import akka.persistence.postgres.TablesTestSpec +import org.apache.pekko.persistence.postgres.TablesTestSpec class SnapshotTablesTest extends TablesTestSpec { val snapshotTableConfiguration = snapshotConfig.snapshotTableConfiguration diff --git a/core/src/test/scala/akka/persistence/postgres/tag/CachedTagIdResolverSpec.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/tag/CachedTagIdResolverSpec.scala similarity index 99% rename from core/src/test/scala/akka/persistence/postgres/tag/CachedTagIdResolverSpec.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/tag/CachedTagIdResolverSpec.scala index 032936cf..70f456e3 100644 --- a/core/src/test/scala/akka/persistence/postgres/tag/CachedTagIdResolverSpec.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/tag/CachedTagIdResolverSpec.scala @@ -1,9 +1,9 @@ -package akka.persistence.postgres.tag +package org.apache.pekko.persistence.postgres.tag import java.util.concurrent.ThreadLocalRandom import java.util.concurrent.atomic.{ AtomicBoolean, AtomicLong } -import akka.persistence.postgres.config.TagsConfig +import org.apache.pekko.persistence.postgres.config.TagsConfig import com.typesafe.config.ConfigFactory import org.scalatest.concurrent.Eventually.eventually import org.scalatest.concurrent.{ IntegrationPatience, ScalaFutures } diff --git a/core/src/test/scala/akka/persistence/postgres/tag/SimpleTagDaoSpec.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/tag/SimpleTagDaoSpec.scala similarity index 89% rename from core/src/test/scala/akka/persistence/postgres/tag/SimpleTagDaoSpec.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/tag/SimpleTagDaoSpec.scala index 19bb8c33..a6ec6a90 100644 --- a/core/src/test/scala/akka/persistence/postgres/tag/SimpleTagDaoSpec.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/tag/SimpleTagDaoSpec.scala @@ -1,9 +1,9 @@ -package akka.persistence.postgres.tag +package org.apache.pekko.persistence.postgres.tag import java.util.concurrent.ThreadLocalRandom -import akka.persistence.postgres.config.{ SlickConfiguration, TagsTableConfiguration } -import akka.persistence.postgres.db.SlickDatabase +import org.apache.pekko.persistence.postgres.config.{ SlickConfiguration, TagsTableConfiguration } +import org.apache.pekko.persistence.postgres.db.SlickDatabase import com.typesafe.config.{ Config, ConfigFactory } import org.scalatest.concurrent.{ IntegrationPatience, ScalaFutures } import org.scalatest.flatspec.AnyFlatSpecLike @@ -22,7 +22,7 @@ class SimpleTagDaoSpec with BeforeAndAfter with IntegrationPatience { - import akka.persistence.postgres.db.ExtendedPostgresProfile.api._ + import org.apache.pekko.persistence.postgres.db.ExtendedPostgresProfile.api._ private implicit val global: ExecutionContext = ExecutionContext.global diff --git a/core/src/test/scala/akka/persistence/postgres/util/BaseQueryTest.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/util/BaseQueryTest.scala similarity index 68% rename from core/src/test/scala/akka/persistence/postgres/util/BaseQueryTest.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/util/BaseQueryTest.scala index 2ab00061..19a59f90 100644 --- a/core/src/test/scala/akka/persistence/postgres/util/BaseQueryTest.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/util/BaseQueryTest.scala @@ -1,11 +1,11 @@ -package akka.persistence.postgres.util +package org.apache.pekko.persistence.postgres.util -import akka.persistence.postgres.SingleActorSystemPerTestSpec -import akka.persistence.postgres.db.ExtendedPostgresProfile +import org.apache.pekko.persistence.postgres.SingleActorSystemPerTestSpec +import org.apache.pekko.persistence.postgres.db.ExtendedPostgresProfile import slick.lifted.RunnableCompiled class BaseQueryTest extends SingleActorSystemPerTestSpec { - import akka.persistence.postgres.db.ExtendedPostgresProfile.api._ + import org.apache.pekko.persistence.postgres.db.ExtendedPostgresProfile.api._ implicit class SQLStringMatcherRunnableCompiled(under: RunnableCompiled[_, _]) { def toSQL: String = { under.result.toSQL diff --git a/core/src/test/scala/akka/persistence/postgres/util/ClasspathResources.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/util/ClasspathResources.scala similarity index 92% rename from core/src/test/scala/akka/persistence/postgres/util/ClasspathResources.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/util/ClasspathResources.scala index 959b2a49..ab8bae45 100644 --- a/core/src/test/scala/akka/persistence/postgres/util/ClasspathResources.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/util/ClasspathResources.scala @@ -3,7 +3,7 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.util +package org.apache.pekko.persistence.postgres.util import java.io.InputStream diff --git a/core/src/test/scala/akka/persistence/postgres/util/DropCreate.scala b/core/src/test/scala/org/apache/pekko/persistence/postgres/util/DropCreate.scala similarity index 88% rename from core/src/test/scala/akka/persistence/postgres/util/DropCreate.scala rename to core/src/test/scala/org/apache/pekko/persistence/postgres/util/DropCreate.scala index 84fa1024..e8272153 100644 --- a/core/src/test/scala/akka/persistence/postgres/util/DropCreate.scala +++ b/core/src/test/scala/org/apache/pekko/persistence/postgres/util/DropCreate.scala @@ -3,18 +3,18 @@ * Copyright (C) 2019 - 2020 Lightbend Inc. */ -package akka.persistence.postgres.util +package org.apache.pekko.persistence.postgres.util import java.sql.Statement -import akka.persistence.postgres.config.{ JournalMetadataTableConfiguration, JournalTableConfiguration } -import akka.persistence.postgres.journal.dao.{ +import org.apache.pekko.persistence.postgres.config.{ JournalMetadataTableConfiguration, JournalTableConfiguration } +import org.apache.pekko.persistence.postgres.journal.dao.{ FlatJournalTable, JournalMetadataTable, JournalTable, NestedPartitionsJournalTable, PartitionedJournalTable } -import akka.persistence.postgres.util.Schema.SchemaType +import org.apache.pekko.persistence.postgres.util.Schema.SchemaType import slick.jdbc.JdbcBackend.{ Database, Session } import slick.lifted.TableQuery diff --git a/migration/src/main/resources/reference.conf b/migration/src/main/resources/reference.conf index b45d957f..05d633e7 100644 --- a/migration/src/main/resources/reference.conf +++ b/migration/src/main/resources/reference.conf @@ -1,4 +1,4 @@ -akka-persistence-postgres { +pekko-persistence-postgres { migration { batchSize = 500 } diff --git a/migration/src/main/scala/akka/persistence/postgres/migration/PgSlickSupport.scala b/migration/src/main/scala/org/apache/pekko/persistence/postgres/migration/PgSlickSupport.scala similarity index 90% rename from migration/src/main/scala/akka/persistence/postgres/migration/PgSlickSupport.scala rename to migration/src/main/scala/org/apache/pekko/persistence/postgres/migration/PgSlickSupport.scala index 34fc3ef2..4582e73f 100644 --- a/migration/src/main/scala/akka/persistence/postgres/migration/PgSlickSupport.scala +++ b/migration/src/main/scala/org/apache/pekko/persistence/postgres/migration/PgSlickSupport.scala @@ -1,4 +1,4 @@ -package akka.persistence.postgres.migration +package org.apache.pekko.persistence.postgres.migration import io.circe.{ Json, Printer } import org.slf4j.{ Logger, LoggerFactory } diff --git a/migration/src/main/scala/akka/persistence/postgres/migration/journal/Jdbc4JournalMigration.scala b/migration/src/main/scala/org/apache/pekko/persistence/postgres/migration/journal/Jdbc4JournalMigration.scala similarity index 82% rename from migration/src/main/scala/akka/persistence/postgres/migration/journal/Jdbc4JournalMigration.scala rename to migration/src/main/scala/org/apache/pekko/persistence/postgres/migration/journal/Jdbc4JournalMigration.scala index 5ebd7831..bb45eb8a 100644 --- a/migration/src/main/scala/akka/persistence/postgres/migration/journal/Jdbc4JournalMigration.scala +++ b/migration/src/main/scala/org/apache/pekko/persistence/postgres/migration/journal/Jdbc4JournalMigration.scala @@ -1,16 +1,16 @@ -package akka.persistence.postgres.migration.journal - -import akka.Done -import akka.actor.ActorSystem -import akka.persistence.postgres.JournalRow -import akka.persistence.postgres.config.JournalConfig -import akka.persistence.postgres.db.SlickExtension -import akka.persistence.postgres.journal.dao._ -import akka.persistence.postgres.migration.PgSlickSupport -import akka.persistence.postgres.tag.{ CachedTagIdResolver, SimpleTagDao } -import akka.serialization.{ Serialization, SerializationExtension } -import akka.stream.Materializer -import akka.stream.scaladsl.Source +package org.apache.pekko.persistence.postgres.migration.journal + +import org.apache.pekko.Done +import org.apache.pekko.actor.ActorSystem +import org.apache.pekko.persistence.postgres.JournalRow +import org.apache.pekko.persistence.postgres.config.JournalConfig +import org.apache.pekko.persistence.postgres.db.SlickExtension +import org.apache.pekko.persistence.postgres.journal.dao._ +import org.apache.pekko.persistence.postgres.migration.PgSlickSupport +import org.apache.pekko.persistence.postgres.tag.{ CachedTagIdResolver, SimpleTagDao } +import org.apache.pekko.serialization.{ Serialization, SerializationExtension } +import org.apache.pekko.stream.Materializer +import org.apache.pekko.stream.scaladsl.Source import com.typesafe.config.Config import slick.jdbc.{ JdbcBackend, ResultSetConcurrency, ResultSetType } @@ -23,7 +23,7 @@ class Jdbc4JournalMigration(globalConfig: Config, tempTableName: String = "tmp_j mat: Materializer) extends PgSlickSupport { - import akka.persistence.postgres.db.ExtendedPostgresProfile.api._ + import org.apache.pekko.persistence.postgres.db.ExtendedPostgresProfile.api._ import system.dispatcher private val db = { @@ -45,7 +45,7 @@ class Jdbc4JournalMigration(globalConfig: Config, tempTableName: String = "tmp_j new CachedTagIdResolver(tagDao, journalConfig.tagsConfig) } - private val migrationConf: Config = globalConfig.getConfig("akka-persistence-postgres.migration") + private val migrationConf: Config = globalConfig.getConfig("pekko-persistence-postgres.migration") private val migrationBatchSize: Int = migrationConf.getInt("batchSize") def run(): Future[Done] = { diff --git a/migration/src/main/scala/akka/persistence/postgres/migration/journal/JournalMigrationQueries.scala b/migration/src/main/scala/org/apache/pekko/persistence/postgres/migration/journal/JournalMigrationQueries.scala similarity index 93% rename from migration/src/main/scala/akka/persistence/postgres/migration/journal/JournalMigrationQueries.scala rename to migration/src/main/scala/org/apache/pekko/persistence/postgres/migration/journal/JournalMigrationQueries.scala index 1e1e7bb5..7dbf85a6 100644 --- a/migration/src/main/scala/akka/persistence/postgres/migration/journal/JournalMigrationQueries.scala +++ b/migration/src/main/scala/org/apache/pekko/persistence/postgres/migration/journal/JournalMigrationQueries.scala @@ -1,8 +1,8 @@ -package akka.persistence.postgres.migration.journal +package org.apache.pekko.persistence.postgres.migration.journal -import akka.persistence.postgres.JournalRow -import akka.persistence.postgres.config.JournalTableConfiguration -import akka.persistence.postgres.db.ExtendedPostgresProfile.api._ +import org.apache.pekko.persistence.postgres.JournalRow +import org.apache.pekko.persistence.postgres.config.JournalTableConfiguration +import org.apache.pekko.persistence.postgres.db.ExtendedPostgresProfile.api._ import io.circe.Json import slick.lifted.TableQuery diff --git a/migration/src/main/scala/akka/persistence/postgres/migration/journal/JournalSchema.scala b/migration/src/main/scala/org/apache/pekko/persistence/postgres/migration/journal/JournalSchema.scala similarity index 96% rename from migration/src/main/scala/akka/persistence/postgres/migration/journal/JournalSchema.scala rename to migration/src/main/scala/org/apache/pekko/persistence/postgres/migration/journal/JournalSchema.scala index d084332e..ccb16777 100644 --- a/migration/src/main/scala/akka/persistence/postgres/migration/journal/JournalSchema.scala +++ b/migration/src/main/scala/org/apache/pekko/persistence/postgres/migration/journal/JournalSchema.scala @@ -1,9 +1,9 @@ -package akka.persistence.postgres.migration.journal +package org.apache.pekko.persistence.postgres.migration.journal -import akka.actor.{ ActorSystem, ExtendedActorSystem } -import akka.persistence.postgres.config.{ JournalConfig, JournalPartitionsConfiguration, JournalTableConfiguration } -import akka.persistence.postgres.db.ExtendedPostgresProfile.api._ -import akka.persistence.postgres.journal.dao.{ JournalDao, NestedPartitionsJournalDao, PartitionedJournalDao } +import org.apache.pekko.actor.{ ActorSystem, ExtendedActorSystem } +import org.apache.pekko.persistence.postgres.config.{ JournalConfig, JournalPartitionsConfiguration, JournalTableConfiguration } +import org.apache.pekko.persistence.postgres.db.ExtendedPostgresProfile.api._ +import org.apache.pekko.persistence.postgres.journal.dao.{ JournalDao, NestedPartitionsJournalDao, PartitionedJournalDao } import org.slf4j.{ Logger, LoggerFactory } import scala.concurrent.ExecutionContext diff --git a/migration/src/main/scala/akka/persistence/postgres/migration/journal/OldJournalDeserializer.scala b/migration/src/main/scala/org/apache/pekko/persistence/postgres/migration/journal/OldJournalDeserializer.scala similarity index 58% rename from migration/src/main/scala/akka/persistence/postgres/migration/journal/OldJournalDeserializer.scala rename to migration/src/main/scala/org/apache/pekko/persistence/postgres/migration/journal/OldJournalDeserializer.scala index d4d33120..ce6cabdd 100644 --- a/migration/src/main/scala/akka/persistence/postgres/migration/journal/OldJournalDeserializer.scala +++ b/migration/src/main/scala/org/apache/pekko/persistence/postgres/migration/journal/OldJournalDeserializer.scala @@ -1,7 +1,7 @@ -package akka.persistence.postgres.migration.journal +package org.apache.pekko.persistence.postgres.migration.journal -import akka.persistence.PersistentRepr -import akka.serialization.Serialization +import org.apache.pekko.persistence.PersistentRepr +import org.apache.pekko.serialization.Serialization import scala.util.Try diff --git a/migration/src/main/scala/akka/persistence/postgres/migration/snapshot/Jdbc4SnapshotStoreMigration.scala b/migration/src/main/scala/org/apache/pekko/persistence/postgres/migration/snapshot/Jdbc4SnapshotStoreMigration.scala similarity index 82% rename from migration/src/main/scala/akka/persistence/postgres/migration/snapshot/Jdbc4SnapshotStoreMigration.scala rename to migration/src/main/scala/org/apache/pekko/persistence/postgres/migration/snapshot/Jdbc4SnapshotStoreMigration.scala index bff53a10..f3a13bd3 100644 --- a/migration/src/main/scala/akka/persistence/postgres/migration/snapshot/Jdbc4SnapshotStoreMigration.scala +++ b/migration/src/main/scala/org/apache/pekko/persistence/postgres/migration/snapshot/Jdbc4SnapshotStoreMigration.scala @@ -1,16 +1,16 @@ -package akka.persistence.postgres.migration.snapshot - -import akka.Done -import akka.actor.ActorSystem -import akka.persistence.SnapshotMetadata -import akka.persistence.postgres.config.SnapshotConfig -import akka.persistence.postgres.db.SlickExtension -import akka.persistence.postgres.migration.PgSlickSupport -import akka.persistence.postgres.snapshot.dao.ByteArraySnapshotSerializer -import akka.persistence.postgres.snapshot.dao.SnapshotTables.SnapshotRow -import akka.serialization.{ Serialization, SerializationExtension } -import akka.stream.Materializer -import akka.stream.scaladsl.Source +package org.apache.pekko.persistence.postgres.migration.snapshot + +import org.apache.pekko.Done +import org.apache.pekko.actor.ActorSystem +import org.apache.pekko.persistence.SnapshotMetadata +import org.apache.pekko.persistence.postgres.config.SnapshotConfig +import org.apache.pekko.persistence.postgres.db.SlickExtension +import org.apache.pekko.persistence.postgres.migration.PgSlickSupport +import org.apache.pekko.persistence.postgres.snapshot.dao.ByteArraySnapshotSerializer +import org.apache.pekko.persistence.postgres.snapshot.dao.SnapshotTables.SnapshotRow +import org.apache.pekko.serialization.{ Serialization, SerializationExtension } +import org.apache.pekko.stream.Materializer +import org.apache.pekko.stream.scaladsl.Source import com.typesafe.config.Config import slick.jdbc.{ JdbcBackend, ResultSetConcurrency, ResultSetType } @@ -23,7 +23,7 @@ class Jdbc4SnapshotStoreMigration(globalConfig: Config, tempTableName: String = mat: Materializer) extends PgSlickSupport { - import akka.persistence.postgres.db.ExtendedPostgresProfile.api._ + import org.apache.pekko.persistence.postgres.db.ExtendedPostgresProfile.api._ import system.dispatcher private val db = { @@ -37,7 +37,7 @@ class Jdbc4SnapshotStoreMigration(globalConfig: Config, tempTableName: String = private val snapshotTableConfig = snapshotConfig.snapshotTableConfiguration private lazy val snapshotQueries = new SnapshotMigrationQueries(snapshotTableConfig, tempTableName) - private val migrationConf: Config = globalConfig.getConfig("akka-persistence-postgres.migration") + private val migrationConf: Config = globalConfig.getConfig("pekko-persistence-postgres.migration") private val migrationBatchSize: Int = migrationConf.getInt("batchSize") def run(): Future[Done] = { diff --git a/migration/src/main/scala/akka/persistence/postgres/migration/snapshot/OldSnapshotDeserializer.scala b/migration/src/main/scala/org/apache/pekko/persistence/postgres/migration/snapshot/OldSnapshotDeserializer.scala similarity index 58% rename from migration/src/main/scala/akka/persistence/postgres/migration/snapshot/OldSnapshotDeserializer.scala rename to migration/src/main/scala/org/apache/pekko/persistence/postgres/migration/snapshot/OldSnapshotDeserializer.scala index 98ae1a42..055f109a 100644 --- a/migration/src/main/scala/akka/persistence/postgres/migration/snapshot/OldSnapshotDeserializer.scala +++ b/migration/src/main/scala/org/apache/pekko/persistence/postgres/migration/snapshot/OldSnapshotDeserializer.scala @@ -1,7 +1,7 @@ -package akka.persistence.postgres.migration.snapshot +package org.apache.pekko.persistence.postgres.migration.snapshot -import akka.persistence.serialization.Snapshot -import akka.serialization.Serialization +import org.apache.pekko.persistence.serialization.Snapshot +import org.apache.pekko.serialization.Serialization import scala.util.Try diff --git a/migration/src/main/scala/akka/persistence/postgres/migration/snapshot/SnapshotMigrationQueries.scala b/migration/src/main/scala/org/apache/pekko/persistence/postgres/migration/snapshot/SnapshotMigrationQueries.scala similarity index 81% rename from migration/src/main/scala/akka/persistence/postgres/migration/snapshot/SnapshotMigrationQueries.scala rename to migration/src/main/scala/org/apache/pekko/persistence/postgres/migration/snapshot/SnapshotMigrationQueries.scala index 142fb434..122ea0a1 100644 --- a/migration/src/main/scala/akka/persistence/postgres/migration/snapshot/SnapshotMigrationQueries.scala +++ b/migration/src/main/scala/org/apache/pekko/persistence/postgres/migration/snapshot/SnapshotMigrationQueries.scala @@ -1,8 +1,8 @@ -package akka.persistence.postgres.migration.snapshot +package org.apache.pekko.persistence.postgres.migration.snapshot -import akka.persistence.postgres.config.SnapshotTableConfiguration -import akka.persistence.postgres.db.ExtendedPostgresProfile.api._ -import akka.persistence.postgres.snapshot.dao.SnapshotTables.SnapshotRow +import org.apache.pekko.persistence.postgres.config.SnapshotTableConfiguration +import org.apache.pekko.persistence.postgres.db.ExtendedPostgresProfile.api._ +import org.apache.pekko.persistence.postgres.snapshot.dao.SnapshotTables.SnapshotRow import io.circe.Json import scala.concurrent.ExecutionContext diff --git a/migration/src/test/resources/base-migration.conf b/migration/src/test/resources/base-migration.conf index f156738e..8b5ef4a6 100644 --- a/migration/src/test/resources/base-migration.conf +++ b/migration/src/test/resources/base-migration.conf @@ -1,12 +1,12 @@ -akka { +pekko { stdout-loglevel = off // defaults to WARNING can be disabled with off. The stdout-loglevel is only in effect during system startup and shutdown log-dead-letters-during-shutdown = on loglevel = WARNING log-dead-letters = on log-config-on-start = off // Log the complete configuration at INFO level when the actor system is started - loggers = ["akka.event.slf4j.Slf4jLogger"] - logging-filter = "akka.event.slf4j.Slf4jLoggingFilter" + loggers = ["org.apache.pekko.event.slf4j.Slf4jLogger"] + logging-filter = "org.apache.pekko.event.slf4j.Slf4jLoggingFilter" persistence { journal.plugin = "postgres-journal" @@ -25,13 +25,13 @@ akka { } serializers { - jackson-cbor = "akka.serialization.jackson.JacksonCborSerializer" + jackson-cbor = "org.apache.pekko.serialization.jackson.JacksonCborSerializer" } } } slick { - profile = "akka.persistence.postgres.db.ExtendedPostgresProfile$" + profile = "org.apache.pekko.persistence.postgres.db.ExtendedPostgresProfile$" db { host = "localhost" url = "jdbc:postgresql://"localhost":5432/docker?reWriteBatchedInserts=true" diff --git a/migration/src/test/resources/flat-migration.conf b/migration/src/test/resources/flat-migration.conf index c1b7ced5..19c8f061 100644 --- a/migration/src/test/resources/flat-migration.conf +++ b/migration/src/test/resources/flat-migration.conf @@ -1,3 +1,3 @@ include "base-migration.conf" -postgres-journal.dao = "akka.persistence.postgres.journal.dao.FlatJournalDao" +postgres-journal.dao = "org.apache.pekko.persistence.postgres.journal.dao.FlatJournalDao" diff --git a/migration/src/test/resources/logback-test.xml b/migration/src/test/resources/logback-test.xml index c916e479..5e9fd870 100644 --- a/migration/src/test/resources/logback-test.xml +++ b/migration/src/test/resources/logback-test.xml @@ -26,8 +26,8 @@ - - + + diff --git a/migration/src/test/resources/nested-partitions-migration.conf b/migration/src/test/resources/nested-partitions-migration.conf index e776eea3..87210127 100644 --- a/migration/src/test/resources/nested-partitions-migration.conf +++ b/migration/src/test/resources/nested-partitions-migration.conf @@ -1,3 +1,3 @@ include "base-migration.conf" -postgres-journal.dao = "akka.persistence.postgres.journal.dao.NestedPartitionsJournalDao" +postgres-journal.dao = "org.apache.pekko.persistence.postgres.journal.dao.NestedPartitionsJournalDao" diff --git a/migration/src/test/resources/partitioned-migration.conf b/migration/src/test/resources/partitioned-migration.conf index 2963c878..8f391dd1 100644 --- a/migration/src/test/resources/partitioned-migration.conf +++ b/migration/src/test/resources/partitioned-migration.conf @@ -1,3 +1,3 @@ include "base-migration.conf" -postgres-journal.dao = "akka.persistence.postgres.journal.dao.PartitionedJournalDao" +postgres-journal.dao = "org.apache.pekko.persistence.postgres.journal.dao.PartitionedJournalDao" diff --git a/migration/src/test/scala/akka/persistence/postgres/migration/MigrationTest.scala b/migration/src/test/scala/org/apache/pekko/persistence/postgres/migration/MigrationTest.scala similarity index 93% rename from migration/src/test/scala/akka/persistence/postgres/migration/MigrationTest.scala rename to migration/src/test/scala/org/apache/pekko/persistence/postgres/migration/MigrationTest.scala index b2e5e5bf..fb1d2a79 100644 --- a/migration/src/test/scala/akka/persistence/postgres/migration/MigrationTest.scala +++ b/migration/src/test/scala/org/apache/pekko/persistence/postgres/migration/MigrationTest.scala @@ -1,15 +1,15 @@ -package akka.persistence.postgres.migration - -import akka.NotUsed -import akka.actor.ActorSystem -import akka.persistence.postgres.config.{ JournalConfig, SnapshotConfig } -import akka.persistence.postgres.db.ExtendedPostgresProfile.api._ -import akka.persistence.postgres.db.SlickExtension -import akka.persistence.postgres.migration.journal.Jdbc4JournalMigration -import akka.persistence.postgres.migration.snapshot.Jdbc4SnapshotStoreMigration -import akka.persistence.postgres.query.scaladsl.PostgresReadJournal -import akka.persistence.query.PersistenceQuery -import akka.stream.scaladsl.Source +package org.apache.pekko.persistence.postgres.migration + +import org.apache.pekko.NotUsed +import org.apache.pekko.actor.ActorSystem +import org.apache.pekko.persistence.postgres.config.{ JournalConfig, SnapshotConfig } +import org.apache.pekko.persistence.postgres.db.ExtendedPostgresProfile.api._ +import org.apache.pekko.persistence.postgres.db.SlickExtension +import org.apache.pekko.persistence.postgres.migration.journal.Jdbc4JournalMigration +import org.apache.pekko.persistence.postgres.migration.snapshot.Jdbc4SnapshotStoreMigration +import org.apache.pekko.persistence.postgres.query.scaladsl.PostgresReadJournal +import org.apache.pekko.persistence.query.PersistenceQuery +import org.apache.pekko.stream.scaladsl.Source import com.typesafe.config.{ Config, ConfigFactory } import org.flywaydb.core.Flyway import org.flywaydb.core.api.migration.{ BaseJavaMigration, Context } diff --git a/project/Dependencies.scala b/project/Dependencies.scala index 85251d0d..f212bbb2 100644 --- a/project/Dependencies.scala +++ b/project/Dependencies.scala @@ -4,7 +4,7 @@ object Dependencies { val Scala213 = "2.13.12" val ScalaVersions = Seq(Scala213) - val AkkaVersion = "2.6.16" + val PekkoVersion = "1.0.2" val FlywayVersion = "9.20.0" val ScaffeineVersion = "5.2.1" val ScalaTestVersion = "3.2.17" @@ -21,23 +21,23 @@ object Dependencies { "com.github.blemale" %% "scaffeine" % ScaffeineVersion, "com.github.tminglei" %% "slick-pg" % SlickPgVersion, "com.github.tminglei" %% "slick-pg_circe-json" % SlickPgVersion, - "com.typesafe.akka" %% "akka-slf4j" % AkkaVersion % Test, - "com.typesafe.akka" %% "akka-persistence-tck" % AkkaVersion % Test, - "com.typesafe.akka" %% "akka-stream-testkit" % AkkaVersion % Test, - "com.typesafe.akka" %% "akka-testkit" % AkkaVersion % Test, - "com.typesafe.akka" %% "akka-persistence-query" % AkkaVersion % Provided, + "org.apache.pekko" %% "pekko-slf4j" % PekkoVersion % Test, + "org.apache.pekko" %% "pekko-persistence-tck" % PekkoVersion % Test, + "org.apache.pekko" %% "pekko-stream-testkit" % PekkoVersion % Test, + "org.apache.pekko" %% "pekko-testkit" % PekkoVersion % Test, + "org.apache.pekko" %% "pekko-persistence-query" % PekkoVersion % Provided, "com.typesafe.slick" %% "slick" % SlickVersion, "com.typesafe.slick" %% "slick-hikaricp" % SlickVersion, "org.scalatest" %% "scalatest" % ScalaTestVersion % Test) ++ JdbcDrivers.map(_ % Test) val Migration: Seq[ModuleID] = Seq( - ("com.typesafe.akka" %% "akka-persistence-query" % AkkaVersion).exclude("com.typesafe", "ssl-config-core"), + ("org.apache.pekko" %% "pekko-persistence-query" % PekkoVersion).exclude("com.typesafe", "ssl-config-core"), "com.typesafe" %% "ssl-config-core" % SslConfigVersion).map(_ % Compile) ++ (Seq( "org.scalatest" %% "scalatest" % ScalaTestVersion, - "com.typesafe.akka" %% "akka-testkit" % AkkaVersion, + "org.apache.pekko" %% "pekko-testkit" % PekkoVersion, "ch.qos.logback" % "logback-classic" % LogbackVersion, - "com.typesafe.akka" %% "akka-slf4j" % AkkaVersion, - "com.typesafe.akka" %% "akka-serialization-jackson" % AkkaVersion, + "org.apache.pekko" %% "pekko-slf4j" % PekkoVersion, + "org.apache.pekko" %% "pekko-serialization-jackson" % PekkoVersion, "org.flywaydb" % "flyway-core" % FlywayVersion) ++ JdbcDrivers).map(_ % Test) } diff --git a/project/ProjectAutoPlugin.scala b/project/ProjectAutoPlugin.scala index aea3aa04..6962f4fb 100644 --- a/project/ProjectAutoPlugin.scala +++ b/project/ProjectAutoPlugin.scala @@ -13,7 +13,7 @@ object ProjectAutoPlugin extends AutoPlugin { organization := "com.swissborg", organizationName := "SwissBorg", organizationHomepage := None, - homepage := Some(url("https://github.com/SwissBorg/akka-persistence-postgres")), + homepage := Some(url("https://github.com/SwissBorg/pekko-persistence-postgres")), licenses := Seq("Apache-2.0" -> url("https://opensource.org/licenses/Apache-2.0")), description := "A plugin for storing events in a PostgreSQL journal", startYear := Some(2020), @@ -40,22 +40,22 @@ object ProjectAutoPlugin extends AutoPlugin { "-release:11"), Compile / doc / scalacOptions := scalacOptions.value ++ Seq( "-doc-title", - "Akka Persistence Postgres", + "Pekko Persistence Postgres", "-doc-version", version.value, "-sourcepath", (ThisBuild / baseDirectory).value.toString, "-skip-packages", - "akka.pattern", // for some reason Scaladoc creates this + "pekko.pattern", // for some reason Scaladoc creates this "-doc-source-url", { val branch = if (isSnapshot.value) "master" else s"v${version.value}" - s"https://github.com/SwissBorg/akka-persistence-postgres/tree/${branch}€{FILE_PATH_EXT}#L€{FILE_LINE}" + s"https://github.com/SwissBorg/pekko-persistence-postgres/tree/${branch}€{FILE_PATH_EXT}#L€{FILE_LINE}" }), // show full stack traces and test case durations Test / testOptions += Tests.Argument("-oDF"), scmInfo := Some( ScmInfo( - url("https://github.com/SwissBorg/akka-persistence-postgres"), - "git@github.com:SwissBorg/akka-persistence-postgres.git"))) + url("https://github.com/SwissBorg/pekko-persistence-postgres"), + "git@github.com:SwissBorg/pekko-persistence-postgres.git"))) } diff --git a/project/project-info.conf b/project/project-info.conf index ccd4edda..1ccf5d26 100644 --- a/project/project-info.conf +++ b/project/project-info.conf @@ -3,17 +3,17 @@ project-info { shared-info { jdk-versions: ["Adopt OpenJDK 8", "Adopt OpenJDK 11"] issues: { - url: "https://github.com/SwissBorg/akka-persistence-postgres/issues" + url: "https://github.com/SwissBorg/pekko-persistence-postgres/issues" text: "GitHub issues" } release-notes: { - url: "https://github.com/SwissBorg/akka-persistence-postgres/releases" + url: "https://github.com/SwissBorg/pekko-persistence-postgres/releases" text: "GitHub releases" } } core: ${project-info.shared-info} { - title: "Akka Persistence Postgres" - jpms-name: "akka.persistence.postgres" + title: "Pekko Persistence Postgres" + jpms-name: "org.apache.pekko.persistence.postgres" levels: [ { readiness: CommunityDriven @@ -23,8 +23,8 @@ project-info { ] } migration: ${project-info.shared-info} { - title: "Akka Persistence Postgres Migration" - jpms-name: "akka.persistence.postgres.migration" + title: "Pekko Persistence Postgres Migration" + jpms-name: "org.apache.pekko.persistence.postgres.migration" levels: [ { readiness: CommunityDriven