@NotThreadSafe public class BuildCompletedNotification extends AbstractCompletedNotification
This class is used to generate content for All Completed Builds Notifications, the Failed And First Successful Notifications and First Failed Job Notifications. If you wish to customise the default notifications, please see the online Bamboo documentation: http://confluence.atlassian.com/display/BAMBOO/Modifying+Notification+Templates
The notification templates are written in Freemarker markup. The object context below provides information about Bamboo builds that you can insert in the Freemarker markup of your notification templates.
Object Context:
ResultsSummary
BuildResults
Plan
LinkedJiraIssue
containing details from JIRA server if available
String
description of the trigger reason for this build (html for html emails, plain text for text emails)
List
of String
containing a truncated version of the build's error summary
Notification.HtmlImContentProvidingNotification
Modifier and Type | Field and Description |
---|---|
protected BuildResults |
buildResults |
plan, resultsSummary
NAVIGATION_SOURCE
Constructor and Description |
---|
BuildCompletedNotification(BranchStatusService branchStatusService,
CachedPlanManager cachedPlanManager,
VcsRepositoryViewerManager vcsRepositoryViewerManager,
RepositoryDefinitionManager repositoryDefinitionManager,
CustomVariableContext customVariableContext) |
Modifier and Type | Method and Description |
---|---|
String |
getDescription()
Text describing this notification object - used for logging/debugging purposes.
|
protected String |
getEmailSubjectTemplate() |
protected String |
getHtmlEmailTemplate() |
protected String |
getHtmlImTemplate() |
protected String |
getImTemplate() |
protected String |
getTextEmailTemplate() |
void |
init() |
protected void |
populateContext(Map<String,Object> context) |
getCommitUrl, getEmailSubject, getHtmlEmailContent, getHtmlImContent, getIMContent, getTextEmailContent, setResultsSummaryManager, setTemplateRenderer, setTriggerManager, updateEmail
addRecipient, applyDefaultCssStyles, excludeRecipient, getCommitUrl, getEvent, getExcludedNotificationRecipients, getNotificationRecipients, getPojoEvent, getRepositoryData, getRepositoryData, setEvent, setEvent, setExcludedNotificationRecipients, setNotificationRecipients
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
addRecipient, applyDefaultCssStyles, excludeRecipient, getEvent, getExcludedNotificationRecipients, getNotificationRecipients, getPojoEvent, setEvent, setEvent, setExcludedNotificationRecipients, setNotificationRecipients
protected BuildResults buildResults
@Inject public BuildCompletedNotification(BranchStatusService branchStatusService, CachedPlanManager cachedPlanManager, VcsRepositoryViewerManager vcsRepositoryViewerManager, RepositoryDefinitionManager repositoryDefinitionManager, CustomVariableContext customVariableContext)
@NotNull public String getDescription()
Notification
getDescription
in interface Notification
getDescription
in class AbstractCompletedNotification
public void init()
init
in class AbstractCompletedNotification
protected void populateContext(Map<String,Object> context)
populateContext
in class AbstractCompletedNotification
protected String getTextEmailTemplate()
getTextEmailTemplate
in class AbstractCompletedNotification
protected String getHtmlEmailTemplate()
getHtmlEmailTemplate
in class AbstractCompletedNotification
protected String getImTemplate()
getImTemplate
in class AbstractCompletedNotification
protected String getEmailSubjectTemplate()
getEmailSubjectTemplate
in class AbstractCompletedNotification
protected String getHtmlImTemplate()
getHtmlImTemplate
in class AbstractCompletedNotification
Copyright © 2020 Atlassian Software Systems Pty Ltd. All rights reserved.