Skip to content

chore: compress large plugin_model obj in redis#38374

Merged
laipz8200 merged 2 commits into
langgenius:mainfrom
hjlarry:p451
Jul 3, 2026
Merged

chore: compress large plugin_model obj in redis#38374
laipz8200 merged 2 commits into
langgenius:mainfrom
hjlarry:p451

Conversation

@hjlarry

@hjlarry hjlarry commented Jul 3, 2026

Copy link
Copy Markdown
Contributor

Important

  1. Make sure you have read our contribution guidelines
  2. Ensure there is an associated issue and you have been assigned to it
  3. Use the correct syntax to link this PR: Fixes #<issue number>.

Summary

  • Compress large plugin_model_providers Redis payloads before caching.
  • Keep small payloads uncompressed with a 64KB threshold to avoid unnecessary CPU cost.
  • Add a versioned prefix for compressed values and keep backward compatibility with existing plain JSON cache entries.

Screenshots

Before After
... ...

Checklist

  • This change requires a documentation update, included: Dify Document
  • I understand that this PR may be closed in case there was no previous discussion or issues. (This doesn't apply to typos!)
  • I've added a test for each change that was introduced, and I tried as much as possible to make a single atomic change.
  • I've updated the documentation accordingly.
  • I ran make lint && make type-check (backend) and cd web && pnpm exec vp staged (frontend) to appease the lint gods

@dosubot dosubot Bot added the size:M This PR changes 30-99 lines, ignoring generated files. label Jul 3, 2026
@github-actions

github-actions Bot commented Jul 3, 2026

Copy link
Copy Markdown
Contributor

Pyrefly Type Coverage

Metric Base PR Delta
Type coverage 52.27% 52.27% +0.00%
Strict coverage 51.78% 51.78% +0.00%
Typed symbols 31,977 31,979 +2
Untyped symbols 29,478 29,478 0
Modules 2969 2969 0

@dosubot dosubot Bot added the lgtm This PR has been approved by a maintainer label Jul 3, 2026
@hjlarry hjlarry enabled auto-merge July 3, 2026 07:18
@hjlarry hjlarry added this pull request to the merge queue Jul 3, 2026
@hjlarry hjlarry removed this pull request from the merge queue due to a manual request Jul 3, 2026
@laipz8200 laipz8200 added this pull request to the merge queue Jul 3, 2026
Merged via the queue into langgenius:main with commit 059a1fe Jul 3, 2026
32 checks passed
hjlarry added a commit that referenced this pull request Jul 3, 2026
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
(cherry picked from commit 059a1fe)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

in-linear lgtm This PR has been approved by a maintainer size:M This PR changes 30-99 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants