You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@oozie.apache.org by ry...@apache.org on 2014/10/15 22:35:27 UTC
git commit: OOZIE-2009 Requeue CoordActionInputCheck in case of
permission error (ryota)
Repository: oozie
Updated Branches:
refs/heads/master 67a120ee7 -> 3badb2d0b
OOZIE-2009 Requeue CoordActionInputCheck in case of permission error (ryota)
Project: http://git-wip-us.apache.org/repos/asf/oozie/repo
Commit: http://git-wip-us.apache.org/repos/asf/oozie/commit/3badb2d0
Tree: http://git-wip-us.apache.org/repos/asf/oozie/tree/3badb2d0
Diff: http://git-wip-us.apache.org/repos/asf/oozie/diff/3badb2d0
Branch: refs/heads/master
Commit: 3badb2d0b5be6ee5ca22fe68ccde07abcc02c5c7
Parents: 67a120e
Author: egashira <ry...@yahoo.com>
Authored: Wed Oct 15 13:34:31 2014 -0700
Committer: egashira <ry...@yahoo.com>
Committed: Wed Oct 15 13:34:31 2014 -0700
----------------------------------------------------------------------
.../coord/CoordActionInputCheckXCommand.java | 27 ++++++++++++++++++--
release-log.txt | 1 +
2 files changed, 26 insertions(+), 2 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/oozie/blob/3badb2d0/core/src/main/java/org/apache/oozie/command/coord/CoordActionInputCheckXCommand.java
----------------------------------------------------------------------
diff --git a/core/src/main/java/org/apache/oozie/command/coord/CoordActionInputCheckXCommand.java b/core/src/main/java/org/apache/oozie/command/coord/CoordActionInputCheckXCommand.java
index 98fa169..b26c1e2 100644
--- a/core/src/main/java/org/apache/oozie/command/coord/CoordActionInputCheckXCommand.java
+++ b/core/src/main/java/org/apache/oozie/command/coord/CoordActionInputCheckXCommand.java
@@ -28,6 +28,7 @@ import java.util.Date;
import java.util.List;
import org.apache.hadoop.conf.Configuration;
+import org.apache.hadoop.security.AccessControlException;
import org.apache.oozie.CoordinatorActionBean;
import org.apache.oozie.CoordinatorJobBean;
import org.apache.oozie.ErrorCode;
@@ -253,6 +254,22 @@ public class CoordActionInputCheckXCommand extends CoordinatorXCommand<Void> {
updateCoordAction(coordAction, isChangeInDependency);
}
}
+ catch (AccessControlException e) {
+ LOG.error("Permission error in ActionInputCheck", e);
+ if (isTimeout(currentTime)) {
+ LOG.debug("Queueing timeout command");
+ Services.get().get(CallableQueueService.class)
+ .queue(new CoordActionTimeOutXCommand(coordAction, coordJob.getUser(), coordJob.getAppName()));
+ }
+ else {
+ // Requeue InputCheckCommand for permission denied error with longer interval
+ Services.get()
+ .get(CallableQueueService.class)
+ .queue(new CoordActionInputCheckXCommand(coordAction.getId(), coordAction.getJobId()),
+ 2 * getCoordInputCheckRequeueInterval());
+ }
+ updateCoordAction(coordAction, isChangeInDependency);
+ }
catch (Exception e) {
if (isTimeout(currentTime)) {
LOG.debug("Queueing timeout command");
@@ -567,8 +584,14 @@ public class CoordActionInputCheckXCommand extends CoordinatorXCommand<Void> {
catch (URIHandlerException e) {
coordAction.setErrorCode(e.getErrorCode().toString());
coordAction.setErrorMessage(e.getMessage());
- throw new IOException(e);
- } catch (URISyntaxException e) {
+ if (e.getCause() != null && e.getCause() instanceof AccessControlException) {
+ throw (AccessControlException) e.getCause();
+ }
+ else {
+ throw new IOException(e);
+ }
+ }
+ catch (URISyntaxException e) {
coordAction.setErrorCode(ErrorCode.E0906.toString());
coordAction.setErrorMessage(e.getMessage());
throw new IOException(e);
http://git-wip-us.apache.org/repos/asf/oozie/blob/3badb2d0/release-log.txt
----------------------------------------------------------------------
diff --git a/release-log.txt b/release-log.txt
index 9e8e9bf..353174c 100644
--- a/release-log.txt
+++ b/release-log.txt
@@ -1,5 +1,6 @@
-- Oozie 4.2.0 release (trunk - unreleased)
+OOZIE-2009 Requeue CoordActionInputCheck in case of permission error (ryota)
OOZIE-2005 Coordinator rerun fails to initialize error code and message (ryota)
OOZIE-1896 ZKUUIDService - Too many job submission fails (puru)
OOZIE-2019 SLA miss processed on server2 not send email (puru)