Class StreamerFactory

java.lang.Object
energy.eddie.aiida.streamers.StreamerFactory

public class StreamerFactory extends Object
  • Method Details

    • getAiidaStreamer

      protected static AiidaStreamer getAiidaStreamer(UUID aiidaId, FailedToSendRepository failedToSendRepository, com.fasterxml.jackson.databind.ObjectMapper mapper, Permission permission, reactor.core.publisher.Flux<AiidaRecord> recordFlux, reactor.core.publisher.Sinks.One<UUID> terminationRequestSink, PermissionLatestRecordMap permissionLatestRecordMap) throws org.eclipse.paho.mqttv5.common.MqttException
      Creates a new AiidaStreamer applying the specified streamingConfig.
      Parameters:
      aiidaId - UUID of the AIIDA instance for which to create the AiidaStreamer.
      failedToSendRepository - Repository to save messages that could not be sent.
      mapper - ObjectMapper that should be used to convert the records to JSON.
      permission - Permission for which to create the AiidaStreamer.
      recordFlux - Flux on which the records that should be sent are published.
      terminationRequestSink - Sink, to which the permissionId will be published when the EP requests a termination.
      Throws:
      org.eclipse.paho.mqttv5.common.MqttException - If the creation of the MqttClient failed.