Class OutboxRecord.Builder

  • All Implemented Interfaces:

    
    public final class OutboxRecord.Builder
    
                        

    Builder class for creating new OutboxRecord instances.

    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
    • Field Summary

      Fields 
      Modifier and Type Field Description
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
    • Constructor Detail

      • OutboxRecord.Builder

        OutboxRecord.Builder()
    • Method Detail

      • aggregateId

         final OutboxRecord.Builder aggregateId(String aggregateId)

        Sets the aggregate ID for the outbox record.

        Parameters:
        aggregateId - Identifier of the aggregate
        Returns:

        this Builder instance for method chaining

      • eventType

         final OutboxRecord.Builder eventType(String eventType)

        Sets the event type for the outbox record.

        Parameters:
        eventType - Type/name of the event
        Returns:

        this Builder instance for method chaining

      • payload

         final OutboxRecord.Builder payload(String payload)

        Sets the payload for the outbox record.

        Parameters:
        payload - Event payload in serialized form
        Returns:

        this Builder instance for method chaining

      • build

         final OutboxRecord build(Clock clock)

        Builds the OutboxRecord with the configured values.

        Parameters:
        clock - Clock to use for timestamps (defaults to system UTC)
        Returns:

        A new OutboxRecord instance