diff options
author | Jon Marius Venstad <jvenstad@yahoo-inc.com> | 2017-10-06 11:10:02 +0200 |
---|---|---|
committer | Jon Marius Venstad <jvenstad@yahoo-inc.com> | 2017-10-06 11:10:02 +0200 |
commit | 61b7515f2e51aa8ccc1095d890d69e8e860c8422 (patch) | |
tree | 3ba05ffba08f7b1de519e87d6363a2c20f63c83a /controller-api | |
parent | 80d54b0d844c964b0ce1cf42cce3f0373ef327a4 (diff) |
Add interface to replace Issues, Contacts, Properties
Diffstat (limited to 'controller-api')
-rw-r--r-- | controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/AutonomousCarbonUnitsWhoFixApplications.java | 67 |
1 files changed, 67 insertions, 0 deletions
diff --git a/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/AutonomousCarbonUnitsWhoFixApplications.java b/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/AutonomousCarbonUnitsWhoFixApplications.java new file mode 100644 index 00000000000..c635d62265f --- /dev/null +++ b/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/AutonomousCarbonUnitsWhoFixApplications.java @@ -0,0 +1,67 @@ +package com.yahoo.vespa.hosted.controller.api.integration; + +import com.yahoo.config.provision.ApplicationId; + +import java.util.Collection; + +/** + * Represents the people responsible for keeping Vespa up and running in a given organization, etc.. + * + * @author jvenstad + */ +public interface AutonomousCarbonUnitsWhoFixApplications { + + /** + * Notifies those responsible for the application with the given ID of failing deployments. + * + * @param applicationId ID of the application with failing deployments. + * @return ID of the created issue. + */ + IssueID fileIssue(ApplicationId applicationId); + + /** + * Notifies those responsible for the Vespa platform that too many applications are failing. + * + * @param applicationIds IDs of all applications with failing deployments. + * @return ID of the created issue. + */ + IssueID fileIssue(Collection<ApplicationId> applicationIds); + + /** + * @param issueID ID of the issue to escalate. + */ + void escalateIssue(IssueID issueID); + + /** + * @param issueID ID of the issue to examine. + * @return Whether the given issue is under investigation. + */ + boolean isOpen(IssueID issueID); + + /** + * @param issueID IF of the issue to examine. + * @return Whether the given issue is actively worked on. + */ + boolean isActive(IssueID issueID); + + + class IssueID { + + protected final String id; + + private IssueID(String id) { + this.id = id; + } + + @Override + public String toString() { + return id; + } + + public static IssueID from(String value) { + return new IssueID(value); + } + + } + +} |