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

fix: Redis driver throws TypeError under high load #7959

Closed
wants to merge 1 commit into from

Conversation

schneefux
Copy link

Check List

  • Tests has been run in packages where changes made if available
  • Linter has been run for changed code
  • Tests for the changes have been added if not covered yet
  • Docs have been added / updated if required

Issue Reference this PR resolves

N/A

Description of Changes Made (if issue reference is not provided)

Fixes "TypeError: result is not iterable at RedisQueueDriverConnection.retrieveForProcessing". The return value of execAsync is undefined if the redis transaction fails due to out of memory errors, see https://redis.io/docs/interact/transactions/#errors-inside-a-transaction. This is a regression of 101b85f.

Fixes "TypeError: result is not iterable at RedisQueueDriverConnection.retrieveForProcessing".
The return value of `execAsync` is undefined if the redis transaction fails due to out of memory errors, see https://redis.io/docs/interact/transactions/#errors-inside-a-transaction.
This is a regression of 101b85f.
@schneefux schneefux requested a review from a team as a code owner March 18, 2024 07:55
Copy link

vercel bot commented Mar 18, 2024

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

8 Ignored Deployments
Name Status Preview Comments Updated (UTC)
examples-angular-dashboard ⬜️ Ignored (Inspect) Visit Preview Mar 18, 2024 7:55am
examples-react-d3 ⬜️ Ignored (Inspect) Visit Preview Mar 18, 2024 7:55am
examples-react-dashboard ⬜️ Ignored (Inspect) Visit Preview Mar 18, 2024 7:55am
examples-react-data-table ⬜️ Ignored (Inspect) Visit Preview Mar 18, 2024 7:55am
examples-react-highcharts ⬜️ Ignored (Inspect) Visit Preview Mar 18, 2024 7:55am
examples-react-material-ui ⬜️ Ignored (Inspect) Visit Preview Mar 18, 2024 7:55am
examples-react-pivot-table ⬜️ Ignored (Inspect) Visit Preview Mar 18, 2024 7:55am
examples-vue-query-builder ⬜️ Ignored (Inspect) Visit Preview Mar 18, 2024 7:55am

@github-actions github-actions bot added the pr:community Contribution from Cube.js community members. label Mar 18, 2024
Copy link

codecov bot commented Mar 18, 2024

Codecov Report

Attention: Patch coverage is 0% with 5 lines in your changes are missing coverage. Please review.

Project coverage is 48.04%. Comparing base (5a27200) to head (de68af3).
Report is 21 commits behind head on master.

Files Patch % Lines
...-orchestrator/src/orchestrator/RedisQueueDriver.ts 0.00% 5 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #7959      +/-   ##
==========================================
+ Coverage   48.02%   48.04%   +0.02%     
==========================================
  Files         154      154              
  Lines       21019    21020       +1     
  Branches     5264     5264              
==========================================
+ Hits        10095    10100       +5     
+ Misses      10723    10719       -4     
  Partials      201      201              
Flag Coverage Δ
cube-backend 48.04% <0.00%> (+0.02%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@igorlukanin
Copy link
Member

Hi @schneefux 👋 I'll let @paveltiunov to review this one but, just FYI, Redis support is deprecated and is subject to be removed from Cube: https://cube.dev/docs/product/deployment#redis

@paveltiunov
Copy link
Member

@schneefux Redis support is deprecated, and we do not accept any changes to this code base. Please consider moving to Cube Store.

@schneefux
Copy link
Author

Since migrating to cubestore in early fall last year, I've had severe performance issues, the cube API servers and cubestore would randomly hang up. This was probably caused by a memory leak introduced in 0.34, see #7545.

I have been running the Redis store for multiple years without any issues so I'd prefer to use it as long as possible until cubestore is more stable.

@paveltiunov
Copy link
Member

@schneefux Sorry to hear that! We didn't see anything like that in our production environments, so it might be configuration differences. We're open to merging any Cube Store fixes regarding OOM, and I believe this is the only way we have right now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pr:community Contribution from Cube.js community members.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants