namespace ZB.MOM.WW.LocalDb.Replication;

/// <summary>
/// Thrown when a peer sends replication data whose schema this node cannot honor: an oplog entry
/// for a table not registered for replication here. Unlike a poison entry (dead-lettered per-row),
/// this is a protocol violation between the two nodes' registered schemas, so the whole batch is
/// rejected before any of it is applied. Task 10 reuses it to fail the handshake closed.
/// </summary>
public sealed class LocalDbSchemaMismatchException : Exception
{
    /// <summary>Creates the exception with a message describing the schema disagreement.</summary>
    public LocalDbSchemaMismatchException(string message) : base(message) { }

    /// <summary>Creates the exception with a message and the underlying cause.</summary>
    public LocalDbSchemaMismatchException(string message, Exception innerException)
        : base(message, innerException) { }
}
