Skip to content

Commit

Permalink
Add integration test.
Browse files Browse the repository at this point in the history
  • Loading branch information
rtar committed Nov 16, 2023
1 parent 76d9b78 commit c6d69ea
Show file tree
Hide file tree
Showing 3 changed files with 46 additions and 3 deletions.
35 changes: 34 additions & 1 deletion persistence/src/main/resources/reference.conf
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,39 @@ evolutiongaming.kafka-journal.persistence {
json-codec = default
}

snapshot {

class = "akka.persistence.kafka.journal.CassandraSnapshotStore"

plugin-dispatcher = "evolutiongaming.kafka-journal.persistence.dispatcher"

persistence-id-to-key {
impl = "constant-topic" # valid values: constant-topic, split
constant-topic {
topic = "journal"
}
}

cassandra {
client {
name = "journal"
query {
fetch-size = 1000
consistency = "LOCAL_QUORUM"
default-idempotence = true
}
}
}

circuit-breaker {
max-failures = 100
call-timeout = 130s // should be higher than producer.delivery-timeout
reset-timeout = 1m
}

json-codec = default
}

dispatcher {
type = "Dispatcher"
executor = "fork-join-executor"
Expand All @@ -64,4 +97,4 @@ evolutiongaming.kafka-journal.persistence {
parallelism-max = 32
}
}
}
}
4 changes: 2 additions & 2 deletions tests/src/test/resources/application.conf
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ akka {
log-dead-letters-during-shutdown = off
persistence {
journal.plugin = "evolutiongaming.kafka-journal.persistence.journal"
snapshot-store.plugin = "akka.persistence.no-snapshot-store"
snapshot-store.plugin = "evolutiongaming.kafka-journal.persistence.snapshot"
}

test {
Expand Down Expand Up @@ -58,4 +58,4 @@ evolutiongaming.kafka-journal {

cassandra = ${evolutiongaming.kafka-journal.cassandra}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
package akka.persistence.kafka.journal

import akka.persistence.snapshot.SnapshotStoreSpec
import com.typesafe.config.ConfigFactory

class SnapshotSpec extends SnapshotStoreSpec(ConfigFactory.load("integration.conf")) {

override def supportsSerialization = false

}

0 comments on commit c6d69ea

Please sign in to comment.