#[derive(Clone, Copy, Debug, Eq, PartialEq)]
pub enum ReplicationStreamErrorV3 {
ForeignLineage,
StaleEpoch,
HistoryPruned,
UnsupportedFormat,
UnsupportedCatalog,
UnsupportedBounds,
InvalidPosition,
CorruptHistory,
Unavailable,
}
impl std::fmt::Display for ReplicationStreamErrorV3 {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
f.write_str(match self {
Self::ForeignLineage => "foreign replication lineage",
Self::StaleEpoch => "stale replication epoch",
Self::HistoryPruned => "replication history has been pruned",
Self::UnsupportedFormat => "unsupported replication format",
Self::UnsupportedCatalog => "unsupported replication catalog",
Self::UnsupportedBounds => "unsupported replication bounds",
Self::InvalidPosition => "invalid replication resume position",
Self::CorruptHistory => "invalid replication history",
Self::Unavailable => "replication source is unavailable",
})
}
}
impl std::error::Error for ReplicationStreamErrorV3 {}