Package org.openmetadata.service.util
Class EmailUtil
java.lang.Object
org.openmetadata.service.util.EmailUtil
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final String -
Method Summary
Modifier and TypeMethodDescriptionstatic Stringstatic Stringstatic Stringstatic Stringstatic StringgetOMUrl()static Stringstatic SmtpSettingsstatic Stringstatic Stringstatic Stringstatic BooleanisValidEmail(String email) Check if given email address is validstatic voidsendAccountStatus(User user, String action, String status) static voidsendChangeEventMail(String receiverMail, EmailMessage emailMessaged) static voidsendDataInsightEmailNotificationToUser(Set<String> emails, String startDate, String endDate, DataInsightTotalAssetTemplate totalAssetObj, DataInsightDescriptionAndOwnerTemplate descriptionObj, DataInsightDescriptionAndOwnerTemplate ownerShipObj, DataInsightDescriptionAndOwnerTemplate tierObj, String subject, String templateFilePath) static voidsendEmailVerification(String emailVerificationLink, User user) static voidsendInviteMailToAdmin(User user, String pwd) static voidsendMail(String subject, Map<String, Object> model, String to, String baseTemplatePackage, String templatePath, boolean async) static voidsendMail(org.simplejavamail.api.email.Email email, boolean async) static voidsendMailToMultiple(String subject, Map<String, Object> model, Set<String> to, String baseTemplatePackage, String templatePath) static voidsendPasswordResetLink(String passwordResetLink, User user, String subject, String templateFilePath) static voidsendTaskAssignmentNotificationToUser(String assigneeName, String email, String taskLink, Thread thread, String subject, String templateFilePath) static voidsendTestEmail(String email, boolean async) static void
-
Field Details
-
USERNAME
- See Also:
-
ENTITY
- See Also:
-
SUPPORT_URL
- See Also:
-
EMAIL_TEMPLATE_BASEPATH
- See Also:
-
EMAIL_VERIFICATION_LINKKEY
- See Also:
-
EMAIL_VERIFICATION_TEMPLATE_PATH
- See Also:
-
PASSWORD_RESET_LINKKEY
- See Also:
-
EXPIRATION_TIME_KEY
- See Also:
-
DEFAULT_EXPIRATION_TIME
- See Also:
-
PASSWORD
- See Also:
-
APPLICATION_LOGIN_LINK
- See Also:
-
PASSWORD_RESET_TEMPLATE_FILE
- See Also:
-
ACTION_KEY
- See Also:
-
ACTION_STATUS_KEY
- See Also:
-
ACCOUNT_STATUS_TEMPLATE_FILE
- See Also:
-
INVITE_RANDOM_PWD
- See Also:
-
CHANGE_EVENT_TEMPLATE
- See Also:
-
INVITE_CREATE_PWD
- See Also:
-
TASK_NOTIFICATION_TEMPLATE
- See Also:
-
DATA_INSIGHT_REPORT_TEMPLATE
- See Also:
-
TEST_EMAIL_TEMPLATE
- See Also:
-
TEST_EMAIL_SUBJECT
- See Also:
-
-
Method Details
-
sendAccountStatus
public static void sendAccountStatus(User user, String action, String status) throws IOException, freemarker.template.TemplateException - Throws:
IOExceptionfreemarker.template.TemplateException
-
sendEmailVerification
public static void sendEmailVerification(String emailVerificationLink, User user) throws IOException, freemarker.template.TemplateException - Throws:
IOExceptionfreemarker.template.TemplateException
-
sendPasswordResetLink
public static void sendPasswordResetLink(String passwordResetLink, User user, String subject, String templateFilePath) throws IOException, freemarker.template.TemplateException - Throws:
IOExceptionfreemarker.template.TemplateException
-
sendTaskAssignmentNotificationToUser
public static void sendTaskAssignmentNotificationToUser(String assigneeName, String email, String taskLink, Thread thread, String subject, String templateFilePath) throws IOException, freemarker.template.TemplateException - Throws:
IOExceptionfreemarker.template.TemplateException
-
sendMail
public static void sendMail(String subject, Map<String, Object> model, String to, String baseTemplatePackage, String templatePath, boolean async) throws IOException, freemarker.template.TemplateException- Throws:
IOExceptionfreemarker.template.TemplateException
-
sendMailToMultiple
public static void sendMailToMultiple(String subject, Map<String, Object> model, Set<String> to, String baseTemplatePackage, String templatePath) throws IOException, freemarker.template.TemplateException- Throws:
IOExceptionfreemarker.template.TemplateException
-
sendMail
public static void sendMail(org.simplejavamail.api.email.Email email, boolean async) -
sendInviteMailToAdmin
-
sendChangeEventMail
-
sendDataInsightEmailNotificationToUser
public static void sendDataInsightEmailNotificationToUser(Set<String> emails, String startDate, String endDate, DataInsightTotalAssetTemplate totalAssetObj, DataInsightDescriptionAndOwnerTemplate descriptionObj, DataInsightDescriptionAndOwnerTemplate ownerShipObj, DataInsightDescriptionAndOwnerTemplate tierObj, String subject, String templateFilePath) throws IOException, freemarker.template.TemplateException - Throws:
IOExceptionfreemarker.template.TemplateException
-
sendTestEmail
public static void sendTestEmail(String email, boolean async) throws IOException, freemarker.template.TemplateException - Throws:
IOExceptionfreemarker.template.TemplateException
-
testConnection
public static void testConnection() -
getPasswordResetSubject
-
getEmailInviteSubject
-
getChangeEventTemplate
-
getTaskAssignmentSubject
-
getTestEmailSubject
-
getDataInsightReportSubject
-
getEmailingEntity
-
getSupportUrl
-
getOMUrl
-
getSmtpSettings
-
isValidEmail
Check if given email address is valid- Parameters:
email- email address- Returns:
- true if valid, false otherwise
-