ReadOnly

class ReadOnly(collection: String? = null, serverMessage: String? = null) : KdrantException.Forbidden

The node is refusing writes while still serving reads (HTTP 403, read-only).

A subclass of Forbidden, and therefore of Unauthorized, so an existing catch keeps catching it and the sealed when stays exhaustive. That inheritance is a compatibility decision rather than a description: nothing is wrong with the credential. Qdrant answers a write with 403 both when the token may not write and when the node may not write, and until this class existed those two arrived as the same exception, which is the difference between fixing a token and adding a disk.

Retryable, unlike its parent: the node comes back when the condition that made it read-only is cleared. Reads against the same node keep working throughout, which is what makes this worth telling apart at all — a caller can degrade to read-only rather than stop.

Constructors

Link copied to clipboard
constructor(collection: String? = null, serverMessage: String? = null)

Properties

Link copied to clipboard
expect open val cause: Throwable?
Link copied to clipboard

the collection the refused operation named, when it named one.

Link copied to clipboard
expect open val message: String?
Link copied to clipboard
open override val retryable: Boolean

Whether the identical request could succeed later without being changed.