You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by po...@apache.org on 2023/10/17 11:11:39 UTC
[airflow] branch move-early-constrints-generation-to-separate-steps updated (2a638d2092 -> 60063e5b67)
This is an automated email from the ASF dual-hosted git repository.
potiuk pushed a change to branch move-early-constrints-generation-to-separate-steps
in repository https://gitbox.apache.org/repos/asf/airflow.git
discard 2a638d2092 Move constraints generation to separate job in CI workflow
add 9b06798a28 Use requires_access to check read permission on dag instead of checking it explicitly (#34940)
add 6bb6ae8f9f `PostgresOperator` should not overwrite `SQLExecuteQueryOperator.template_fields` (#34969)
add ad15af5cab Update documentation to enable test connection (#34905)
add b1196460db Add `check_interval` and `max_attempts` as parameter of `DynamoDBToS3Operator` (#34972)
add b392f66c42 Set `EcsRunTaskOperator` default waiter duration to 70 days (#34928)
add 4a37777567 Glue `DataBrew` operator (#34807)
add 85fd0e1102 Optimise and migrate to SA2-compatible syntax for TaskReschedule (#33720)
new 60063e5b67 Move constraints generation to separate job in CI workflow
This update added new revisions after undoing existing revisions.
That is to say, some revisions that were in the old version of the
branch are not in the new version. This situation occurs
when a user --force pushes a change and generates a repository
containing something like this:
* -- * -- B -- O -- O -- O (2a638d2092)
\
N -- N -- N refs/heads/move-early-constrints-generation-to-separate-steps (60063e5b67)
You should already have received notification emails for all of the O
revisions, and so the following emails describe only the N revisions
from the common base, B.
Any revisions marked "omit" are not gone; other references still
refer to them. Any revisions marked "discard" are gone forever.
The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
Summary of changes:
.../endpoints/dag_warning_endpoint.py | 10 +-
airflow/api_connexion/openapi/v1.yaml | 9 +
airflow/models/taskinstance.py | 10 +-
airflow/models/taskreschedule.py | 54 +++++-
.../providers/amazon/aws/hooks/glue_databrew.py | 68 +++++++
airflow/providers/amazon/aws/operators/ecs.py | 4 +-
.../amazon/aws/operators/glue_databrew.py | 110 +++++++++++
.../amazon/aws/transfers/dynamodb_to_s3.py | 14 +-
.../providers/amazon/aws/triggers/glue_databrew.py | 59 ++++++
.../waiters/{stepfunctions.json => databrew.json} | 26 +--
airflow/providers/amazon/provider.yaml | 15 ++
airflow/providers/postgres/operators/postgres.py | 6 +-
airflow/sensors/base.py | 16 +-
airflow/ti_deps/deps/ready_to_reschedule.py | 11 +-
airflow/www/static/js/types/api-generated.ts | 18 ++
.../operators/glue.rst | 1 +
.../operators/glue_databrew.rst | 53 ++++++
docs/apache-airflow/howto/connection.rst | 20 +-
.../integration-logos/aws/AWS-Glue-DataBrew_64.png | Bin 0 -> 14575 bytes
tests/models/test_taskinstance.py | 35 ++--
.../amazon/aws/hooks/test_glue_databrew.py | 24 +--
tests/providers/amazon/aws/operators/test_ecs.py | 2 +-
.../amazon/aws/operators/test_glue_databrew.py | 58 ++++++
.../amazon/aws/triggers/test_glue_databrew.py} | 36 ++--
.../amazon/aws/waiters/test_glue_databrew.py | 68 +++++++
.../providers/postgres/operators/test_postgres.py | 16 ++
tests/sensors/test_base.py | 32 ++--
.../providers/amazon/aws/example_dynamodb_to_s3.py | 2 +
.../aws/example_glue_databrew.py} | 39 ++--
tests/ti_deps/deps/test_ready_to_reschedule_dep.py | 208 ++++++++++-----------
30 files changed, 801 insertions(+), 223 deletions(-)
create mode 100644 airflow/providers/amazon/aws/hooks/glue_databrew.py
create mode 100644 airflow/providers/amazon/aws/operators/glue_databrew.py
create mode 100644 airflow/providers/amazon/aws/triggers/glue_databrew.py
copy airflow/providers/amazon/aws/waiters/{stepfunctions.json => databrew.json} (52%)
create mode 100644 docs/apache-airflow-providers-amazon/operators/glue_databrew.rst
create mode 100644 docs/integration-logos/aws/AWS-Glue-DataBrew_64.png
copy airflow/operators/smooth.py => tests/providers/amazon/aws/hooks/test_glue_databrew.py (61%)
create mode 100644 tests/providers/amazon/aws/operators/test_glue_databrew.py
copy tests/{ti_deps/deps/test_task_not_running_dep.py => providers/amazon/aws/triggers/test_glue_databrew.py} (54%)
create mode 100644 tests/providers/amazon/aws/waiters/test_glue_databrew.py
copy tests/system/providers/{alibaba/example_adb_spark_sql.py => amazon/aws/example_glue_databrew.py} (61%)
[airflow] 01/01: Move constraints generation to separate job in CI workflow
Posted by po...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
potiuk pushed a commit to branch move-early-constrints-generation-to-separate-steps
in repository https://gitbox.apache.org/repos/asf/airflow.git
commit 60063e5b67b3c1e4f88b804480ee26676cd3df21
Author: Jarek Potiuk <ja...@potiuk.com>
AuthorDate: Mon Oct 16 16:49:08 2023 +0200
Move constraints generation to separate job in CI workflow
We generate constraints for preview right after images are build, in
order to be able to see the output and to diagnose which dependencies
have been updated later in the process.
So far we were doing it in CI workflow and When constraints generation
failed however (for example because pip backtracking takes a log ot
time), it faied build image workflow and did not allow tests to
complete.
This PR extracts constraint generation to CI separate job which
does not block tests from running in case constraints generation
fails or times out.
It also moves out the steps from the composite action which allows
to better see which step failed and allows to see the constraints
used in each job more easily.
---
.github/actions/build-ci-images/action.yml | 24 --------------
.github/workflows/ci.yml | 51 ++++++++++++++++++++++++++++++
2 files changed, 51 insertions(+), 24 deletions(-)
diff --git a/.github/actions/build-ci-images/action.yml b/.github/actions/build-ci-images/action.yml
index 81825f9a79..e93b2f4e71 100644
--- a/.github/actions/build-ci-images/action.yml
+++ b/.github/actions/build-ci-images/action.yml
@@ -34,30 +34,6 @@ runs:
- name: "Build & Push AMD64 CI images ${{ env.IMAGE_TAG }} ${{ env.PYTHON_VERSIONS }}"
shell: bash
run: breeze ci-image build --push --tag-as-latest --run-in-parallel --upgrade-on-failure
- - name: "Generate source constraints"
- shell: bash
- run: >
- breeze release-management generate-constraints --run-in-parallel
- --airflow-constraints-mode constraints-source-providers
-# - name: "Generate PyPI constraints"
-# shell: bash
-# run: >
-# breeze release-management generate-constraints --run-in-parallel
-# --airflow-constraints-mode constraints
-# if: ${{ inputs.build-provider-packages != 'true' }}
- - name: "Print dependency upgrade summary"
- shell: bash
- run: |
- for PYTHON_VERSION in ${{ env.PYTHON_VERSIONS }}; do
- echo "Summarizing Python $PYTHON_VERSION"
- cat "files/constraints-${PYTHON_VERSION}/*.md" >> $GITHUB_STEP_SUMMARY || true
- done
- - name: "Upload constraint artifacts"
- uses: actions/upload-artifact@v3
- with:
- name: constraints
- path: ./files/constraints-*/constraints-*.txt
- retention-days: 7
- name: "Fix ownership"
shell: bash
run: breeze ci fix-ownership
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index ca44ad3199..e242254e66 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -326,6 +326,57 @@ jobs:
DEBUG_RESOURCES: ${{needs.build-info.outputs.debug-resources}}
BUILD_TIMEOUT_MINUTES: 70
+ preview-constraints:
+ permissions:
+ contents: read
+ timeout-minutes: 20
+ continue-on-error: true
+ name: >
+ Preview constraints
+ ${{needs.build-info.outputs.all-python-versions-list-as-string}}
+ runs-on: "${{needs.build-info.outputs.runs-on}}"
+ needs: [build-info, build-ci-images]
+ if: needs.build-info.outputs.upgrade-to-newer-dependencies != "false"
+ env:
+ RUNS_ON: "${{ needs.build-info.outputs.runs-on }}"
+ PYTHON_VERSIONS: ${{needs.build-info.outputs.all-python-versions-list-as-string}}
+ steps:
+ - name: "Checkout ${{ github.ref }} ( ${{ github.sha }} )"
+ uses: actions/checkout@v3
+ with:
+ persist-credentials: false
+ - name: >
+ Prepare breeze & CI image: ${{needs.build-info.outputs.default-python-version}}:${{env.IMAGE_TAG}}
+ uses: ./.github/actions/prepare_breeze_and_image
+ - name: "Source constraints"
+ shell: bash
+ run: >
+ breeze release-management generate-constraints --run-in-parallel
+ --airflow-constraints-mode constraints-source-providers || true
+ env:
+ DEBUG_RESOURCES: ${{needs.build-info.outputs.debug-resources}}
+ - name: "PyPI constraints"
+ shell: bash
+ timeout-minutes: 10
+ run: >
+ breeze release-management generate-constraints --run-in-parallel
+ --airflow-constraints-mode constraints || true
+ env:
+ DEBUG_RESOURCES: ${{needs.build-info.outputs.debug-resources}}
+ - name: "Dependency upgrade summary"
+ shell: bash
+ run: |
+ for PYTHON_VERSION in ${{ env.PYTHON_VERSIONS }}; do
+ echo "Summarizing Python $PYTHON_VERSION"
+ cat "files/constraints-${PYTHON_VERSION}/*.md" >> $GITHUB_STEP_SUMMARY || true
+ done
+ - name: "Upload constraint artifacts"
+ uses: actions/upload-artifact@v3
+ with:
+ name: constraints
+ path: ./files/constraints-*/constraints-*.txt
+ retention-days: 7
+
build-prod-images:
timeout-minutes: 80
name: >