Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

✨ source-stripe: Use concurrent cdk #31327

Merged
merged 146 commits into from
Oct 26, 2023
Merged

✨ source-stripe: Use concurrent cdk #31327

merged 146 commits into from
Oct 26, 2023

Conversation

girarda
Copy link
Contributor

@girarda girarda commented Oct 11, 2023

What

  • Use the concurrent cdk with a configurable concurrency level when running in full refresh
  • The concurrency level is capped to 3 workers to avoid hitting the rate limit even in test mode

How

  • Add num_workers field to the spec
  • Create concurrent streams using StreamFacade.create_from_stream if the read process has no input state
  • Concurrency level is set to 2 workers by default

Recommended reading order

  1. airbyte-integrations/connectors/source-stripe/source_stripe/spec.yaml
  2. airbyte-integrations/connectors/source-stripe/main.py
  3. airbyte-integrations/connectors/source-stripe/source_stripe/source.py

🚨 User Impact 🚨

  • Full refresh syncs will use the concurrent CDK

Pre-merge Actions

Expand the relevant checklist and delete the others.

New Connector

Community member or Airbyter

  • Community member? Grant edit access to maintainers (instructions)
  • Unit & integration tests added and passing. Community members, please provide proof of success locally e.g: screenshot or copy-paste unit, integration, and acceptance test output. To run acceptance tests for a Python connector, follow instructions in the README. For java connectors run ./gradlew :airbyte-integrations:connectors:<name>:integrationTest.
  • Connector version is set to 0.0.1
    • Dockerfile has version 0.0.1
  • Documentation updated
    • Connector's README.md
    • Connector's bootstrap.md. See description and examples
    • docs/integrations/<source or destination>/<name>.md including changelog with an entry for the initial version. See changelog example
    • docs/integrations/README.md

Airbyter

If this is a community PR, the Airbyte engineer reviewing this PR is responsible for the below items.

  • Create a non-forked branch based on this PR and test the below items on it
  • Build is successful
  • If new credentials are required for use in CI, add them to GSM. Instructions.
Updating a connector

Community member or Airbyter

  • Grant edit access to maintainers (instructions)
  • Unit & integration tests added

Airbyter

If this is a community PR, the Airbyte engineer reviewing this PR is responsible for the below items.

  • Create a non-forked branch based on this PR and test the below items on it
  • Build is successful
  • If new credentials are required for use in CI, add them to GSM. Instructions.
Connector Generator
  • Issue acceptance criteria met
  • PR name follows PR naming conventions
  • If adding a new generator, add it to the list of scaffold modules being tested
  • The generator test modules (all connectors with -scaffold in their name) have been updated with the latest scaffold by running ./gradlew :airbyte-integrations:connector-templates:generator:generateScaffolds then checking in your changes
  • Documentation which references the generator is updated as needed
Updating the Python CDK

Airbyter

Before merging:

  • Pull Request description explains what problem it is solving
  • Code change is unit tested
  • Build and my-py check pass
  • Smoke test the change on at least one affected connector
    • On Github: Run this workflow, passing --use-local-cdk --name=source-<connector> as options
    • Locally: airbyte-ci connectors --use-local-cdk --name=source-<connector> test
  • PR is reviewed and approved

After merging:

  • Publish the CDK
    • The CDK does not follow proper semantic versioning. Choose minor if this the change has significant user impact or is a breaking change. Choose patch otherwise.
    • Write a thoughtful changelog message so we know what was updated.
  • Merge the platform PR that was auto-created for updating the Connector Builder's CDK version
    • This step is optional if the change does not affect the connector builder or declarative connectors.

@airbyte-oss-build-runner
Copy link
Collaborator

source-stripe test report (commit 938c271ba7) - ✅

⏲️ Total pipeline duration: 08mn58s

Step Result
Build source-stripe docker image for platform(s) linux/amd64
Unit tests
Acceptance tests
Check our base image is used
Code format checks
Validate metadata for source-stripe
Connector version semver check
Connector version increment check
QA checks

🔗 View the logs here

☁️ View runs for commit in Dagger Cloud

Please note that tests are only run on PR ready for review. Please set your PR to draft mode to not flood the CI engine and upstream service on following commits.
You can run the same pipeline locally on this branch with the airbyte-ci tool with the following command

