{"id":44358,"date":"2024-08-06T15:23:06","date_gmt":"2024-08-06T19:23:06","guid":{"rendered":"https:\/\/mjtsai.com\/blog\/?p=44358"},"modified":"2024-08-06T15:23:06","modified_gmt":"2024-08-06T19:23:06","slug":"netnewswire-and-conditional-get-issues","status":"publish","type":"post","link":"https:\/\/mjtsai.com\/blog\/2024\/08\/06\/netnewswire-and-conditional-get-issues\/","title":{"rendered":"NetNewsWire and Conditional GET Issues"},"content":{"rendered":"<p><a href=\"https:\/\/inessential.com\/2024\/08\/03\/netnewswire_and_conditional_get_issues.html\">Brent Simmons<\/a> (<a href=\"https:\/\/indieweb.social\/@brentsimmons\/112900192417127467\">Mastodon<\/a>):<\/p>\n<blockquote cite=\"https:\/\/inessential.com\/2024\/08\/03\/netnewswire_and_conditional_get_issues.html\">\n<p>I had thought that NetNewsWire&rsquo;s conditional GET support was rock-solid &mdash;&nbsp;and so my first reaction was to be very surprised to <a href=\"https:\/\/rachelbythebay.com\/w\/2024\/08\/02\/fs\/\">learn that it&rsquo;s not<\/a>!<\/p>\n<p>[&#8230;]<\/p>\n<p>When a server returns a Last-Modified header, the client should return that exact same string in follow-up requests in an If-Modified-Since header. The server then looks at the If-Modified-Since header and decides to either return a 200 plus the feed &mdash; if it <em>has<\/em> been modified since &mdash;&nbsp;or return a 304 Not Modified response and an empty body.<\/p>\n<p>It&rsquo;s the same story with the Etag header. The client should save it and return it in follow-up requests in an If-None-Match header.<\/p>\n<p>[&#8230;]<\/p>\n<p>In some cases, NetNewsWire is not picking up and saving the changed Last-Modified and Etag headers. Sometimes it does, and sometimes it keeps using whatever it already had and ignores the new ones.<\/p>\n<\/blockquote>\n<p>I had been meaning to file a bug about this because I&rsquo;d noticed in my server logs that sometimes a lot more full requests were being served than I expected. That is, on a day when I didn&rsquo;t make any posts, I would have expected the feed to be mostly cached by NetNewsWire, but it wasn&rsquo;t. However, many other times it seemed like the conditions GETs <em>were<\/em> working. Simmons found a bug that perhaps explains this.<\/p>\n\n<p>The other NetNewsWire issue I&rsquo;ve been seeing is <a href=\"https:\/\/github.com\/Ranchero-Software\/NetNewsWire\/issues\/4240\">this one<\/a>, where sometimes it stops syncing with Feedbin until it&rsquo;s restarted.<\/p>\n\n<p>Previously:<\/p>\n<ul>\n<li><a href=\"https:\/\/mjtsai.com\/blog\/2020\/05\/19\/why-netnewswire-is-fast\/\">Why NetNewsWire Is Fast<\/a><\/li>\n<\/ul>","protected":false},"excerpt":{"rendered":"<p>Brent Simmons (Mastodon): I had thought that NetNewsWire&rsquo;s conditional GET support was rock-solid &mdash;&nbsp;and so my first reaction was to be very surprised to learn that it&rsquo;s not! [&#8230;] When a server returns a Last-Modified header, the client should return that exact same string in follow-up requests in an If-Modified-Since header. The server then looks [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"apple_news_api_created_at":"2024-08-06T19:23:08Z","apple_news_api_id":"9ce5f99d-3540-4916-9d55-4b5b2b106523","apple_news_api_modified_at":"2024-08-06T19:23:08Z","apple_news_api_revision":"AAAAAAAAAAD\/\/\/\/\/\/\/\/\/\/w==","apple_news_api_share_url":"https:\/\/apple.news\/AnOX5nTVASRadVUtbKxBlIw","apple_news_coverimage":0,"apple_news_coverimage_caption":"","apple_news_is_hidden":false,"apple_news_is_paid":false,"apple_news_is_preview":false,"apple_news_is_sponsored":false,"apple_news_maturity_rating":"","apple_news_metadata":"\"\"","apple_news_pullquote":"","apple_news_pullquote_position":"","apple_news_slug":"","apple_news_sections":"\"\"","apple_news_suppress_video_url":false,"apple_news_use_image_component":false,"footnotes":""},"categories":[2],"tags":[131,30,32,2385,392,138,52,1659,96,740],"class_list":["post-44358","post","type-post","status-publish","format-standard","hentry","category-technology","tag-bug","tag-mac","tag-macapp","tag-macos-14-sonoma","tag-netnewswire","tag-optimization","tag-rss","tag-this-blog","tag-web","tag-wordpress"],"apple_news_notices":[],"_links":{"self":[{"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/posts\/44358","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/comments?post=44358"}],"version-history":[{"count":1,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/posts\/44358\/revisions"}],"predecessor-version":[{"id":44359,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/posts\/44358\/revisions\/44359"}],"wp:attachment":[{"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/media?parent=44358"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/categories?post=44358"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/mjtsai.com\/blog\/wp-json\/wp\/v2\/tags?post=44358"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}