Skip to content

Add auto-repair options for broken AOF tail on startup#7

Open
tomerqodo wants to merge 22 commits into
codex_full_base_add_auto-repair_options_for_broken_aof_tail_on_startup_pr7from
codex_full_head_add_auto-repair_options_for_broken_aof_tail_on_startup_pr7
Open

Add auto-repair options for broken AOF tail on startup#7
tomerqodo wants to merge 22 commits into
codex_full_base_add_auto-repair_options_for_broken_aof_tail_on_startup_pr7from
codex_full_head_add_auto-repair_options_for_broken_aof_tail_on_startup_pr7

Conversation

@tomerqodo

Copy link
Copy Markdown

Benchmark PR from agentic-review-benchmarks#7

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 5c59ae6e67

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread src/server.h
Comment on lines +15 to +16
#ifndef _REDIS_H
#define _REDIS_H

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P1 Badge Restore double-underscore include guard

This change switches the include guard to _REDIS_H, but the repository compliance rules in /workspace/redis-combined-codex/AGENTS.md (Rule 3: “Header Files Must Use Double-Underscore Include Guards”) require #ifndef __FILENAME_H/#define __FILENAME_H. Keeping the single-underscore guard will violate the documented repo standard and should be treated as a compliance failure for any file under this scope.

Useful? React with 👍 / 👎.

Comment thread src/aof.c
Comment on lines +1841 to 1842
if (ret == AOF_OPEN_ERR || ret == AOF_FAILED || ret == AOF_BROKEN_RECOVERED) {
goto cleanup;

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Avoid treating recovered AOF as fatal in base load

When aof-load-broken successfully recovers the base AOF and it is the last file, loadAppendOnlyFiles will still jump to cleanup because AOF_BROKEN_RECOVERED is included in this fatal condition. That exits before server.aof_current_size and server.aof_rewrite_base_size are initialized later in the function, leaving them at defaults (e.g., 0). This can skew INFO output and rewrite thresholds after a recovered startup. The recovered case should continue through the normal post-load initialization.

Useful? React with 👍 / 👎.

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.

2 participants