-
Notifications
You must be signed in to change notification settings - Fork 112
FALCON-2077 Api support for Process SLA #278
Conversation
Result of Dev Testing : $ bin/falcon entity -type process -slaAlert -name ProcessInstanceRerunTest-agregator-33 -start 2016-08-30T07:30Z -end 2016-08-30T08:30Z name: ProcessInstanceRerunTest-agregator-33, type: PROCESS, cluster: local, instanceTime: 2016-08-30T07:30Z, tags: Missed-SLA-High |
Hi All, EntitySLAAlertServiceTest might fail just wanted to make sure its not my machine issue.Will see what is needed to be done if it fails. Thanks |
* if the entityType is not valid. | ||
* */ | ||
|
||
public static void checkEntityType(String entityType)throws FalconException { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can't you use EntityType.getEnum(entityType) instead?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
After discussed moving it to EntityType as EntityType.getEnum will not serve the complete purpose of the function.
@PraveenAdlakha, are you taking up corresponding CLI changes as part of a separate JIRA? |
My bad. Didn't notice that you had tested against CLI itself. Which means the CLI changes were already in place. Please ignore my comment on the CLI change. |
@@ -111,16 +111,29 @@ protected synchronized void scheduleInternal(String type, String entity, Boolean | |||
} | |||
} | |||
|
|||
/** | |||
* Validates the parameters wheather SLA is supported or not. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit : Typo. Should be "whether"
ec8d20f
to
a4c3686
Compare
@@ -101,6 +101,16 @@ public boolean isSchedulable() { | |||
return ((this != EntityType.CLUSTER) && (this != EntityType.DATASOURCE)); | |||
} | |||
|
|||
public static void assertSchedulable(String entityType){ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you use EntityType.getEnum inside this method? This method will be pretty much similar to AbstractSchedulableEntityManager.checkSchedulableEntity, except, the exception may be different.
Other than the minor nit. +1. |
@pallavi-rao have made the changes please review. |
Merging this... |
Author: Praveen Adlakha <adlakha.praveen@gmail.com> Reviewers: @pallavi-rao Closes apache#278 from PraveenAdlakha/2077_v1 and squashes the following commits: 3b89e83 [Praveen Adlakha] changed method in EntityType a4c3686 [Praveen Adlakha] comments addressed 860d055 [Praveen Adlakha] FALCON-2077 Api support for Process SLA
Author: Praveen Adlakha <adlakha.praveen@gmail.com> Reviewers: @pallavi-rao Closes apache#278 from PraveenAdlakha/2077_v1 and squashes the following commits: 3b89e83 [Praveen Adlakha] changed method in EntityType a4c3686 [Praveen Adlakha] comments addressed 860d055 [Praveen Adlakha] FALCON-2077 Api support for Process SLA
No description provided.