TFS2010 - 并行构建 - 单一解决方案、单一构建代理

发布于 2024-12-28 20:11:57 字数 168 浏览 2 评论 0原文

我们有 TFS2010 和一个包含近 20000 个项目的解决方案(是的,我知道,这是个坏主意,不是我的!)。通过解耦代码以实现高水平的构建并发性,我将 4 核(8 个超级)机器上的构建时间从按顺序完成的 4 分钟缩短到大约 30 秒。我现在想在构建服务器上受益,这一定是可能的,因为 MSBuild 支持并行构建。如何?

We have TFS2010 and a single solution with nearly 200 hundred projects (Yes, I know, bad idea, not mine!). I have the build time down to circa 30 seconds on a 4 core (8 hyper) machine from 4 minutes done sequentially by decoupling code to enable a high level of build concurrency. I would now like to get the benefit of that on the build server, this must be possible as MSBuild supports parallel build. How?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

深海不蓝 2025-01-04 20:11:57

您可以通过编辑构建属性在 Team Build 2010 中并行运行构建。

  1. 在团队资源管理器中打开构建列表
  2. 右键单击要编辑的构建,然后选择编辑构建定义...
  3. 选择左侧的流程选项卡并展开<右侧的strong>高级属性
  4. 在MSBuild Arguments属性中添加/maxcpucount/m
  5. 保存并关闭

这是一个屏幕截图:

Team Build 2010 构建过程属性

另请参阅

You can run builds in parallel in Team Build 2010 by editing your build properties.

  1. Open the list of builds in Team Explorer
  2. Right click on the build you want to edit and choose Edit Build Definition...
  3. Select the Process tab on the left and expand the Advanced properties on the right
  4. In the MSBuild Arguments property add /maxcpucount or /m
  5. Save and close

Here's a screenshot:

Team Build 2010 build process properties

See also

作死小能手 2025-01-04 20:11:57

如果默认情况下未启用并行编译,请转到生成定义的“Process-Advanced”选项卡上的“其他 MSBuild 参数”属性并添加“/m”命令行开关

If parallel compilation is not enabled by default, go to Additional MSBuild parameters property on build definition's "Process-Advanced" tab and add "/m" command line switch

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文