Expand description
§Message Processor Implementations for TAP Node
This module provides message processing functionality for TAP Node. Message processors serve as middleware in the message handling pipeline, allowing for validation, transformation, and filtering of messages as they flow through the system.
§Message Processing Pipeline
The TAP Node uses a pipeline architecture for message processing, where messages pass through a series of processors in sequence. Each processor can:
- Pass the message through unchanged
- Transform the message in some way
- Filter out (drop) messages based on certain criteria
- Perform side effects (logging, metrics collection, etc.)
§Processor Types
The module provides several built-in processor implementations:
LoggingMessageProcessor: Logs information about messages passing through the systemValidationMessageProcessor: Validates message structure and contentDefaultMessageProcessor: A simple pass-through processor with minimal functionalityCompositeMessageProcessor: Combines multiple processors into a processing chain
§Custom Processors
You can create custom processors by implementing the MessageProcessor trait. This
allows for specialized processing such as:
- Message transformation for protocol version compatibility
- Content-based filtering and routing
- Security scanning and anomaly detection
- Metrics collection and performance monitoring
§Processing Modes
Each processor implements two key methods:
process_incoming(): For messages received by the nodeprocess_outgoing(): For messages being sent from the node
This separation allows for different processing logic depending on message direction.
Structs§
- Default
Message Processor - Default message processor with core functionality
- Default
Message Processor Impl - Default message processor that logs and validates messages
- Logging
Message Processor - A message processor that logs messages
- Validation
Message Processor - A message processor that validates messages
Traits§
- Message
Processor - Trait for processing DIDComm messages in TAP nodes