Skip to content

OkHttpConnector_Cache_MaxAgeDefault_Zero fails when Last-Modified header is correct format #597

Closed

Description

@bitwiseman

The OkHttp 2.7.5 connector test for caching fails when the test data is updated.

Before the attached commit, the generated string was in the format: "2019-09-06T23:26:04Z"
After the change, the generated string is in the correct RFC-1123 format: "Fri, 06 Sep 2019 23:26:04 GMT"

This second one is what GitHub returns.

Changing the offset to a time much further in the past (`offset='-10007 seconds', for example) does not fix the behavior.

I'm not sure if this is a problem with the test data or OkHttp, but OkHttp3 works as expected.

Activity

  1. added a commit that references this issue on Nov 7, 2019
  2. changed the title [-]OkHttpConnector_Cache_MaxAgeDefault_Zero fails when Last-Modified header is correct format[/-] [+]OkHttpConnector_Cache_MaxAgeDefault_Zero fails when `Last-Modified` header is correct format[/+] on Nov 7, 2019
  3. bitwiseman commented on Nov 7, 2019

    @bitwiseman
    MemberAuthor

    Some comparing of the responses that come back from GitHub and the generated test data show:

    • GitHub Last-Modified stays the same for same for 304 cache hits
    • Test-generated Last-Modified changes for each response due to limitations in the templating engine. Actually, it is less a hard limitation but that getting the behavior to match GitHub is more difficult.

    This test important, but more in an informational sense than in a day-to-day sense. As long as the OkHttp3 version of the test works, we can leave this test turned off for now.

  4. bitwiseman commented on Mar 15, 2021

    @bitwiseman
    MemberAuthor

    OkHttp 2.x has been deprecated.

  5. added a commit that references this issue on Nov 4, 2021
    7a91e43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions