Package org.apache.falcon

Examples of org.apache.falcon.FalconException


    private String pathValue(Method method, Object... args) throws FalconException {

        Path pathParam = method.getAnnotation(Path.class);
        if (pathParam == null) {
            throw new FalconException("No path param mentioned for " + method);
        }
        String pathValue = pathParam.value();

        Annotation[][] paramAnnotations = method.getParameterAnnotations();
        StringBuilder queryString = new StringBuilder("?");
View Full Code Here


                                      String annotationAttribute) throws FalconException {
        try {
            return String.valueOf(paramAnnotation.annotationType().
                    getMethod(annotationAttribute).invoke(paramAnnotation));
        } catch (Exception e) {
            throw new FalconException("Unable to get attribute value for "
                    + paramAnnotation + "[" + annotationAttribute + "]");
        }
    }
View Full Code Here

        FileSystem fs;
        try {
            fs = getFileSystem(cluster);
            fs.getConf().set("dfs.umaskmode", "022")// drwxr-xr-x
        } catch (Exception e) {
            throw new FalconException("Unable to connect to HDFS: "
                    + ClusterHelper.getStorageUrl(cluster), e);
        }
        if (!fs.exists(target)) {
            fs.mkdirs(target);
        }
View Full Code Here

            FileSystem fs = HadoopClientFactory.get().createFileSystem(lineageDataPath.toUri());

            BufferedReader in = new BufferedReader(new InputStreamReader(fs.open(lineageDataPath)));
            return (Map<String, String>) JSONValue.parse(in);
        } catch (IOException e) {
            throw new FalconException("Error opening lineage file", e);
        }
    }
View Full Code Here

            throw new ValidationException(e);
        } catch (ConnectException e) {
            throw new ValidationException(
                    "Unable to connect to Namenode: " + nameNode + " referenced in cluster: " + clusterName);
        } catch (Exception e) {
            throw new FalconException(e);
        }
    }
View Full Code Here

                        "Process start time: " + start + " should be before process end time: " + end);
            }
        } catch (ValidationException e) {
            throw new ValidationException(e);
        } catch (Exception e) {
            throw new FalconException(e);
        }
    }
View Full Code Here

    public static <T extends Entity> T getEntity(String type, String entityName) throws FalconException {
        EntityType entityType;
        try {
            entityType = EntityType.valueOf(type.toUpperCase());
        } catch (IllegalArgumentException e) {
            throw new FalconException("Invalid entity type: " + type, e);
        }
        return getEntity(entityType, entityName);
    }
View Full Code Here

    public static Date parseDateUTC(String dateStr) throws FalconException {
        try {
            return SchemaHelper.parseDateUTC(dateStr);
        } catch (Exception e) {
            throw new FalconException(e);
        }
    }
View Full Code Here

                            mapToProperties(map.get(key), name != null ? name + "." + key : key, propMap,
                                    filterProps);
                        }
                    }
                } catch (Exception e1) {
                    throw new FalconException(e1);
                }
            } catch (Exception e) {
                throw new FalconException(e);
            }
        }
    }
View Full Code Here

            return retry;
        case PROCESS:
            Process process = (Process) entity;
            return process.getRetry();
        default:
            throw new FalconException("Cannot create Retry for entity:" + entity.getName());
        }
    }
View Full Code Here

TOP

Related Classes of org.apache.falcon.FalconException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.