Skip to content

Resource get does not perform a check #1748

Closed

Description

@william-tran

Bug Report

Raised as feature request #1719 but this looks like a bug.

Given a pipeline:

resources:
- name: trigger
  type: git
  check_every: 10s
  source:
    uri: https://github.com/william-tran/pipeline-test.git
- name: repo
  type: git
  check_every: 1000h
  source:
    uri: https://github.com/william-tran/pipeline-test.git
jobs:
- name: output-readme
  plan:
  - get: trigger
    trigger: true
  - get: repo
  - task: output-readme
    config:
      platform: linux
      image_resource:
        type: docker-image
        source:
          repository: alpine
      inputs:
      - name: repo
      run:
        path: /bin/sh
        args: ["-c", "cat repo/README.md"]

When I push a commit to https://github.com/william-tran/pipeline-test, I would expect output-readme to reflect that change, but it doesn't. Previous behaviour was that

Every time a get happens it always performs a check to pull the latest version.

But that doesn't seem to happen now.

  • Concourse version: 3.5.0
  • Deployment type (BOSH/Docker/binary): Helm chart
  • Infrastructure/IaaS: AWS
  • Did this used to work? Yes from what I hear.

Activity

  1. vito commented on Oct 26, 2017

    @vito
    Contributor

    That was never the case. checks are only performed in two cases:

    1. periodically in the pipeline, and
    2. when manually triggering a build, prior to determining its inputs

    Automatically scheduled builds have all their get steps pinned at the point the build is enqueued. There is no need to check as all versions are already determined, as they needed to be to determine whether to queue the build in the first place (to know that a version is 'new'). There are no timing guarantees or correlation of resource versions.

    I don't see this being fixed unless you can tie it to a higher level conceptual model. If you have two different resources, without anything tying them together concretely, Concourse has no incentive to guarantee any sort of correlation.

    It may be incidentally fixed if we e.g. globalize resource configuration such that versions are tied to anonymous self-identifying resources rather than pipeline resources, but I wouldn't model this as a regression, and don't think this use case should be a prime motivation for that change.

  2. william-tran commented on Oct 26, 2017

    @william-tran
    ContributorAuthor

    Thank you for the quick response and clarification @vito.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions