Skip to content

Conversation

DrFaust92
Copy link

@DrFaust92 DrFaust92 commented Aug 6, 2025

Summary by CodeRabbit

  • New Features
    • Configurable revisionHistoryLimit added for main, worker, and webhook deployments to control how many previous revisions are retained (improves rollback control).
  • Documentation
    • Values documentation updated to describe the new revisionHistoryLimit setting for main, worker, and webhook.
  • Chores
    • Helm chart metadata and version bumped to 1.0.14; release notes/annotations updated to reflect support for revisionHistoryLimit.

Copy link
Contributor

coderabbitai bot commented Aug 6, 2025

Walkthrough

Added revisionHistoryLimit values for main, worker, and webhook and wired them into their respective Kubernetes Deployment templates; bumped chart version and updated artifacthub change notes. No other functional changes.

Changes

Cohort / File(s) Change Summary
Deployment Templates Update
charts/n8n/templates/deployment.yaml, charts/n8n/templates/deployment.worker.yaml, charts/n8n/templates/deployment.webhook.yaml
Inserted revisionHistoryLimit under each Deployment spec, referencing .Values.main.revisionHistoryLimit, .Values.worker.revisionHistoryLimit, and .Values.webhook.revisionHistoryLimit respectively.
Helm Values Configuration
charts/n8n/values.yaml, README.md
Added revisionHistoryLimit: 10 to the main, worker, and webhook sections in values and documented the new field in README.
Chart Metadata
charts/n8n/Chart.yaml
Bumped chart version from 1.0.13 to 1.0.14 and updated annotations.artifacthub.io/changes entry to: "Support setting revisionHistoryLimit".

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Possibly related PRs

  • feat: Release 1.0.1 #142 — Related chart metadata/version annotation edits touching charts/n8n/Chart.yaml.
  • Next Gen Chart #132 — Related changes to Helm templates and .Values.main/.Values.worker/.Values.webhook structure; likely connected to value-driven template updates.

Tip

🔌 Remote MCP (Model Context Protocol) integration is now available!

Pro plan users can now connect to remote MCP servers from the Integrations page. Connect with popular remote MCPs such as Notion and Linear to add more context to your reviews and chats.


📜 Recent review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

💡 Knowledge Base configuration:

  • MCP integration is disabled by default for public repositories
  • Jira integration is disabled by default for public repositories
  • Linear integration is disabled by default for public repositories

You can enable these sources in your CodeRabbit configuration.

📥 Commits

Reviewing files that changed from the base of the PR and between 084ee6b and c760792.

📒 Files selected for processing (6)
  • README.md (3 hunks)
  • charts/n8n/Chart.yaml (2 hunks)
  • charts/n8n/templates/deployment.webhook.yaml (1 hunks)
  • charts/n8n/templates/deployment.worker.yaml (1 hunks)
  • charts/n8n/templates/deployment.yaml (1 hunks)
  • charts/n8n/values.yaml (3 hunks)
✅ Files skipped from review due to trivial changes (2)
  • README.md
  • charts/n8n/templates/deployment.yaml
🚧 Files skipped from review as they are similar to previous changes (4)
  • charts/n8n/Chart.yaml
  • charts/n8n/templates/deployment.webhook.yaml
  • charts/n8n/templates/deployment.worker.yaml
  • charts/n8n/values.yaml
✨ Finishing Touches
🧪 Generate unit tests
  • Create PR with unit tests
  • Post copyable unit tests in a comment

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

CodeRabbit Commands (Invoked using PR/Issue comments)

Type @coderabbitai help to get the list of available commands.

Other keywords and placeholders

  • Add @coderabbitai ignore or @coderabbit ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Status, Documentation and Community

  • Visit our Status Page to check the current availability of CodeRabbit.
  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

🧹 Nitpick comments (4)
charts/n8n/values.yaml (1)

133-135: Deduplicate the identical revisionHistoryLimit defaults

The same literal value (10) is repeated for main, worker, and webhook. Consider a single source of truth to avoid accidental drift—e.g.

# top-level default
revisionHistoryLimit: 10

and then in each section:

revisionHistoryLimit: *revisionHistoryLimit  # YAML anchor/alias

or reference it in the templates with default.
This keeps the chart DRY and reduces maintenance overhead.

Also applies to: 326-328, 515-517

charts/n8n/templates/deployment.yaml (1)

15-19: Provide a fallback in case the value is unset

If a user deletes the key or passes it as null, Helm will render an empty value resulting in an invalid manifest (revisionHistoryLimit: ). Add a default to keep the manifest valid:

-  revisionHistoryLimit: {{ .Values.main.revisionHistoryLimit }}
+  revisionHistoryLimit: {{ default 10 .Values.main.revisionHistoryLimit }}

This mirrors Kubernetes’ own default (10) while remaining override-able.

charts/n8n/templates/deployment.worker.yaml (1)

18-20: Same fallback recommendation as for the main deployment

-  revisionHistoryLimit: {{ .Values.worker.revisionHistoryLimit }}
+  revisionHistoryLimit: {{ default 10 .Values.worker.revisionHistoryLimit }}
charts/n8n/templates/deployment.webhook.yaml (1)

19-22: Same fallback recommendation as for the main deployment

-  revisionHistoryLimit: {{ .Values.webhook.revisionHistoryLimit }}
+  revisionHistoryLimit: {{ default 10 .Values.webhook.revisionHistoryLimit }}
📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between d5a4b1e and e2b754b.

📒 Files selected for processing (4)
  • charts/n8n/templates/deployment.webhook.yaml (1 hunks)
  • charts/n8n/templates/deployment.worker.yaml (1 hunks)
  • charts/n8n/templates/deployment.yaml (1 hunks)
  • charts/n8n/values.yaml (3 hunks)

@RoseSecurity
Copy link
Contributor

Thoughts on using YAML anchors to reduce repetition here?

@DrFaust92
Copy link
Author

For a oneliner I think it adds more confusion than it helps but im fine with whatever maintainers decide

@RoseSecurity
Copy link
Contributor

Testing this today. Thank you for the contribution

@RoseSecurity
Copy link
Contributor

Would you also be able to bump the chart version (follow the Chart Versioning Schema). Then in Chart.yaml, replace the content of the artifacthub.io/changes section. See the ArtifactHub annotation reference.

@DrFaust92 DrFaust92 force-pushed the revisionhistorylimit branch from e2b754b to 39aea42 Compare August 23, 2025 19:27
@DrFaust92
Copy link
Author

RoseSecurity added changelog

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

🧹 Nitpick comments (5)
charts/n8n/Chart.yaml (1)

37-38: Tighten ArtifactHub change entry and add context/link.

Minor polish: make it explicit that all Deployments are covered and add a link back to the PR for traceability in ArtifactHub.

Apply this diff:

   artifacthub.io/changes: |
-    - kind: added
-      description: "Support setting revisionHistoryLimit"
+    - kind: added
+      description: "Support setting revisionHistoryLimit on main, worker and webhook Deployments."
+      links:
+        - name: "PR #221"
+          url: "https://github.com/8gears/n8n-helm-chart/pull/221"
charts/n8n/values.yaml (4)

133-135: Good default; consider clarifying behavior when set to 0.

Defaulting to 10 mirrors Kubernetes’ default. Add a brief note that 0 disables revision history to help users tune cleanup.

Apply this diff:

   # How many old ReplicaSets for the Deployment to retain to allow rollback.
+  # Note: set to 0 to disable retention entirely.
   revisionHistoryLimit: 10

326-328: Mirror the same doc hint for worker.

Keep docs consistent across components.

Apply this diff:

   # How many old ReplicaSets for the Deployment to retain to allow rollback.
