Created issue: https://github.com/gocd/gocd/issues/13003

On Friday 9 August 2024 at 10:37:42 UTC+10 Tina Boyce wrote:

> Thank you Chad and Aravind for the quick helpful response.
>
> I'll look into the API pipeline referencing a config repo pipeline 
> further, get it easily reproduced and then raise the issue with the 
> findings.
>
> On Fri, 9 Aug 2024 at 02:32, Aravind SV <[email protected]> wrote:
>
>> Yes, you're right Chad. That is not intentional. I suspect the API is 
>> using the "merged" config to do its validation, instead of using the 
>> representation of the config XML. It is an oversight / bug.
>>
>> Cheers,
>> Aravind
>>
>> On Thu, Aug 8, 2024 at 3:57 PM Chad Wilson <[email protected]> 
>> wrote:
>>
>>> Hiya Tina
>>>
>>> I believe it is intentional that you cannot (normally) reference a 
>>> config repo pipeline from a manually created pipeline (that otherwise sits 
>>> in the config.xml).
>>>
>>> https://github.com/gocd/gocd/issues/10667 has some 
>>> discussion/explanation of this, along with 
>>> https://github.com/gocd/gocd/issues/1133#issuecomment-109785886 and 
>>> https://github.com/gocd/gocd/issues/1133#issue-77045258
>>>
>>> However it sounds like an oversight or bug that the API is allowing you 
>>> to do this (and take down the server). I do not know if that is 
>>> intentional, but I suspect now - and really the API should be consistent 
>>> with the UI in matters of "safety" such as this. Would probably be 
>>> worthwhile raising an issue to investigate the inconsistency and try and 
>>> fix the API validation if at all possible.
>>>
>>> -Chad
>>>
>>> On Thu, Aug 8, 2024 at 10:47 PM Tina Boyce <[email protected]> wrote:
>>>
>>>> I came across an interesting behaviour and I was wondering if this is 
>>>> already known or expected, or is it a bug?
>>>>
>>>> I've created 3 pipelines:
>>>>
>>>>    - child (through UI)
>>>>    - parent (in my git repo, imported by config repo setting)
>>>>    - parent-mkII (through UI)
>>>>
>>>> [image: Screenshot 2024-08-09 at 12.09.26 AM.png]
>>>>
>>>> I then went into the "child" pipeline setting > Materials > Add 
>>>> Material and in the Upstream Stage drop-down, the only given options was 
>>>> "parent-mkII"
>>>> [image: Screenshot 2024-08-09 at 12.13.05 AM.png]
>>>>
>>>> This is not an isolated incident and what prompted me to start 
>>>> investigating was when I brought down gocd server a few times when I used 
>>>> the gocd api to deploy pipelines where the request body config referenced 
>>>> a 
>>>> pipeline that was deployed through the config repo. 
>>>>
>>>> The server error message was very similar every time, it was "Error: 
>>>> Pipeline 'from-config-repo' does not exist. It is used from pipeline 
>>>> 'from-api'.". However, it works fine if a pipeline is from the config repo 
>>>> referencing another pipeline from config repo.
>>>>
>>>> -- 
>>>> You received this message because you are subscribed to the Google 
>>>> Groups "go-cd" group.
>>>> To unsubscribe from this group and stop receiving emails from it, send 
>>>> an email to [email protected].
>>>> To view this discussion on the web visit 
>>>> https://groups.google.com/d/msgid/go-cd/8c35ce75-e0e4-4532-82d3-10d40ba303a3n%40googlegroups.com
>>>>  
>>>> <https://groups.google.com/d/msgid/go-cd/8c35ce75-e0e4-4532-82d3-10d40ba303a3n%40googlegroups.com?utm_medium=email&utm_source=footer>
>>>> .
>>>>
>>> -- 
>>> You received this message because you are subscribed to the Google 
>>> Groups "go-cd" group.
>>> To unsubscribe from this group and stop receiving emails from it, send 
>>> an email to [email protected].
>>> To view this discussion on the web visit 
>>> https://groups.google.com/d/msgid/go-cd/CAA1RwH96yQ1q7ES_pXSXRnayg2QxdovGZUNm_eSaPJs8ySmshA%40mail.gmail.com
>>>  
>>> <https://groups.google.com/d/msgid/go-cd/CAA1RwH96yQ1q7ES_pXSXRnayg2QxdovGZUNm_eSaPJs8ySmshA%40mail.gmail.com?utm_medium=email&utm_source=footer>
>>> .
>>>
>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "go-cd" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to [email protected].
>>
> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/go-cd/CACxychHYXRV2iG4DpqAk2gQhsXdf4ZpESo-7PB3aqNoxfwHzUQ%40mail.gmail.com
>>  
>> <https://groups.google.com/d/msgid/go-cd/CACxychHYXRV2iG4DpqAk2gQhsXdf4ZpESo-7PB3aqNoxfwHzUQ%40mail.gmail.com?utm_medium=email&utm_source=footer>
>> .
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"go-cd" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/go-cd/dfd08ce2-8a62-4331-ab9c-57442b23635bn%40googlegroups.com.

Reply via email to