Skip to content

TestTriggers is flaky #5421

Closed
Closed

Description

@smarterclayton
--- FAIL: TestTriggers_imageChange-2 (6.15s)
    deploy_trigger_test.go:164: unexpected error: imageStream "test-image-stream" cannot be updated: the object has been modified; please apply your changes to the latest version and try again
FAIL

@ironcladlou

Activity

  1. added
    kind/test-flake
    on Oct 27, 2015
  2. deads2k commented on Oct 27, 2015

    @deads2k
    Contributor

    Any chance this is going down the same path as #5410?

    If so, same question: Should the imagestreammapping.REST be retrying a couple times for you or would that be incorrect? It seems like you'd be safe to retry as long as the update did not mutate anything related to your tag, right?

  3. smarterclayton commented on Oct 27, 2015

    @smarterclayton
    ContributorAuthor

    Someone added a retry.

    On Tue, Oct 27, 2015 at 12:53 PM, David Eads [email protected]
    wrote:

    Any chance this is going down the same path as #5410
    #5410?

    If so, same question: Should the imagestreammapping.REST be retrying a
    couple times for you or would that be incorrect? It seems like you'd be
    safe to retry as long as the update did not mutate anything related to your
    tag, right?

    —
    Reply to this email directly or view it on GitHub
    #5421 (comment).

  4. deads2k commented on Oct 27, 2015

    @deads2k
    Contributor

    Someone added a retry.

    The question is at what level. I'd prefer doing it server-side as opposed to client-side. If we can set it up to use patch instead of replace, we'll get the retry and conflict detection for free.

  5. smarterclayton commented on Oct 27, 2015

    @smarterclayton
    ContributorAuthor

    You don't even need patch, you just need a retry loop, and no, it doesn't
    look like it was added to server side, but it should be as long as we can
    prove our tag wasn't mutated.

    On Tue, Oct 27, 2015 at 12:59 PM, David Eads [email protected]
    wrote:

    Someone added a retry.

    The question is at what level. I'd prefer doing it server-side as opposed
    to client-side. If we can set it up to use patch instead of replace, we'll
    get the retry and conflict detection for free.

    —
    Reply to this email directly or view it on GitHub
    #5421 (comment).

  6. ironcladlou commented on Oct 27, 2015

    @ironcladlou
    Contributor

    Looking closely at imagestreammapping.REST#Create, it no-ops when re-applying the same mapping in most cases, but it only looks back 1 element in the tag list so it seem possible that a retried change could overwrite a newer tag update.

    I think Create would have to ensure that len(ImageStream.Status.Tags[tag]) didn't change between retries.

  7. smarterclayton commented on Oct 27, 2015

    @smarterclayton
    ContributorAuthor

    Or that the most recent one is the same.

    On Tue, Oct 27, 2015 at 1:43 PM, Dan Mace [email protected] wrote:

    Looking closely at imagestreammapping.REST#Create, it no-ops when
    re-applying the same mapping in most cases, but it only looks back 1
    element in the tag list so it seem possible that a retried change could
    overwrite a newer tag update.

    I think Create would have to ensure that len(ImageStream.Status.Tags[tag])
    didn't change between retries.

    —
    Reply to this email directly or view it on GitHub
    #5421 (comment).

  8. ironcladlou commented on Oct 27, 2015

    @ironcladlou
    Contributor

    Yeah, looking again, that should work. Track the latest TagEvent, and compare on conflict.

  9. ironcladlou commented on Oct 27, 2015

    @ironcladlou
    Contributor

    Working on this here: https://github.com/openshift/origin/compare/master...ironcladlou:istmapping-create-retries?expand=1

    I'm still working on figuring out how to do the unit tests with the etcd test scaffolding.

  10. smarterclayton commented on Oct 28, 2015

    @smarterclayton
    ContributorAuthor
    I1027 23:38:37.491079    2824 create_dockercfg_secrets.go:177] View of ServiceAccount integration/default is not up to date, skipping dockercfg creation
    I1027 23:38:37.496554    2824 helper.go:366] UpdateTrackingTags: stream=integration/test-image-stream, updatedTag=latest, updatedImage.dockerImageReference=registry:8080/openshift/test-image@sha256:00000000000000000000000000000001, updatedImage.image=sha256:00000000000000000000000000000001
    --- FAIL: TestTriggers_imageChange-2 (6.42s)
        deploy_trigger_test.go:164: unexpected error: imageStream "test-image-stream" cannot be updated: the object has been modified; please apply your changes to the latest version and try again
    FAIL
    
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

kind/test-flake

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions