Skip to content

Conversation

@lcomplete
Copy link
Owner

Summary

  • Implement HTTP 304 Not Modified support for RSS feed fetching using ETag and Last-Modified headers
  • Store HTTP cache headers (ETag, Last-Modified) in Connector entity for conditional requests
  • Skip feed processing entirely when server returns 304, reducing unnecessary work and bandwidth
  • Update batch organize button to always display item count for clarity

Test plan

  • Verify RSS feeds still fetch correctly on first request
  • Confirm subsequent fetches send If-None-Match and If-Modified-Since headers
  • Validate that 304 responses skip feed processing
  • Check that cache headers are properly stored and retrieved from database
  • Test batch organize button shows correct count text

🤖 Generated with Claude Code

Implement ETag and Last-Modified header caching to skip unnecessary
feed processing when content hasn't changed. Also update batch organize
button text to always show count.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@augmentcode
Copy link

augmentcode bot commented Jan 20, 2026

🤖 Augment PR Summary

Summary: This PR adds conditional HTTP caching for RSS connector fetches so unchanged feeds can be skipped via 304 Not Modified, and updates the batch organize UI to always show counts.

Changes:

  • Persist RSS HTTP cache metadata (ETag, Last-Modified) on the Connector entity and expose it via ConnectorProperties.
  • Add result wrappers (FeedFetchResult, FetchPagesResult) to carry both fetched content and cache header state.
  • Implement FeedUtils.fetchFeed(...) using If-None-Match/If-Modified-Since and short-circuit on HTTP 304.
  • Extend InfoConnector with a cache-aware fetchNewestPagesWithCache() (defaulting to existing behavior).
  • Update RSSConnector to use conditional requests and return cache headers alongside pages.
  • Update ConnectorFetchService to skip RSS processing entirely when the feed is not modified, and to store updated cache headers.
  • UI: Adjust the batch organize action button to always display the item count for clarity.

Technical Notes: Uses OkHttp response headers (ETag, Last-Modified) for persistence and sends them back on subsequent requests as conditional headers.

🤖 Was this summary useful? React with 👍 or 👎

Copy link

@augmentcode augmentcode bot left a comment

Choose a reason for hiding this comment

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

Review completed. 1 suggestions posted.

Fix All in Augment

Comment augment review to trigger a new review at any time.

fetchResult.getHttpLastModified());
}
} else {
// For first fetch or non-RSS connectors, use regular fetch
Copy link

Choose a reason for hiding this comment

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

In fetchPages, the “first fetch” path for RSS goes through fetchAllPages()/fetchNewestPages() and never persists httpEtag/httpLastModified, so conditional headers won’t be sent until a later run. Consider capturing/updating cache headers on the initial successful RSS fetch too so the very next poll can benefit from 304 responses.

Fix This in Augment

🤖 Was this useful? React with 👍 or 👎

@lcomplete lcomplete merged commit 8e3ca13 into main Jan 20, 2026
1 of 3 checks passed
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