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

Remove entry and allocated memory for empty buffers. #31194

Merged
merged 6 commits into from
Oct 11, 2023

Conversation

tryangul
Copy link
Contributor

@tryangul tryangul commented Oct 9, 2023

What

Fixes memory leak due to empty buffers holding onto allocated memory. Fix for this issue.

How

If a buffer for a stream descriptor ever empties, we shrink the queue and release any lingering memory not covered by the pending batch release.

Notes

We are shrinking the queue and not removing it because 1) enough code assumed the queue was always present that it presented a bigger change. 2) if there is some race on the map (there shouldn't be) removing the entry could lead to dropped data.

🚨 User Impact 🚨

This fixes an ongoing issue. If users use an async connector on tables with lots of streams, they will want to upgrade.

@vercel
Copy link

vercel bot commented Oct 9, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

1 Ignored Deployment
Name Status Preview Comments Updated (UTC)
airbyte-docs ⬜️ Ignored (Inspect) Visit Preview Oct 11, 2023 4:51pm

@octavia-squidington-iii octavia-squidington-iii added the CDK Connector Development Kit label Oct 9, 2023
@tryangul tryangul force-pushed the rbroughan/clean-up-empty-buffer-memory branch 12 times, most recently from e21617f to d78caf0 Compare October 11, 2023 01:03
@tryangul tryangul requested a review from a team as a code owner October 11, 2023 01:03
@tryangul
Copy link
Contributor Author

@benmoriceau should be ready for re-review

@airbyte-oss-build-runner
Copy link
Collaborator

destination-redshift test report (commit 480a1a91eb) - ❌

⏲️ Total pipeline duration: 19mn51s

Step Result
Build connector tar
Build destination-redshift docker image for platform(s) linux/x86_64
Java Connector Unit Tests
Build airbyte/normalization-redshift:dev
Java Connector Integration Tests
Validate metadata for destination-redshift
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=destination-redshift test

@tryangul tryangul force-pushed the rbroughan/clean-up-empty-buffer-memory branch from 480a1a9 to deca106 Compare October 11, 2023 02:32
@airbyte-oss-build-runner
Copy link
Collaborator

destination-snowflake test report (commit deca106787) - ❌

⏲️ Total pipeline duration: 01mn09s

Step Result
Build connector tar
Validate metadata for destination-snowflake
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=destination-snowflake test

@airbyte-oss-build-runner
Copy link
Collaborator

destination-redshift test report (commit deca106787) - ❌

⏲️ Total pipeline duration: 01mn14s

Step Result
Build connector tar
Validate metadata for destination-redshift
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=destination-redshift test

@airbyte-oss-build-runner
Copy link
Collaborator

destination-bigquery test report (commit 164a81877b) - ❌

⏲️ Total pipeline duration: 01mn41s

Step Result
Build connector tar
Validate metadata for destination-bigquery
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=destination-bigquery test

@airbyte-oss-build-runner
Copy link
Collaborator

destination-redshift test report (commit 164a81877b) - ❌

⏲️ Total pipeline duration: 01mn14s

Step Result
Build connector tar
Validate metadata for destination-redshift
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=destination-redshift test

@airbyte-oss-build-runner
Copy link
Collaborator

destination-snowflake test report (commit 164a81877b) - ❌

⏲️ Total pipeline duration: 01mn09s

Step Result
Build connector tar
Validate metadata for destination-snowflake
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=destination-snowflake test

@airbyte-oss-build-runner
Copy link
Collaborator

destination-snowflake test report (commit 1a7fad8213) - ❌

⏲️ Total pipeline duration: 54.47s

Step Result
Build connector tar
Validate metadata for destination-snowflake
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=destination-snowflake test

@airbyte-oss-build-runner
Copy link
Collaborator

destination-bigquery test report (commit 1a7fad8213) - ❌

⏲️ Total pipeline duration: 01mn20s

Step Result
Build connector tar
Validate metadata for destination-bigquery
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=destination-bigquery test

@airbyte-oss-build-runner
Copy link
Collaborator

destination-redshift test report (commit 1a7fad8213) - ❌

⏲️ Total pipeline duration: 22.00s

Step Result
Build connector tar
Validate metadata for destination-redshift
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=destination-redshift test

@airbyte-oss-build-runner
Copy link
Collaborator

destination-snowflake test report (commit 7566b0f122) - ❌

⏲️ Total pipeline duration: 46.60s

Step Result
Build connector tar
Validate metadata for destination-snowflake
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=destination-snowflake test

@airbyte-oss-build-runner
Copy link
Collaborator

destination-bigquery test report (commit 7566b0f122) - ❌

⏲️ Total pipeline duration: 01mn21s

Step Result
Build connector tar
Validate metadata for destination-bigquery
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=destination-bigquery test

@airbyte-oss-build-runner
Copy link
Collaborator

destination-redshift test report (commit 7566b0f122) - ❌

⏲️ Total pipeline duration: 21.86s

Step Result
Build connector tar
Validate metadata for destination-redshift
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=destination-redshift test

@tryangul
Copy link
Contributor Author

tryangul commented Oct 11, 2023

/publish-java-cdk

🕑 https://github.com/airbytehq/airbyte/actions/runs/6485122944
✅ Successfully published Java CDK version=0.1.7!

@airbyte-oss-build-runner
Copy link
Collaborator

destination-bigquery test report (commit f52bb50d84) - ✅

⏲️ Total pipeline duration: 08mn38s

Step Result
Build connector tar
Build destination-bigquery docker image for platform(s) linux/x86_64
Java Connector Unit Tests
Java Connector Integration Tests
Validate metadata for destination-bigquery
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=destination-bigquery test

@airbyte-oss-build-runner
Copy link
Collaborator

destination-snowflake test report (commit f52bb50d84) - ✅

⏲️ Total pipeline duration: 10mn13s

Step Result
Build connector tar
Build destination-snowflake docker image for platform(s) linux/x86_64
Java Connector Unit Tests
Java Connector Integration Tests
Validate metadata for destination-snowflake
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=destination-snowflake test

@airbyte-oss-build-runner
Copy link
Collaborator

destination-redshift test report (commit dc98428471) - ✅

⏲️ Total pipeline duration: 20mn38s

Step Result
Build connector tar
Build destination-redshift docker image for platform(s) linux/x86_64
Java Connector Unit Tests
Build airbyte/normalization-redshift:dev
Java Connector Integration Tests
Validate metadata for destination-redshift
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=destination-redshift test

@airbyte-oss-build-runner
Copy link
Collaborator

destination-bigquery test report (commit dc98428471) - ✅

⏲️ Total pipeline duration: 08mn00s

Step Result
Build connector tar
Build destination-bigquery docker image for platform(s) linux/x86_64
Java Connector Unit Tests
Java Connector Integration Tests
Validate metadata for destination-bigquery
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=destination-bigquery test

@airbyte-oss-build-runner
Copy link
Collaborator

destination-snowflake test report (commit dc98428471) - ✅

⏲️ Total pipeline duration: 10mn21s

Step Result
Build connector tar
Build destination-snowflake docker image for platform(s) linux/x86_64
Java Connector Unit Tests
Java Connector Integration Tests
Validate metadata for destination-snowflake
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=destination-snowflake test

@tryangul tryangul merged commit 5f9bec0 into master Oct 11, 2023
25 checks passed
@tryangul tryangul deleted the rbroughan/clean-up-empty-buffer-memory branch October 11, 2023 18:22
ariesgun pushed a commit to ariesgun/airbyte that referenced this pull request Oct 23, 2023
Co-authored-by: tryangul <tryangul@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants