diff --git a/.evergreen/config/generated/build/build-php-7.4.yml b/.evergreen/config/generated/build/build-php-7.4.yml index c536ec27b..713be9d40 100644 --- a/.evergreen/config/generated/build/build-php-7.4.yml +++ b/.evergreen/config/generated/build/build-php-7.4.yml @@ -7,38 +7,34 @@ tasks: vars: PHP_VERSION: "7.4" - func: "compile extension" - # TODO: Remove this variable once PHPC 1.17.0 is released + - func: "upload extension" + - name: "build-php-7.4-lowest" + tags: ["build", "php7.4", "lowest"] + commands: + - func: "locate PHP binaries" + vars: + PHP_VERSION: "7.4" + - func: "compile extension" + vars: + EXTENSION_VERSION: "1.17.0" + - func: "upload extension" + - name: "build-php-7.4-next-stable" + tags: ["build", "php7.4", "next-stable"] + commands: + - func: "locate PHP binaries" + vars: + PHP_VERSION: "7.4" + - func: "compile extension" + vars: + EXTENSION_BRANCH: "v1.17" + - func: "upload extension" + - name: "build-php-7.4-next-minor" + tags: ["build", "php7.4", "next-minor"] + commands: + - func: "locate PHP binaries" + vars: + PHP_VERSION: "7.4" + - func: "compile extension" vars: EXTENSION_BRANCH: "master" - func: "upload extension" -# TODO: Re-enable these tasks once PHPC 1.17.0 is released -# - name: "build-php-7.4-lowest" -# tags: ["build", "php7.4", "lowest"] -# commands: -# - func: "locate PHP binaries" -# vars: -# PHP_VERSION: "7.4" -# - func: "compile extension" -# vars: -# EXTENSION_VERSION: "1.17.0" -# - func: "upload extension" -# - name: "build-php-7.4-next-stable" -# tags: ["build", "php7.4", "next-stable"] -# commands: -# - func: "locate PHP binaries" -# vars: -# PHP_VERSION: "7.4" -# - func: "compile extension" -# vars: -# EXTENSION_BRANCH: "v1.17" -# - func: "upload extension" -# - name: "build-php-7.4-next-minor" -# tags: ["build", "php7.4", "next-minor"] -# commands: -# - func: "locate PHP binaries" -# vars: -# PHP_VERSION: "7.4" -# - func: "compile extension" -# vars: -# EXTENSION_BRANCH: "master" -# - func: "upload extension" diff --git a/.evergreen/config/generated/build/build-php-8.0.yml b/.evergreen/config/generated/build/build-php-8.0.yml index c34b722ec..c69691a59 100644 --- a/.evergreen/config/generated/build/build-php-8.0.yml +++ b/.evergreen/config/generated/build/build-php-8.0.yml @@ -7,38 +7,34 @@ tasks: vars: PHP_VERSION: "8.0" - func: "compile extension" - # TODO: Remove this variable once PHPC 1.17.0 is released + - func: "upload extension" + - name: "build-php-8.0-lowest" + tags: ["build", "php8.0", "lowest"] + commands: + - func: "locate PHP binaries" + vars: + PHP_VERSION: "8.0" + - func: "compile extension" + vars: + EXTENSION_VERSION: "1.17.0" + - func: "upload extension" + - name: "build-php-8.0-next-stable" + tags: ["build", "php8.0", "next-stable"] + commands: + - func: "locate PHP binaries" + vars: + PHP_VERSION: "8.0" + - func: "compile extension" + vars: + EXTENSION_BRANCH: "v1.17" + - func: "upload extension" + - name: "build-php-8.0-next-minor" + tags: ["build", "php8.0", "next-minor"] + commands: + - func: "locate PHP binaries" + vars: + PHP_VERSION: "8.0" + - func: "compile extension" vars: EXTENSION_BRANCH: "master" - func: "upload extension" -# TODO: Re-enable these tasks once PHPC 1.17.0 is released -# - name: "build-php-8.0-lowest" -# tags: ["build", "php8.0", "lowest"] -# commands: -# - func: "locate PHP binaries" -# vars: -# PHP_VERSION: "8.0" -# - func: "compile extension" -# vars: -# EXTENSION_VERSION: "1.17.0" -# - func: "upload extension" -# - name: "build-php-8.0-next-stable" -# tags: ["build", "php8.0", "next-stable"] -# commands: -# - func: "locate PHP binaries" -# vars: -# PHP_VERSION: "8.0" -# - func: "compile extension" -# vars: -# EXTENSION_BRANCH: "v1.17" -# - func: "upload extension" -# - name: "build-php-8.0-next-minor" -# tags: ["build", "php8.0", "next-minor"] -# commands: -# - func: "locate PHP binaries" -# vars: -# PHP_VERSION: "8.0" -# - func: "compile extension" -# vars: -# EXTENSION_BRANCH: "master" -# - func: "upload extension" diff --git a/.evergreen/config/generated/build/build-php-8.1.yml b/.evergreen/config/generated/build/build-php-8.1.yml index 912f0b5c1..42e2bdbcc 100644 --- a/.evergreen/config/generated/build/build-php-8.1.yml +++ b/.evergreen/config/generated/build/build-php-8.1.yml @@ -7,38 +7,34 @@ tasks: vars: PHP_VERSION: "8.1" - func: "compile extension" - # TODO: Remove this variable once PHPC 1.17.0 is released + - func: "upload extension" + - name: "build-php-8.1-lowest" + tags: ["build", "php8.1", "lowest"] + commands: + - func: "locate PHP binaries" + vars: + PHP_VERSION: "8.1" + - func: "compile extension" + vars: + EXTENSION_VERSION: "1.17.0" + - func: "upload extension" + - name: "build-php-8.1-next-stable" + tags: ["build", "php8.1", "next-stable"] + commands: + - func: "locate PHP binaries" + vars: + PHP_VERSION: "8.1" + - func: "compile extension" + vars: + EXTENSION_BRANCH: "v1.17" + - func: "upload extension" + - name: "build-php-8.1-next-minor" + tags: ["build", "php8.1", "next-minor"] + commands: + - func: "locate PHP binaries" + vars: + PHP_VERSION: "8.1" + - func: "compile extension" vars: EXTENSION_BRANCH: "master" - func: "upload extension" -# TODO: Re-enable these tasks once PHPC 1.17.0 is released -# - name: "build-php-8.1-lowest" -# tags: ["build", "php8.1", "lowest"] -# commands: -# - func: "locate PHP binaries" -# vars: -# PHP_VERSION: "8.1" -# - func: "compile extension" -# vars: -# EXTENSION_VERSION: "1.17.0" -# - func: "upload extension" -# - name: "build-php-8.1-next-stable" -# tags: ["build", "php8.1", "next-stable"] -# commands: -# - func: "locate PHP binaries" -# vars: -# PHP_VERSION: "8.1" -# - func: "compile extension" -# vars: -# EXTENSION_BRANCH: "v1.17" -# - func: "upload extension" -# - name: "build-php-8.1-next-minor" -# tags: ["build", "php8.1", "next-minor"] -# commands: -# - func: "locate PHP binaries" -# vars: -# PHP_VERSION: "8.1" -# - func: "compile extension" -# vars: -# EXTENSION_BRANCH: "master" -# - func: "upload extension" diff --git a/.evergreen/config/generated/build/build-php-8.2.yml b/.evergreen/config/generated/build/build-php-8.2.yml index af7223515..756245940 100644 --- a/.evergreen/config/generated/build/build-php-8.2.yml +++ b/.evergreen/config/generated/build/build-php-8.2.yml @@ -7,38 +7,34 @@ tasks: vars: PHP_VERSION: "8.2" - func: "compile extension" - # TODO: Remove this variable once PHPC 1.17.0 is released + - func: "upload extension" + - name: "build-php-8.2-lowest" + tags: ["build", "php8.2", "lowest"] + commands: + - func: "locate PHP binaries" + vars: + PHP_VERSION: "8.2" + - func: "compile extension" + vars: + EXTENSION_VERSION: "1.17.0" + - func: "upload extension" + - name: "build-php-8.2-next-stable" + tags: ["build", "php8.2", "next-stable"] + commands: + - func: "locate PHP binaries" + vars: + PHP_VERSION: "8.2" + - func: "compile extension" + vars: + EXTENSION_BRANCH: "v1.17" + - func: "upload extension" + - name: "build-php-8.2-next-minor" + tags: ["build", "php8.2", "next-minor"] + commands: + - func: "locate PHP binaries" + vars: + PHP_VERSION: "8.2" + - func: "compile extension" vars: EXTENSION_BRANCH: "master" - func: "upload extension" -# TODO: Re-enable these tasks once PHPC 1.17.0 is released -# - name: "build-php-8.2-lowest" -# tags: ["build", "php8.2", "lowest"] -# commands: -# - func: "locate PHP binaries" -# vars: -# PHP_VERSION: "8.2" -# - func: "compile extension" -# vars: -# EXTENSION_VERSION: "1.17.0" -# - func: "upload extension" -# - name: "build-php-8.2-next-stable" -# tags: ["build", "php8.2", "next-stable"] -# commands: -# - func: "locate PHP binaries" -# vars: -# PHP_VERSION: "8.2" -# - func: "compile extension" -# vars: -# EXTENSION_BRANCH: "v1.17" -# - func: "upload extension" -# - name: "build-php-8.2-next-minor" -# tags: ["build", "php8.2", "next-minor"] -# commands: -# - func: "locate PHP binaries" -# vars: -# PHP_VERSION: "8.2" -# - func: "compile extension" -# vars: -# EXTENSION_BRANCH: "master" -# - func: "upload extension" diff --git a/.evergreen/config/templates/build/build-extension.yml b/.evergreen/config/templates/build/build-extension.yml index 9785cfa57..04946be87 100644 --- a/.evergreen/config/templates/build/build-extension.yml +++ b/.evergreen/config/templates/build/build-extension.yml @@ -6,38 +6,34 @@ tasks: vars: PHP_VERSION: "%phpVersion%" - func: "compile extension" - # TODO: Remove this variable once PHPC 1.17.0 is released + - func: "upload extension" + - name: "build-php-%phpVersion%-lowest" + tags: ["build", "php%phpVersion%", "lowest"] + commands: + - func: "locate PHP binaries" + vars: + PHP_VERSION: "%phpVersion%" + - func: "compile extension" + vars: + EXTENSION_VERSION: "1.17.0" + - func: "upload extension" + - name: "build-php-%phpVersion%-next-stable" + tags: ["build", "php%phpVersion%", "next-stable"] + commands: + - func: "locate PHP binaries" + vars: + PHP_VERSION: "%phpVersion%" + - func: "compile extension" + vars: + EXTENSION_BRANCH: "v1.17" + - func: "upload extension" + - name: "build-php-%phpVersion%-next-minor" + tags: ["build", "php%phpVersion%", "next-minor"] + commands: + - func: "locate PHP binaries" + vars: + PHP_VERSION: "%phpVersion%" + - func: "compile extension" vars: EXTENSION_BRANCH: "master" - func: "upload extension" -# TODO: Re-enable these tasks once PHPC 1.17.0 is released -# - name: "build-php-%phpVersion%-lowest" -# tags: ["build", "php%phpVersion%", "lowest"] -# commands: -# - func: "locate PHP binaries" -# vars: -# PHP_VERSION: "%phpVersion%" -# - func: "compile extension" -# vars: -# EXTENSION_VERSION: "1.17.0" -# - func: "upload extension" -# - name: "build-php-%phpVersion%-next-stable" -# tags: ["build", "php%phpVersion%", "next-stable"] -# commands: -# - func: "locate PHP binaries" -# vars: -# PHP_VERSION: "%phpVersion%" -# - func: "compile extension" -# vars: -# EXTENSION_BRANCH: "v1.17" -# - func: "upload extension" -# - name: "build-php-%phpVersion%-next-minor" -# tags: ["build", "php%phpVersion%", "next-minor"] -# commands: -# - func: "locate PHP binaries" -# vars: -# PHP_VERSION: "%phpVersion%" -# - func: "compile extension" -# vars: -# EXTENSION_BRANCH: "master" -# - func: "upload extension" diff --git a/.evergreen/config/test-variants.yml b/.evergreen/config/test-variants.yml index 34875e83f..00e13fa9b 100644 --- a/.evergreen/config/test-variants.yml +++ b/.evergreen/config/test-variants.yml @@ -88,17 +88,44 @@ buildvariants: run_on: debian92-small expansions: FETCH_BUILD_VARIANT: "build-debian92" - # TODO: Change to build-php-7.4-lowest once PHPC 1.17.0 is released - FETCH_BUILD_TASK: "build-php-7.4" + FETCH_BUILD_TASK: "build-php-7.4-lowest" PHP_VERSION: "7.4" DEPENDENCIES: "lowest" depends_on: - variant: "build-debian92" - # TODO: Change to build-php-7.4-lowest once PHPC 1.17.0 is released - name: "build-php-7.4" + name: "build-php-7.4-lowest" tasks: - ".replicaset .local .3.6 !.csfle" + # Test with upcoming PHPC versions + - name: test-debian11-php82-phpc-next-stable + tags: ["test", "debian", "x64"] + display_name: "Test: Debian 11, PHP 8.2, PHPC next-stable" + run_on: debian11-small + expansions: + FETCH_BUILD_VARIANT: "build-debian11" + FETCH_BUILD_TASK: "build-php-8.2-next-stable" + PHP_VERSION: "8.2" + depends_on: + - variant: "build-debian11" + name: "build-php-8.2-next-stable" + tasks: + - ".replicaset .local .7.0 !.csfle" + + - name: test-debian11-php82-phpc-next-minor + tags: ["test", "debian", "x64"] + display_name: "Test: Debian 11, PHP 8.2, PHPC next-minor" + run_on: debian11-small + expansions: + FETCH_BUILD_VARIANT: "build-debian11" + FETCH_BUILD_TASK: "build-php-8.2-next-minor" + PHP_VERSION: "8.2" + depends_on: + - variant: "build-debian11" + name: "build-php-8.2-next-minor" + tasks: + - ".replicaset .local .7.0 !.csfle" + # Test Atlas and CSFLE on RHEL 8 - name: test-rhel80-php82-atlas tags: ["test", "debian", "x64"] diff --git a/.github/workflows/benchmark.yml b/.github/workflows/benchmark.yml deleted file mode 100644 index 053d5776f..000000000 --- a/.github/workflows/benchmark.yml +++ /dev/null @@ -1,78 +0,0 @@ -name: "Performance Benchmark" - -on: - pull_request: - branches: - - "v*.*" - - "master" - - "feature/*" - paths-ignore: - - "docs/**" - push: - branches: - - "v*.*" - - "master" - - "feature/*" - paths-ignore: - - "docs/**" - -env: - PHP_VERSION: "8.2" - DRIVER_VERSION: "mongodb/mongo-php-driver@master" - -jobs: - psalm: - name: "phpbench" - runs-on: "ubuntu-22.04" - - steps: - - name: "Checkout" - uses: "actions/checkout@v4" - - - id: setup-mongodb - uses: mongodb-labs/drivers-evergreen-tools@master - with: - version: "6.0" - topology: "server" - skip-legacy-shell: true - - - name: Setup cache environment - id: extcache - uses: shivammathur/cache-extensions@v1 - with: - php-version: ${{ env.PHP_VERSION }} - extensions: "mongodb-${{ ENV.DRIVER_VERSION }}" - key: "extcache-v1" - - - name: Cache extensions - uses: actions/cache@v3 - with: - path: ${{ steps.extcache.outputs.dir }} - key: ${{ steps.extcache.outputs.key }} - restore-keys: ${{ steps.extcache.outputs.key }} - - - name: "Install PHP" - uses: "shivammathur/setup-php@v2" - with: - coverage: "none" - extensions: "mongodb-${{ ENV.DRIVER_VERSION }}" - php-version: "${{ env.PHP_VERSION }}" - - - name: "Show driver information" - run: "php --ri mongodb" - - - name: "Install dependencies with Composer" - uses: "ramsey/composer-install@2.2.0" - with: - composer-options: "--no-suggest --working-dir=./benchmark" - - - name: "Run phpbench" - working-directory: "./benchmark" - run: "vendor/bin/phpbench run --report=aggregate --report=bar_chart_time --report=env --output html" - - - name: Upload HTML report - uses: actions/upload-artifact@v3 - with: - name: phpbench-${{ github.sha }}.html - path: ./benchmark/.phpbench/html/index.html - retention-days: 3 diff --git a/.github/workflows/coding-standards.yml b/.github/workflows/coding-standards.yml index 76df7a698..d39183073 100644 --- a/.github/workflows/coding-standards.yml +++ b/.github/workflows/coding-standards.yml @@ -18,7 +18,7 @@ on: env: PHP_VERSION: "8.2" - DRIVER_VERSION: "mongodb/mongo-php-driver@master" + DRIVER_VERSION: "stable" jobs: phpcs: diff --git a/.github/workflows/static-analysis.yml b/.github/workflows/static-analysis.yml index 41e6fbb09..bb216b712 100644 --- a/.github/workflows/static-analysis.yml +++ b/.github/workflows/static-analysis.yml @@ -18,7 +18,7 @@ on: env: PHP_VERSION: "8.2" - DRIVER_VERSION: "mongodb/mongo-php-driver@master" + DRIVER_VERSION: "stable" jobs: psalm: diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 48400e7cc..ce0816ee1 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -35,34 +35,34 @@ jobs: mongodb-version: - "4.4" driver-version: - - "mongodb/mongo-php-driver@master" + - "stable" topology: - "server" include: - os: "ubuntu-20.04" php-version: "8.0" mongodb-version: "6.0" - driver-version: "mongodb/mongo-php-driver@master" + driver-version: "stable" topology: "replica_set" - os: "ubuntu-20.04" php-version: "8.0" mongodb-version: "6.0" - driver-version: "mongodb/mongo-php-driver@master" + driver-version: "stable" topology: "sharded_cluster" - os: "ubuntu-20.04" php-version: "8.0" mongodb-version: "5.0" - driver-version: "mongodb/mongo-php-driver@master" + driver-version: "stable" topology: "server" - os: "ubuntu-20.04" php-version: "8.0" mongodb-version: "4.4" - driver-version: "mongodb/mongo-php-driver@master" + driver-version: "stable" topology: "replica_set" - os: "ubuntu-20.04" php-version: "8.0" mongodb-version: "4.4" - driver-version: "mongodb/mongo-php-driver@master" + driver-version: "stable" topology: "sharded_cluster" steps: