Skip to content

Conversation

@remicollet
Copy link
Contributor

See #2678

Track in moduleLoadQueueEntry where the module was loaded from

  • config (moduleEnqueueLoadModule)*
  • command (module load or loaded)

Only add loadmodule line when not from config to avoid duplicate line.

@codecov
Copy link

codecov bot commented Oct 4, 2025

Codecov Report

❌ Patch coverage is 0% with 12 lines in your changes missing coverage. Please review.
✅ Project coverage is 72.17%. Comparing base (0646749) to head (b40ab88).

Files with missing lines Patch % Lines
src/module.c 0.00% 8 Missing ⚠️
src/config.c 0.00% 4 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff              @@
##           unstable    #2689      +/-   ##
============================================
- Coverage     72.18%   72.17%   -0.01%     
============================================
  Files           128      128              
  Lines         71037    71041       +4     
============================================
- Hits          51277    51275       -2     
- Misses        19760    19766       +6     
Files with missing lines Coverage Δ
src/module.h 0.00% <ø> (ø)
src/config.c 78.64% <0.00%> (-0.10%) ⬇️
src/module.c 9.77% <0.00%> (-0.01%) ⬇️

... and 12 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@zuiderkwast zuiderkwast requested a review from rjd15372 October 4, 2025 07:24
@remicollet
Copy link
Contributor Author

Notice: this fixes the loadmodule case

but can be considered as a workaround, the main issue is that the included configuration files are not managed during the rewrite process, so they can generate duplication.

@remicollet
Copy link
Contributor Author

I have slightly reduced the PR by protecting only loadmodule from include files.
So for main configuration file, the behavior is unchanged

@ranshid ranshid added major-decision-pending Major decision pending by TSC team needs-doc-pr This change needs to update a documentation page. Remove label once doc PR is open. labels Oct 6, 2025
@zuiderkwast
Copy link
Contributor

zuiderkwast commented Oct 6, 2025

I think this is a bugfix and I think we should backport it. I can't see how it's a breaking change, or even a behavior change for any working configuration.

@zuiderkwast
Copy link
Contributor

@remicollet Please fix the DCO issue. Essentially, commits need to be done with git commit -s. See the DCO failing check details page for information.

@remicollet
Copy link
Contributor Author

@remicollet Please fix the DCO issue. Essentially, commits need to be done with git commit -s. See the DCO failing check details page for information.

Smashed and signed

@zuiderkwast
Copy link
Contributor

Great, but author and signer emails need to match.

only protect loadmodule from include files

Signed-off-by: Remi Collet <remi@remirepo.net>
@remicollet
Copy link
Contributor Author

Great, but author and signer emails need to match.

fixed

@madolson
Copy link
Member

madolson commented Oct 6, 2025

Core team meeting discussion:

  1. We need to also validate the behavior for normal module configs when the module is unloaded and a user does CONFIG REWRITE as we might have the same issue with the server not starting because the module config will still be present.
  2. We think CONFIG REWRITE doesn't make that much sense for production workloads, we should probably consider deprecating it or something to avoid people using it in the future, or more properly fix the behavior with CONFIG REWRITE and includes.
  3. We think in the fullness of time we would like to add a way for operators to disable CONFIG REWRITE to prevent users from accidentally breaking applications. We will figure out the proper way to do that for 9.1 (if it's backwards compatible) or 10 (if it's behavior change).

@madolson madolson moved this to Todo in Valkey 9.1 Oct 6, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

major-decision-pending Major decision pending by TSC team needs-doc-pr This change needs to update a documentation page. Remove label once doc PR is open.

Projects

Status: Todo

Development

Successfully merging this pull request may close these issues.

4 participants