Comments (5)
Transactions are committed in this line, so it is expected that metadata and journal are written atomically.
Could you check some logs to confirm that transactions are written correctly?
I'm poor at postgresql but commit logs like MySQL's binlog maybe exist.
from akka-persistence-sql-async.
I'll see if I can build a minimal replication case and get some logs, although I'm not a PostgreSQL expert.
from akka-persistence-sql-async.
I've created a project that replicates the issue here: https://github.com/ColinScott/persist-test
I'm hosting the PostgreSQL instance in a docker image based on the official PostgreSQL image. You can run this with docker run --name some-postgres -e POSTGRES_PASSWORD=qazxsw21 -p 5432:5432 -d abstractcode/akka-postgres:9.4.6
.
My first test run for this resulted in 7460 entries in the persistence_metadata table but none in the persistence_journal table. I didn't find any useful logs in the docker container running the database after this test (or indeed any PostgreSQL logs at all).
from akka-persistence-sql-async.
Thanks for your minimal existence and it makes me realize the cause.
About inconsistency
PersistentActor replays existent a snapshot and journals first after creating.
PersistentActor of akka-persistent-sql-async
inserts into metadata table on replaying those if its metadata has not yet created.
Something like inconsistency happened due to that, but it is not inconsistency.
So you can run com.abstractcode.persisttest.TestMain
with few Items(e.g. 1 to 100) on records created on high load.
Tests by TCK uses internal APIs directly, so I have observed transaction boundaries on such an abnormal environments.
About errors
Being related to underlying libraries, followings are guesses……
postgresql-async
seems to collapse and becomes non-available once its buffer is overflowed.
That buffer is parameterized by configuring wait-queue-capacity
parameter.
However, buffers will be overflowed sometime if too many queries which postgresql cannot handle.
So you should take care of high loads.
akka-stream
looks good for this problem……
from akka-persistence-sql-async.
Thanks for looking at this.
from akka-persistence-sql-async.
Related Issues (19)
- An exception causes bad sql to be generated HOT 3
- Help for migration HOT 2
- PostgreSQL message/record size HOT 2
- Serialize as Json HOT 4
- How to close the debug info? HOT 3
- Don't swallow journal serialization errors. HOT 8
- New release HOT 2
- SSL Connection HOT 1
- Support for multiple Database configurations HOT 2
- Update homepage table instructions HOT 1
- SSL mode is not being parsed HOT 2
- Publish for Scala 2.12 HOT 1
- Change pass to password in configuration HOT 1
- Publish version 0.1.1 for password HOT 1
- Incompatible with Akka 2.4-M2 persistence API HOT 12
- Taking a snapshot and deleting old messages causes highest sequence nr to be reset HOT 9
- Implementing Persistence Query HOT 8
- Serialize writing events for the same persistence id
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from akka-persistence-sql-async.