Reading the writes on Instance A done by Instance B

We are facing an issue with the janusgraph cluster having around 20 instances. The issue here is that if we are writing a vertex on instance A and try to read it from other instance it takes few seconds for the write to reflect on other instances. I have checked that storage.batch-loading is set to false.
3 Replies
Bo
Bo13mo ago
Is cache.db-cache turned off?
shivam.choudhary
shivam.choudhary13mo ago
Yes, I checked it is set to false.
porunov
porunov13mo ago
It could potentially be related to transactions (could be that you use the same transaction to check for the vertex existence, but transactions have it's own cache and if they read something once - they cache it until you transaction cache overflows which causes for the vertex to be really re-fetched from the database). To prevent this issue - ensure you are using freshly started transactions to read data and don't reuse the same transaction (don't forget to close the old transaction to prevent transaction data leak). It could also be related to consistency settings if your database is eventually consistent. For example, if you use Cassandra and have consistency level ONE both for read and write operations then it could happen that your write wasn't reflected on all nodes yet but your read operations are using nodes with stale data.