DurabilityImpossibleException

Hi

Having a cluster with 4 data nodes, bucket with 1 replica, and transaction durability set to MAJORITY, and 1 failed-over node, we are facing below exception:

HTTP 500 Internal Server Error: Transaction failed: Transaction has failed with cause 'com.couchbase.client.core.error.DurabilityImpossibleException: With the current cluster configuration, the requested durability guarantees are impossible {“clientContext”:
{“txn.op”:“atrPending”}

,“completed”:true,“coreId”:“0x5b28e29e00000001”,“idempotent”:false,“lastChannelId”:“5B28E29E00000001/00000000CEB73395”,“lastDispatchedFrom”:“AAA:55448”,“lastDispatchedTo”:“AAA:11210”,“requestId”:283603,“requestType”:“SubdocMutateRequest”,“retried”:0,“service”:{“bucket”:“AAA”,“collection”:“_default”,“documentId”:“_txn:atr-619-#846”,“opaque”:“0x4451d”,“scope”:“_default”,“syncDurability”:“MAJORITY”,“type”:“kv”},“status”:“DURABILITY_IMPOSSIBLE”,“timeoutMs”:10000,“timings”:{“dispatchMicros”:809,“encodingMicros”:52,“totalDispatchMicros”:809,“totalServerMicros”:0,“totalMicros”:1098,“serverMicros”:0}

Increasing replica to 2 seems to have solved the issue. We are guessing setting durability to NONE might do the trick too, but this does not seem to be a reasonable setting, right?

What are the guidelines regarding this error with our current architecture?

We understand in case we have 2 failed-over nodes and 2 replicas we will face the error again? so requesting 3 number of replicas, being the max number possible, is it a recommended option? what other guidelines can we follow?

Please find screenshot attached:

Thanks in advance

This is a physical limitation of needing enough nodes to do the replication, and it seems like you have this figured out. When a node fails it should be replaced as soon as possible. If you are experiencing multiple simultaneous failed-over nodes, you should consider hosting your servers elsewhere. Three replicas is not supported with Durability.Majority ( Durability | Couchbase Docs )

One thing you could consider - depending on the importance of the data - is having your application retry the operation with less or no replication. This will only help if the bucket has a lower replication.

1 Like

In addition to what Michael says above, you are correct - this isn’t a supported setting for transactions as without durability you no longer have ACID guarantees.

1 Like