Repository: falcon
Updated Branches:
  refs/heads/master b6d2c134b -> 9a4c18c7d


FALCON-2088 Entity submission fails with EntityNotRegisteredException in 
distributed mode

… in distributed mode

Author: Praveen Adlakha <[email protected]>

Reviewers: "Pallavi Rao <[email protected]>"

Closes #232 from PraveenAdlakha/2088


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

Branch: refs/heads/master
Commit: 9a4c18c7d380334756df84f89f57dabc42437008
Parents: b6d2c13
Author: Praveen Adlakha <[email protected]>
Authored: Tue Jul 19 11:31:37 2016 -0700
Committer: bvellanki <[email protected]>
Committed: Tue Jul 19 11:31:37 2016 -0700

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


http://git-wip-us.apache.org/repos/asf/falcon/blob/9a4c18c7/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 185c830..aefd699 100644
--- a/prism/src/main/java/org/apache/falcon/resource/AbstractEntityManager.java
+++ b/prism/src/main/java/org/apache/falcon/resource/AbstractEntityManager.java
@@ -169,21 +169,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) {

Reply via email to