Class JobFinishedSNSPublisher

java.lang.Object
com.netflix.genie.web.events.JobFinishedSNSPublisher
All Implemented Interfaces:
EventListener, org.springframework.context.ApplicationListener<JobStateChangeEvent>

public class JobFinishedSNSPublisher extends Object implements org.springframework.context.ApplicationListener<JobStateChangeEvent>
Publishes Amazon SNS notifications with detailed information about each completed job.
Since:
4.0.0
  • Field Details

    • properties

      protected final SNSNotificationsProperties properties
    • registry

      protected final io.micrometer.core.instrument.MeterRegistry registry
  • Constructor Details

    • JobFinishedSNSPublisher

      public JobFinishedSNSPublisher(com.amazonaws.services.sns.AmazonSNS snsClient, SNSNotificationsProperties properties, DataServices dataServices, io.micrometer.core.instrument.MeterRegistry registry, com.fasterxml.jackson.databind.ObjectMapper mapper)
      Constructor.
      Parameters:
      snsClient - Amazon SNS client
      properties - configuration properties
      dataServices - the DataServices instance to use
      registry - metrics registry
      mapper - object mapper
  • Method Details

    • onApplicationEvent

      public void onApplicationEvent(JobStateChangeEvent event)
      Specified by:
      onApplicationEvent in interface org.springframework.context.ApplicationListener<JobStateChangeEvent>
    • publishEvent

      protected void publishEvent(com.netflix.genie.web.events.AbstractSNSPublisher.EventType eventType, HashMap<String,Object> eventDetailsMap)