001    /**
002     * Copyright (c) 2010 Yahoo! Inc. All rights reserved.
003     * Licensed under the Apache License, Version 2.0 (the "License");
004     * you may not use this file except in compliance with the License.
005     * You may obtain a copy of the License at
006     *
007     *   http://www.apache.org/licenses/LICENSE-2.0
008     *
009     *  Unless required by applicable law or agreed to in writing, software
010     *  distributed under the License is distributed on an "AS IS" BASIS,
011     *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
012     *  See the License for the specific language governing permissions and
013     *  limitations under the License. See accompanying LICENSE file.
014     */
015    package org.apache.oozie.client;
016    
017    import java.util.Date;
018    
019    /**
020     * Bean that represents a SLA event
021     */
022    public interface SLAEvent {
023    
024        /**
025         * Defines the possible status of an SLA events or Job status for SLA events.
026         */
027        public static enum Status {
028            CREATED, STARTED, SUCCEEDED, KILLED, FAILED
029        }
030    
031        /**
032         * Defines the possible status of an SLA events.
033         */
034        public static enum SlaAppType {
035            COORDINATOR_ACTION, COORDINATOR_JOB, WORKFLOW_JOB, WORKFLOW_ACTION
036        }
037    
038        public long getEvent_id();
039    
040        public String getSlaId();
041    
042        public SlaAppType getAppType();
043    
044        public String getAppName();
045    
046        public String getUser();
047    
048        public String getGroupName();
049    
050        public String getParentClientId();
051    
052        public String getParentSlaId();
053    
054        public Date getExpectedStart();
055    
056        public Date getExpectedEnd();
057    
058        public Date getStatusTimestamp();
059    
060        public String getNotificationMsg();
061    
062        public String getAlertContact();
063    
064        public String getDevContact();
065    
066        public String getQaContact();
067    
068        public String getSeContact();
069    
070        public String getAlertFrequency();
071    
072        public String getAlertPercentage();
073    
074        public String getUpstreamApps();
075    
076        public Status getJobStatus();
077    
078        public String getJobData();
079    
080    }