falcon-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From b...@apache.org
Subject falcon git commit: FALCON-2088 Entity submission fails with EntityNotRegisteredException in distributed mode
Date Tue, 19 Jul 2016 18:31:50 GMT
Repository: falcon
Updated Branches:
  refs/heads/0.10 b1025c7ed -> 3b05c17fe


FALCON-2088 Entity submission fails with EntityNotRegisteredException in distributed mode

… in distributed mode

Author: Praveen Adlakha <adlakha.praveen@gmail.com>

Reviewers: "Pallavi Rao <pallavi@apache.org>"

Closes #232 from PraveenAdlakha/2088

(cherry picked from commit 9a4c18c7d380334756df84f89f57dabc42437008)
Signed-off-by: bvellanki <bvellanki@hortonworks.com>


Project: http://git-wip-us.apache.org/repos/asf/falcon/repo
Commit: http://git-wip-us.apache.org/repos/asf/falcon/commit/3b05c17f
Tree: http://git-wip-us.apache.org/repos/asf/falcon/tree/3b05c17f
Diff: http://git-wip-us.apache.org/repos/asf/falcon/diff/3b05c17f

Branch: refs/heads/0.10
Commit: 3b05c17fe267e792be5c0a3eff77ba3752a73561
Parents: b1025c7
Author: Praveen Adlakha <adlakha.praveen@gmail.com>
Authored: Tue Jul 19 11:31:37 2016 -0700
Committer: bvellanki <bvellanki@hortonworks.com>
Committed: Tue Jul 19 11:31:46 2016 -0700

----------------------------------------------------------------------
 .../falcon/resource/AbstractEntityManager.java    | 18 +++---------------
 1 file changed, 3 insertions(+), 15 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/falcon/blob/3b05c17f/prism/src/main/java/org/apache/falcon/resource/AbstractEntityManager.java
----------------------------------------------------------------------
diff --git a/prism/src/main/java/org/apache/falcon/resource/AbstractEntityManager.java b/prism/src/main/java/org/apache/falcon/resource/AbstractEntityManager.java
index bf47d44..8ba9b82 100644
--- a/prism/src/main/java/org/apache/falcon/resource/AbstractEntityManager.java
+++ b/prism/src/main/java/org/apache/falcon/resource/AbstractEntityManager.java
@@ -167,21 +167,9 @@ public abstract class AbstractEntityManager extends AbstractMetadataResource
{
 
             Set<String> clusters = EntityUtil.getClustersDefined(entity);
             Set<String> colos = new HashSet<String>();
-            try{
-                // Fix for Falcon-1749
-                EntityType entitytype =  EntityType.getEnum(type);
-                if (entitytype == EntityType.PROCESS || entitytype == EntityType.FEED){
-                    EntityUtil.getEntity(entitytype, entity.getName());
-                }
-                for (String cluster : clusters) {
-                    Cluster clusterEntity = EntityUtil.getEntity(EntityType.CLUSTER, cluster);
-                    colos.add(clusterEntity.getColo());
-                }
-            }catch (EntityNotRegisteredException e){
-                LOG.warn(e.getMessage(), e);
-            }
-            if (colos.isEmpty()) {
-                throw new EntityNotRegisteredException(entity.getName()  + " (" + type +
") not found");
+            for (String cluster : clusters) {
+                Cluster clusterEntity = EntityUtil.getEntity(EntityType.CLUSTER, cluster);
+                colos.add(clusterEntity.getColo());
             }
             return colos;
         } catch (FalconException e) {


Mime
View raw message