[
https://issues.apache.org/jira/browse/FALCON-297?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13894367#comment-13894367
]
Srikanth Sundarrajan commented on FALCON-297:
---------------------------------------------
Are we silently ignoring the user's effective time, if it happens to be outside
the range of the entity ?
{code}
+ private Date validateEffectiveTime(Entity entity, String cluster, Date
effectiveTime) {
+ Date start = EntityUtil.getStartTime(entity, cluster);
+ Date end = EntityUtil.getEndTime(entity, cluster);
+ if (effectiveTime == null || effectiveTime.before(start) ||
effectiveTime.after(end)) {
+ return null;
+ }
+ return effectiveTime;
+ }
{code}
> Validations on update with effective time
> -----------------------------------------
>
> Key: FALCON-297
> URL: https://issues.apache.org/jira/browse/FALCON-297
> Project: Falcon
> Issue Type: Bug
> Reporter: Shwetha G S
> Assignee: Shwetha G S
> Fix For: 0.5
>
> Attachments: FALCON-297.patch
>
>
> Effective time should be validated against start and end of entity. Also,
> when new bundle is not created because effectiveTime = endTime throws
> exception:
> 2014-02-03 07:08:26,011 ERROR -
> [1451544186@qtp-1790118163-0:samarth.gupta:POST//sync/update/process/agregator-coord16-47c507d2-7ac0-4f11-88f7-94653de28b56-36dac363-8dca-48ab-aa55
> -34fcafafc8d7 c6bbe757-e13f-4f95-a14a-d6e1cd0108aa] ~ Updation failed
> (AbstractEntityManager:269)
> java.lang.IllegalArgumentException: jobId cannot be null
> at org.apache.oozie.client.OozieClient.notEmpty(OozieClient.java:1443)
> at
> org.apache.oozie.client.OozieClient$BundleJobInfo.<init>(OozieClient.java:907)
> at org.apache.oozie.client.OozieClient.getBundleJobInfo(OozieClient.java:953)
> at
> org.apache.falcon.workflow.engine.OozieWorkflowEngine.getBundleInfo(OozieWorkflowEngine.java:1029)
> at
> org.apache.falcon.workflow.engine.OozieWorkflowEngine.updateInternal(OozieWorkflowEngine.java:975)
> at
> org.apache.falcon.workflow.engine.OozieWorkflowEngine.update(OozieWorkflowEngine.java:827)
> Thanks [~samarthg] for pointing these
--
This message was sent by Atlassian JIRA
(v6.1.5#6160)