Package com.asakusafw.bulkloader.exception

Examples of com.asakusafw.bulkloader.exception.BulkLoaderSystemException


                        exporterBean.getJobflowId(),
                        exporterBean.getJobflowSid(),
                        exporterBean.getExecutionId());
                ExportDataCopy copy = createExportDataCopy();
                if (!copy.copyData(exporterBean)) {
                    throw new BulkLoaderSystemException(getClass(), "TG-RECOVERER-01012",
                            exporterBean.getTargetName(),
                            exporterBean.getBatchId(),
                            exporterBean.getJobflowId(),
                            exporterBean.getJobflowSid(),
                            exporterBean.getExecutionId());
                } else {
                    // 更新レコードのコピーが全て終了しているかを表すフラグを取得
                    updateEnd = copy.isUpdateEnd();
                    LOG.info("TG-RECOVERER-01020",
                            exporterBean.getTargetName(),
                            exporterBean.getBatchId(),
                            exporterBean.getJobflowId(),
                            exporterBean.getJobflowSid(),
                            exporterBean.getExecutionId());
                }
            }

            // エクスポートテンポラリテーブルの削除及びロック解除を行う
            LOG.info("TG-RECOVERER-01021",
                    exporterBean.getTargetName(),
                    exporterBean.getBatchId(),
                    exporterBean.getJobflowId(),
                    exporterBean.getJobflowSid(),
                    exporterBean.getExecutionId());
            LockRelease lock = createLockRelease();
            if (!lock.releaseLock(exporterBean, updateEnd)) {
                // ロックの解除に失敗
                throw new BulkLoaderSystemException(getClass(), "TG-RECOVERER-01013",
                        exporterBean.getTargetName(),
                        exporterBean.getBatchId(),
                        exporterBean.getJobflowId(),
                        exporterBean.getJobflowSid(),
                        exporterBean.getExecutionId());
            } else {
                LOG.info("TG-RECOVERER-01022",
                        exporterBean.getTargetName(),
                        exporterBean.getBatchId(),
                        exporterBean.getJobflowId(),
                        exporterBean.getJobflowSid(),
                        exporterBean.getExecutionId());
            }

            // 処理結果をログに出力
            if (rollBack) {
                LOG.info("TG-RECOVERER-01014",
                        exporterBean.getTargetName(),
                        exporterBean.getBatchId(),
                        exporterBean.getJobflowId(),
                        exporterBean.getJobflowSid(),
                        exporterBean.getExecutionId(),
                        "ロールバック");
            } else {
                if (updateEnd) {
                    LOG.info("TG-RECOVERER-01014",
                            exporterBean.getTargetName(),
                            exporterBean.getBatchId(),
                            exporterBean.getJobflowId(),
                            exporterBean.getJobflowSid(),
                            exporterBean.getExecutionId(),
                            "ロールフォワード");
                } else {
                    throw new BulkLoaderSystemException(getClass(), "TG-RECOVERER-01015",
                            exporterBean.getTargetName(),
                            exporterBean.getBatchId(),
                            exporterBean.getJobflowId(),
                            exporterBean.getJobflowSid(),
                            exporterBean.getExecutionId(),
View Full Code Here


            boolean hasParam) throws BulkLoaderSystemException {
        String executionId = exporterBean.getExecutionId();
        // ジョブフロー実行テーブルにレコードが存在しない場合はエラーとする
        List<ExporterBean> beans = selectRunningJobFlow(executionId);
        if (beans.size() == 0) {
            throw new BulkLoaderSystemException(getClass(), "TG-RECOVERER-01009",
                    exporterBean.getTargetName(),
                    exporterBean.getBatchId(),
                    exporterBean.getJobflowId(),
                    exporterBean.getJobflowSid(),
                    exporterBean.getExecutionId());
View Full Code Here

    protected void loadParam(ExporterBean exporterBean) throws BulkLoaderSystemException {
        // DSLプロパティを読み込み
        JobFlowParamLoader paramLoader = createJobFlowParamLoader();
        if (!paramLoader.loadRecoveryParam(
                exporterBean.getTargetName(), exporterBean.getBatchId(), exporterBean.getJobflowId())) {
            throw new BulkLoaderSystemException(getClass(), "TG-RECOVERER-01007",
                    "DSLプロパティ",
                    MessageFormat.format(
                            "ターゲット名:{0}, バッチID:{1}, ジョブフローID:{2}" ,
                            exporterBean.getTargetName(),
                            exporterBean.getBatchId(),
                            exporterBean.getJobflowId()),
                    exporterBean.getExecutionId());
        }
        exporterBean.setExportTargetTable(paramLoader.getExportTargetTables());
        exporterBean.setImportTargetTable(paramLoader.getImportTargetTables());

        // リトライ回数・リトライインターバルを読み込み
        String count = ConfigurationLoader.getProperty(Constants.PROP_KEY_EXP_RETRY_COUNT);
        String interval = ConfigurationLoader.getProperty(Constants.PROP_KEY_EXP_RETRY_INTERVAL);
        try {
            exporterBean.setRetryCount(Integer.parseInt(count));
            exporterBean.setRetryInterval(Integer.parseInt(interval));
        } catch (NumberFormatException e) {
            throw new BulkLoaderSystemException(getClass(), "TG-RECOVERER-01007",
                    "リトライ回数,リトライインターバル",
                    count + "," + interval,
                    exporterBean.getExecutionId());
        }
    }
View Full Code Here

        List<ExportTempTableBean> tempBean = null;
        try {
            tempBean = getExportTempTable(exporterBean.getJobflowSid());
        } catch (BulkLoaderSystemException e) {
            LOG.log(e);
            throw new BulkLoaderSystemException(getClass(), "TG-RECOVERER-01011",
                    exporterBean.getTargetName(),
                    exporterBean.getBatchId(),
                    exporterBean.getJobflowId(),
                    exporterBean.getJobflowSid(),
                    exporterBean.getExecutionId());
View Full Code Here

                LOG.info("TG-GCCACHE-03007", protocol.getLocation(), result);
                FileProtocol response = new FileProtocol(result, protocol.getLocation(), null);
                output.openNext(response).close();
            }
        } catch (IOException e) {
            throw new BulkLoaderSystemException(e, getClass(), "TG-GCCACHE-03005",
                    targetName, userName);
        }
    }
View Full Code Here

                        try {
                            DBConnection.rollback(conn);
                            Thread.sleep(TimeUnit.SECONDS.toMillis(retryInterval));
                            continue;
                        } catch (InterruptedException e2) {
                            throw new BulkLoaderSystemException(e2, getClass(), "TG-IMPORTER-02002");
                        }
                    } else {
                        // リトライ不可の場合、異常終了する。
                        throw new BulkLoaderReRunnableException(e, getClass(), "TG-IMPORTER-02003");
                    }
View Full Code Here

            }
            provider.waitForComplete();
            reportResults(targetName, results);
            return results;
        } catch (IOException e) {
            throw new BulkLoaderSystemException(e, getClass(), "TG-GCCACHE-02004",
                    targetName);
        } catch (InterruptedException e) {
            throw new BulkLoaderSystemException(e, getClass(), "TG-GCCACHE-02004",
                    targetName);
        } finally {
            if (provider != null) {
                try {
                    provider.close();
View Full Code Here

        try {
            return tableInfo.getImportTargetType()
                .asSubclass(ThunderGateCacheSupport.class)
                .newInstance();
        } catch (Exception e) {
            throw new BulkLoaderSystemException(e, getClass(), "TG-IMPORTER-11011",
                    tableName,
                    tableInfo.getCacheId(),
                    tableInfo.getImportTargetType().getName());
        }
    }
View Full Code Here

                    bean.getJobflowId(),
                    bean.getExecutionId(),
                    result.size());
            return result;
        } catch (IOException e) {
            throw new BulkLoaderSystemException(e, getClass(), "TG-IMPORTER-12004",
                    bean.getTargetName(),
                    bean.getBatchId(),
                    bean.getJobflowId(),
                    bean.getExecutionId());
        } catch (InterruptedException e) {
            throw new BulkLoaderSystemException(e, getClass(), "TG-IMPORTER-12004",
                    bean.getTargetName(),
                    bean.getBatchId(),
                    bean.getJobflowId(),
                    bean.getExecutionId());
        } finally {
View Full Code Here

                        try {
                            DBConnection.rollback(conn);
                            Thread.sleep(TimeUnit.SECONDS.toMillis(retryInterval));
                            continue;
                        } catch (InterruptedException e1) {
                            throw new BulkLoaderSystemException(e1, getClass(), "TG-EXPORTER-04001",
                                    "IMPORT_TABLE_LOCKテーブルのロック取得に失敗");
                        }
                    } else {
                        // リトライ不可の場合、異常終了する。
                        throw new BulkLoaderSystemException(getClass(), "TG-EXPORTER-04002",
                                "IMPORT_TABLE_LOCKテーブルのロック取得に失敗");
                    }
                }
            }
View Full Code Here

TOP

Related Classes of com.asakusafw.bulkloader.exception.BulkLoaderSystemException

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.