Class IngestionEventPublisher

java.lang.Object
com.minicrm.mini_crm_api.messaging.IngestionEventPublisher

@Service public class IngestionEventPublisher extends Object
A dedicated service for publishing data ingestion events to RabbitMQ. This decouples the API controllers from the actual data persistence logic.
  • Constructor Details

    • IngestionEventPublisher

      public IngestionEventPublisher()
  • Method Details

    • publishCustomerIngestionEvent

      public void publishCustomerIngestionEvent(CustomerDTO customerDTO)
      Publishes an event to ingest a new customer.
      Parameters:
      customerDTO - The DTO containing the new customer's data.
    • publishOrderIngestionEvent

      public void publishOrderIngestionEvent(OrderDTO orderDTO)
      Publishes an event to ingest a new order.
      Parameters:
      orderDTO - The DTO containing the new order's data.