Azure管道无法并行运行矩阵作业

Azure管道无法并行运行矩阵作业,azure,parallel-processing,rust,azure-devops,Azure,Parallel Processing,Rust,Azure Devops,尽管设置了推荐的设置,我始终按顺序运行azure管道。我希望在两个linux/windows中并行运行: trigger: branches: include: - 'master' strategy: maxParallel: 2 matrix: windows-stable: imageName: 'windows-latest' rustup_toolchain: stable linux-stable:

尽管设置了推荐的设置,我始终按顺序运行azure管道。我希望在两个linux/windows中并行运行:

trigger:
  branches:
    include:
      - 'master'

strategy:
  maxParallel: 2
  matrix:
    windows-stable:
      imageName: 'windows-latest'
      rustup_toolchain: stable
    linux-stable:
      imageName: 'ubuntu-latest'
      rustup_toolchain: stable

pool:
  vmImage: $(imageName)

steps:
  - script: |
      sudo apt-get update &&
      sudo apt-get install wget ca-certificates &&
      sudo apt install libncursesw5-dev
      wget --quiet -O - https://www.postgresql.org/media/keys/ACCC4CF8.asc | sudo apt-key add -
      sudo sh -c 'echo "deb http://apt.postgresql.org/pub/repos/apt/ `lsb_release -cs`-pgdg main" >> /etc/apt/sources.list.d/pgdg.list'
      sudo apt-get update &&
      sudo apt-get install libpq-dev postgresql-11 postgresql-contrib-11 postgresql-client-11
      echo "host    all             all             127.0.0.1/32            md5" > sudo tee -a /etc/postgresql/11/main/pg_hba.conf &&
      sudo service postgresql restart && sleep 3 &&
      sudo -u postgres psql -c "CREATE DATABASE \"BestSeller2\"" &&
      sudo -u postgres psql -c "ALTER USER postgres PASSWORD 'pinkycerebro';" &&
               sudo service postgresql restart && sleep 3
    displayName: Install PG
    condition: ne( variables['Agent.OS'], 'Windows_NT' )
  - script: |
      choco install llvm
      refreshenv
    displayName: Install CLANG
    condition: eq( variables['Agent.OS'], 'Windows_NT' )

  - script: cargo test --all
    displayName: Cargo test

Azure DevOps对您可以同时启动的并行作业的数量有限制。这取决于您的场景:

  • Microsoft托管CI/CD。在发表这篇文章时,私人项目有1份免费工作(运行时间不超过60分钟),公共项目有10份免费工作
  • 自托管CI/CD。在回答这个问题时,每个VisualStudio企业订户有1个免费工作+1个免费额外工作,或者公共项目有无限的工作
  • 所以,我建议你先检查一下,这是否是我们没有平行化的原因 你的管道。如果你在一个没有任何VS企业订阅的私人项目上,你应该考虑移动到公共项目或者保持至少两个代理池(一个自托管的Ci/CD其他用于微软托管的Ci/CD),如果你想得到某种程度的分类。
    查看最新的文档。

    谢谢,这就澄清了情况。