[英]What are the differences between an Agent Job and a Deployment Group Job in Azure DevOps?
What are the differences between an Agent Job and a Deployment Group Job in Azure DevOps? Azure DevOps 中的代理作业和部署组作业有什么区别? What are the reason to create one or the other?
创建一个或另一个的原因是什么?
What are the differences between an Agent Job and a Deployment Group Job in Azure DevOps?
Azure DevOps 中的代理作业和部署组作业有什么区别?
Agent job:代理工作:
Run steps on an agent which in an agent pool .在代理池中的代理上运行步骤。
Deployment group jobs:部署组作业:
Run on machines in a deployment group .在部署组中的机器上运行。
These are the definition of them.这些是它们的定义。 You can see that, the fundamental difference between them is that the target when running the job are different.
可以看到,它们的根本区别在于运行作业时的目标不同。
For agent job, it can only run on one target at a time (unless set up parallel to run on multiple targets at a time, but parallel is essentially multiple jobs).对于代理作业,它一次只能在一个目标上运行(除非设置并行以一次在多个目标上运行,但并行本质上是多个作业)。 And deployment group job is, since the deployment group is multiple machines are bound in a group, it can run a job on multiple machines at a time.
而部署组作业是,由于部署组是多台机器绑定在一个组中,它可以一次在多台机器上运行一个作业。
In the usage scenario, Agent job can used in both Build and Release pipeline.在使用场景中, Agent 作业可以在 Build 和 Release 管道中使用。 But for Deployment agent job , it can only be used in Release pipeline for application/project deploy.
但是对于部署代理作业,它只能在发布管道中用于应用程序/项目部署。
What are the reason to create one or the other?
创建一个或另一个的原因是什么?
In build pipeline, it should no doubt that you can only use Agent job (or Agentless) job.在构建管道中,毫无疑问您只能使用代理作业(或无代理)作业。
I think what you concerned should be the usage in Release pipeline.我认为您关心的应该是发布管道中的用法。 As I mentioned above, these different jobs can all be used in Release pipeline, and they can all be used for project deployed.
正如我上面提到的,这些不同的作业都可以在发布管道中使用,它们都可以用于项目部署。
But in terms of specific use, it depends on the task you will use and the number of target servers you want to deploy to.但在具体使用方面,这取决于您将使用的任务以及您要部署到的目标服务器的数量。
Agent job:代理工作:
If your deployment target server number less than 5 objects, and need to deploy to multiple machines at the same time, you can set up a parallel job for Agent job .如果您的部署目标服务器数量少于 5 个对象,并且需要同时部署到多台机器上,您可以为Agent 作业设置并行作业。 The Agent job may take a little longer time than Deployment group job.
代理作业可能需要比部署组作业稍长的时间。 But because the number of deployed targets is not too much, the difference is not obvious.
但是因为部署的目标数量不是太多,所以区别并不明显。
Deployment group job:部署组作业:
For medium and large companies, the Deployment target objects are generally more than 10, even 100. It is most appropriate to use Deployment group job, because it can be deployed on different machines in one job.对于大中型企业,Deployment目标对象一般都在10个以上,甚至100个以上。使用Deployment group job最合适,因为一个job可以部署在不同的机器上。
In release, recommend you use Deployment group job if you have multiple targets to deploy to:在发布中,如果您有多个目标要部署到,建议您使用部署组作业:
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.