SSIS 主包设计请求反馈 - 运行一堆子包 [英] Feedback requested for SSIS Master package design - Running a bunch of Sub-Packages

查看:28
本文介绍了SSIS 主包设计请求反馈 - 运行一堆子包的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

总的来说,我正在寻找有关运行主包的两种不同设计选项的反馈.

Overall, I am looking for feedback regarding two different design options of running a master package.

我有一个被代理调用的包,它运行着一堆处理数据的包(我想我们现在已经达到了大约 50 个).

I have one package that Agent calls that runs a bunch of packages that process data (I think we are up to about 50 now).

最初的设计是将包分组为更小的块,称为董事会,这些块称为实际包.示例如下:

The original design was to group packages into smaller chunks called directorates which call the actual packages. Sample below:

我对这种方法看到(和经历)的一些看法是:1. 每个包都必须打开(即使没有必要运行,即没有文件存在)2. #1 为流程完成增加了很多时间3. 确保并行运行

A few perceptions I see (and experienced) with this approach is that: 1. Every package has to open (even if it is unnecessary to run ie no file present) 2. #1 adds so much time for the process to complete 3. Runs in parallel for sure

所以我开发了一种新方法,它只会运行具有必要文件的包,如果没有,则记录尝试.它更简洁,您不需要运行每个包的所有文件连接,因为您正在遍历它们.

So I developed a new approach which will only run the packages that have the necessary files and logs the attempt if not. It is so much cleaner and you don't need all the file connections for each package to run since you are iterating through them.

我不确定它是否并行运行(我实际上对此表示怀疑).

I am not sure it runs in parallel (I actually doubt it).

我正在添加填充在 foreach 中迭代的 ADO 对象的数据流,以演示正在处理的文件.

I am adding the dataflow that populates the ADO Object that is being iterated in foreach to demonstrate the files being processed.

注意:通常在 DEV 环境中要处理的文件并不多,但是,当部署到 TEST 和 PROD 时,将有大部分文件要处理.

Note: Usually in DEV environment there are not many files to be processed, however, when deploying to TEST and PROD there will be most files present to be processed.

我可以就这两种不同的方法获得一些反馈吗?

任何提供富有成效的反馈的人都会收到赞成票!!!

Anyone that provides productive feedback will recieve upvotes!!!

推荐答案

我会采用修改后的第一种方法,即类似 Inside package 的方法,使用 Script task 来检查文件是否存在于目标中.

I would go with modified first approach ie something like Inside package, use Script task to check if files are present in destination or not.

例如:

  1. 创建脚本任务和变量.

  1. 在脚本任务中,编写类似于下图的代码(逻辑是,如果找到文件则将其标记为真,否则标记为假):

  1. 现在使用这个标志来限制 DFT 的执行,如下所示:

唯一的缺点是,您必须对 50 个包进行更改,但这是一次性活动.您的并行执行将保持不变.

Only con is, you'll have to make changes in 50 packages, but this is a one time activity. Your parallel execution will remain intact.

这篇关于SSIS 主包设计请求反馈 - 运行一堆子包的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