Examples of StageResourceDriver


Examples of com.asakusafw.runtime.stage.resource.StageResourceDriver

        if (LOG.isDebugEnabled()) {
            LOG.debug(MessageFormat.format(
                    "Building join-table from \"{0}\" on distributed cache",
                    getCacheName()));
        }
        StageResourceDriver driver = new StageResourceDriver(configuration);
        try {
            List<Path> paths = driver.findCache(getCacheName());
            if (paths.isEmpty()) {
                throw new FileNotFoundException(MessageFormat.format(
                        "Missing resource \"{0}\" in distributed cache",
                        getCacheName()));
            }
            if (LOG.isDebugEnabled()) {
                LOG.debug(MessageFormat.format(
                        "Building join table \"{0}\" using \"{1}\"",
                        getCacheName(),
                        paths));
            }
            try {
                table = createTable(driver, paths);
            } catch (IOException e) {
                throw new IOException(MessageFormat.format(
                        "Failed to build a join table from \"{0}\"",
                        getCacheName()), e);
            }
            if (LOG.isDebugEnabled()) {
                LOG.debug(MessageFormat.format(
                        "Built join-table from \"{0}\"",
                        getCacheName()));
            }
        } finally {
            driver.close();
        }
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.