From c7e925ba624eee7e386855251169aecbafd6ae7d Mon Sep 17 00:00:00 2001 From: Silv3rcircl3 Date: Wed, 2 Dec 2015 15:44:16 +0100 Subject: [PATCH] fixe sqlite.conf and readme --- .../Akka.Persistence.Sqlite/README.md | 6 ++--- .../Akka.Persistence.Sqlite/sqlite.conf | 26 +++++++++++-------- 2 files changed, 18 insertions(+), 14 deletions(-) diff --git a/src/contrib/persistence/Akka.Persistence.Sqlite/README.md b/src/contrib/persistence/Akka.Persistence.Sqlite/README.md index 5eaad2d2cb7..974908dfed7 100644 --- a/src/contrib/persistence/Akka.Persistence.Sqlite/README.md +++ b/src/contrib/persistence/Akka.Persistence.Sqlite/README.md @@ -1,6 +1,6 @@ ## Akka.Persistence.Sqlite -Akka Persistence journal and snapshot store backed by SQL Server database. +Akka Persistence journal and snapshot store backed by SQLite database. **WARNING: Akka.Persistence.Sqlite plugin is still in beta and it's mechanics described bellow may be still subject to change**. @@ -13,7 +13,7 @@ akka.persistence.journal.plugin = "akka.persistence.journal.sqlite" akka.persistence.journal.sqlite.connection-string = "" ``` -Similar configuration may be used to setup a SQL Server snapshot store: +Similar configuration may be used to setup a SQLite snapshot store: ``` akka.persistence.snapshot-store.plugin = "akka.persistence.snapshot-store.sqlite" @@ -28,7 +28,7 @@ Both journal and snapshot store share the same configuration keys (however they - `class` (string with fully qualified type name) - determines class to be used as a persistent journal. Default: *Akka.Persistence.Sqlite.Journal.SqliteJournal, Akka.Persistence.Sqlite* (for journal) and *Akka.Persistence.Sqlite.Snapshot.SqliteSnapshotStore, Akka.Persistence.Sqlite* (for snapshot store). - `plugin-dispatcher` (string with configuration path) - describes a message dispatcher for persistent journal. Default: *akka.actor.default-dispatcher* -- `connection-string` - connection string used to access SQL Server database. Default: *none*. +- `connection-string` - connection string used to access SQLite database. Default: *none*. - `connection-timeout` - timespan determining default connection timeouts on database-related operations. Default: *30s* - `table-name` - name of the table used by either journal or snapshot store. Default: *event_journal* (for journal) or *snapshot_store* (for snapshot store) - `auto-initialize` - flag determining if journal or snapshot store related tables should by automatically created when they have not been found in connected database. Default: *false* diff --git a/src/contrib/persistence/Akka.Persistence.Sqlite/sqlite.conf b/src/contrib/persistence/Akka.Persistence.Sqlite/sqlite.conf index 23e99edc74a..cce8b8c9b42 100644 --- a/src/contrib/persistence/Akka.Persistence.Sqlite/sqlite.conf +++ b/src/contrib/persistence/Akka.Persistence.Sqlite/sqlite.conf @@ -1,10 +1,11 @@ akka.persistence{ journal { + sqlite { - # qualified type name of the SQL Server persistence journal actor - class = "Akka.Persistence.SqlServer.Journal.SqlServerJournal, Akka.Persistence.SqlServer" + # qualified type name of the SQLite persistence journal actor + class = "Akka.Persistence.Sqlite.Journal.SqliteJournal, Akka.Persistence.Sqlite" # dispatcher used to drive journal actor plugin-dispatcher = "akka.actor.default-dispatcher" @@ -15,13 +16,13 @@ # connection string name for .config file used when no connection string has been provided connection-string-name = "" - # default SQL commands timeout + # default SQLite commands timeout connection-timeout = 30s - # SQL server schema name to table corresponding with persistent journal + # SQLite schema name to table corresponding with persistent journal schema-name = dbo - # SQL server table corresponding with persistent journal + # SQLite table corresponding with persistent journal table-name = event_journal # should corresponding journal table be initialized automatically @@ -29,17 +30,19 @@ # timestamp provider used for generation of journal entries timestamps timestamp-provider = "Akka.Persistence.Sql.Common.Journal.DefaultTimestampProvider, Akka.Persistence.Sql.Common" + } } snapshot-store { + sqlite { - # qualified type name of the SQL Server persistence journal actor - class = "Akka.Persistence.SqlServer.Snapshot.SqlServerSnapshotStore, Akka.Persistence.SqlServer" + # qualified type name of the SQLite persistence journal actor + class = "Akka.Persistence.Sqlite.Snapshot.SqliteSnapshotStore, Akka.Persistence.Sqlite" # dispatcher used to drive journal actor - plugin-dispatcher = ""akka.actor.default-dispatcher"" + plugin-dispatcher = "akka.actor.default-dispatcher" # connection string used for database access connection-string = "" @@ -47,17 +50,18 @@ # connection string name for .config file used when no connection string has been provided connection-string-name = "" - # default SQL commands timeout + # default SQLite commands timeout connection-timeout = 30s - # SQL server schema name to table corresponding with persistent journal + # SQLite schema name to table corresponding with persistent journal schema-name = dbo - # SQL server table corresponding with persistent journal + # SQLite table corresponding with persistent journal table-name = snapshot_store # should corresponding journal table be initialized automatically auto-initialize = off + } } } \ No newline at end of file