+  # Note: set to 0 to disable retention entirely.
   revisionHistoryLimit: 10

515-517: Mirror the same doc hint for webhook.

Keep docs consistent across components.

Apply this diff:

   # How many old ReplicaSets for the Deployment to retain to allow rollback.
+  # Note: set to 0 to disable retention entirely.
   revisionHistoryLimit: 10

133-135: Optional: Consolidate revisionHistoryLimit Defaults

The three identical defaults can be centralized to reduce duplication and simplify future changes:

• In charts/n8n/values.yaml at lines 134, 327, 516, you define

revisionHistoryLimit: 10

under each of main, worker, and webhook.
• In the templates—

  • charts/n8n/templates/deployment.yaml (line 18)
  • charts/n8n/templates/deployment.worker.yaml (line 19)
  • charts/n8n/templates/deployment.webhook.yaml (line 21)
    —each spec.revisionHistoryLimit references its corresponding section:
revisionHistoryLimit: {{ .Values.<component>.revisionHistoryLimit }}

Proposed approach:

  1. Add a top-level common default in values.yaml:
    common:
      revisionHistoryLimit: 10
  2. Remove the duplicated revisionHistoryLimit: 10 entries under main, worker, and webhook (or leave them empty for overrides).
  3. Update each template to fall back to the shared value:
    spec:
      revisionHistoryLimit: {{ .Values.main.revisionHistoryLimit | default .Values.common.revisionHistoryLimit }}
    
    (and similarly for worker and webhook).

This keeps a single source of truth while still allowing per-component overrides.

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

💡 Knowledge Base configuration:

  • MCP integration is disabled by default for public repositories
  • Jira integration is disabled by default for public repositories
  • Linear integration is disabled by default for public repositories

You can enable these sources in your CodeRabbit configuration.

📥 Commits

Reviewing files that changed from the base of the PR and between e2b754b and c0f3c66.

📒 Files selected for processing (5)
  • charts/n8n/Chart.yaml (2 hunks)
  • charts/n8n/templates/deployment.webhook.yaml (1 hunks)
  • charts/n8n/templates/deployment.worker.yaml (1 hunks)
  • charts/n8n/templates/deployment.yaml (1 hunks)
  • charts/n8n/values.yaml (3 hunks)
🚧 Files skipped from review as they are similar to previous changes (3)
  • charts/n8n/templates/deployment.yaml
  • charts/n8n/templates/deployment.webhook.yaml
  • charts/n8n/templates/deployment.worker.yaml
🔇 Additional comments (1)
charts/n8n/Chart.yaml (1)

3-3: SemVer bump to 1.1.0 is appropriate for an additive feature.

Feature addition without breaking changes warrants a minor version bump. Looks good.

@DrFaust92
Copy link
Author

RoseSecurity gentle reminder.

@Vad1mo
Copy link
Member

Vad1mo commented Aug 29, 2025

If you change the value.yaml please update the Readme accordingly and in the right spot

Signed-off-by: drfaust92 <[email protected]>
Signed-off-by: drfaust92 <[email protected]>
Signed-off-by: drfaust92 <[email protected]>
@DrFaust92 DrFaust92 force-pushed the revisionhistorylimit branch from 084ee6b to e6924d3 Compare August 29, 2025 16:44
@DrFaust92
Copy link
Author

Vad1mo I can do it, seems a bit too manual to me though. I would recommend a more automated method using https://github.com/norwoodj/helm-docs to generate it from values.yaml. wdyt?

Signed-off-by: drfaust92 <[email protected]>
@DrFaust92
Copy link
Author

Vad1mo added refs in docs in any case

@Vad1mo
Copy link
Member

Vad1mo commented Aug 29, 2025

Vad1mo I can do it, seems a bit too manual to me though. I would recommend a more automated method using https://github.com/norwoodj/helm-docs to generate it from values.yaml. wdyt?

I don't like the table output, it kills readability and take a huge amount of space

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants