Package com.alibaba.otter.shared.common.utils.thread

Examples of com.alibaba.otter.shared.common.utils.thread.ExecutorTemplate.start()


    }

    private void doFileDetectCollector(Pipeline pipeline, List<FileData> fileDatas) {
        ExecutorTemplate executorTemplate = executorTemplateGetter.get();
        try {
            executorTemplate.start();
            // 重新设置下poolSize
            executorTemplate.adjustPoolSize(pipeline.getParameters().getFileLoadPoolSize());
            for (final FileData fileData : fileDatas) {
                // 提交进行多线程处理
                executorTemplate.submit(new Runnable() {
View Full Code Here


        }

        ExecutorTemplate executorTemplate = executorTemplateGetter.get();
        try {
            MDC.put(OtterConstants.splitPipelineLoadLogFileKey, String.valueOf(fileBatch.getIdentity().getPipelineId()));
            executorTemplate.start();
            // 重新设置下poolSize
            Pipeline pipeline = configClientService.findPipeline(fileBatch.getIdentity().getPipelineId());
            executorTemplate.adjustPoolSize(pipeline.getParameters().getFileLoadPoolSize());
            // 启动
            final List<FileData> result = Collections.synchronizedList(new ArrayList<FileData>());
View Full Code Here

    }

    private void doFileDetectCollector(Pipeline pipeline, List<FileData> fileDatas) {
        ExecutorTemplate executorTemplate = executorTemplateGetter.get();
        try {
            executorTemplate.start();
            // 重新设置下poolSize
            executorTemplate.adjustPoolSize(pipeline.getParameters().getFileLoadPoolSize());
            for (final FileData fileData : fileDatas) {
                // 提交进行多线程处理
                executorTemplate.submit(new Runnable() {
View Full Code Here

            RowBatch rowBatch = param.getRowBatch();
            final Pipeline pipeline = getPipeline(rowBatch.getIdentity().getPipelineId());
            List<EventData> eventDatas = rowBatch.getDatas();
            final Set<EventData> removeDatas = Collections.synchronizedSet(new HashSet<EventData>());// 使用set,提升remove时的查找速度
            executorTemplate = executorTemplateGetter.get();
            executorTemplate.start();
            // 重新设置下poolSize
            executorTemplate.adjustPoolSize(pipeline.getParameters().getExtractPoolSize());
            for (final EventData eventData : eventDatas) {
                List<DataMediaPair> dataMediaPairs = ConfigHelper.findDataMediaPairByMediaId(pipeline,
                    eventData.getTableId());
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.