airbyte-ci connectors --name=source-stripe test

@airbyte-oss-build-runner
Copy link
Collaborator

source-stripe test report (commit 4d4ec83279) - ✅

⏲️ Total pipeline duration: 08mn40s

Step Result
Build source-stripe docker image for platform(s) linux/amd64
Unit tests
Acceptance tests
Check our base image is used
Code format checks
Validate metadata for source-stripe
Connector version semver check
Connector version increment check
QA checks

🔗 View the logs here

☁️ View runs for commit in Dagger Cloud

Please note that tests are only run on PR ready for review. Please set your PR to draft mode to not flood the CI engine and upstream service on following commits.
You can run the same pipeline locally on this branch with the airbyte-ci tool with the following command

airbyte-ci connectors --name=source-stripe test

@girarda
Copy link
Contributor Author

girarda commented Oct 26, 2023

good question @maxi297 I'll set a recurring reminder to search in the GCP log

@airbyte-oss-build-runner
Copy link
Collaborator

source-stripe test report (commit f317ee3167) - ❌

⏲️ Total pipeline duration: 04mn07s

Step Result
Build source-stripe docker image for platform(s) linux/amd64
Unit tests
Acceptance tests
Check our base image is used
Code format checks
Validate metadata for source-stripe
Connector version semver check
Connector version increment check
QA checks

🔗 View the logs here

☁️ View runs for commit in Dagger Cloud

Please note that tests are only run on PR ready for review. Please set your PR to draft mode to not flood the CI engine and upstream service on following commits.
You can run the same pipeline locally on this branch with the airbyte-ci tool with the following command

airbyte-ci connectors --name=source-stripe test

@airbyte-oss-build-runner
Copy link
Collaborator

source-stripe test report (commit afbf79a17c) - ✅

⏲️ Total pipeline duration: 05mn48s

Step Result
Build source-stripe docker image for platform(s) linux/amd64
Unit tests
Acceptance tests
Check our base image is used
Code format checks
Validate metadata for source-stripe
Connector version semver check
Connector version increment check
QA checks

🔗 View the logs here

☁️ View runs for commit in Dagger Cloud

Please note that tests are only run on PR ready for review. Please set your PR to draft mode to not flood the CI engine and upstream service on following commits.
You can run the same pipeline locally on this branch with the airbyte-ci tool with the following command

airbyte-ci connectors --name=source-stripe test

@girarda girarda enabled auto-merge (squash) October 26, 2023 04:37
@airbyte-oss-build-runner
Copy link
Collaborator

source-qualaroo test report (commit c85e5738cf) - ✅

⏲️ Total pipeline duration: 33.44s

Step Result
Build source-qualaroo docker image for platform(s) linux/amd64
Unit tests
Acceptance tests
Code format checks
Validate metadata for source-qualaroo
Connector version semver check
QA checks

🔗 View the logs here

☁️ View runs for commit in Dagger Cloud

Please note that tests are only run on PR ready for review. Please set your PR to draft mode to not flood the CI engine and upstream service on following commits.
You can run the same pipeline locally on this branch with the airbyte-ci tool with the following command

airbyte-ci connectors --name=source-qualaroo test

@airbyte-oss-build-runner
Copy link
Collaborator

source-stripe test report (commit c85e5738cf) - ✅

⏲️ Total pipeline duration: 03mn21s

Step Result
Build source-stripe docker image for platform(s) linux/amd64
Unit tests
Acceptance tests
Check our base image is used
Code format checks
Validate metadata for source-stripe
Connector version semver check
Connector version increment check
QA checks

🔗 View the logs here

☁️ View runs for commit in Dagger Cloud

Please note that tests are only run on PR ready for review. Please set your PR to draft mode to not flood the CI engine and upstream service on following commits.
You can run the same pipeline locally on this branch with the airbyte-ci tool with the following command

airbyte-ci connectors --name=source-stripe test

@girarda girarda merged commit f554ebb into master Oct 26, 2023
19 checks passed
@girarda girarda deleted the alex/stripe_concurrent_cdk branch October 26, 2023 05:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/connectors Connector related issues area/documentation Improvements or additions to documentation connectors/source/qualaroo connectors/source/stripe
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants