Message Validation
Extension method reference
// Connection settings validation
IEnumerable<ValidationResult> ValidateConnectionSettings(
this IChannelSchema schema, ConnectionSettings settings)
// Message property validation only
IEnumerable<ValidationResult> ValidateMessageProperties(
this IChannelSchema schema, IDictionary<string, object?> properties)
// Full message validation
IEnumerable<ValidationResult> ValidateMessage(
this IChannelSchema schema, IMessage message)
// Schema identity
string GetLogicalIdentity(this IChannelSchema schema)
// Schema compatibility
bool IsCompatibleWith(this IChannelSchema schema, IChannelSchema other)
// Restriction validation
IEnumerable<ValidationResult> ValidateAsRestrictionOf(
this IChannelSchema schema, IChannelSchema target)
// Authentication support
ICollection<AuthenticationType> GetAuthenticationTypes(this IChannelSchema)
bool SupportsAuthenticationType(this IChannelSchema, AuthenticationType)ValidateMessage
What it checks
Example
Common validation failures
Scenario
Error message
ValidateConnectionSettings
ValidateMessageProperties
Schema identity and compatibility
Authentication support queries
Early validation pattern
Batch validation
Unit testing validation
ValidationResult
Last updated