Class DataProcessorTemplateEmailMessage


  • public class DataProcessorTemplateEmailMessage
    extends TemplateEmailMessage
    This class define a template email message for end of step messages.
    Since:
    3.1
    Author:
    Laurent Jourdren
    • Constructor Detail

      • DataProcessorTemplateEmailMessage

        public DataProcessorTemplateEmailMessage​(Configuration conf,
                                                 String templateKey,
                                                 String defaultTemplateResource)
                                          throws IOException
        Public constructor.
        Parameters:
        conf - Configuration
        templateKey - template configuration key
        defaultTemplateResource - default path for the template in Java resources
        Throws:
        IOException - if an error occurs while reading the template file
    • Method Detail

      • endDataProcessorEmail

        public EmailMessage endDataProcessorEmail​(String subject,
                                                  RunId runId,
                                                  Path outputDirectory,
                                                  long startTime,
                                                  long endTime,
                                                  long outputSize,
                                                  long diskFree,
                                                  Map<String,​String> variables)
                                           throws Aozan3Exception
        Create an end of step message.
        Parameters:
        subject - email message
        runId - run ID
        outputDirectory - output directory of the step
        startTime - start time of the step
        endTime - end time of the step
        outputSize - output size of generated data
        diskFree - disk free space available at the end of the steo
        variables - variables for the template
        Returns:
        an email message
        Throws:
        Aozan3Exception - if an error occurs while creating the message