Hi there, I need some more clarification about `co...
# pact-broker
s
Hi there, I need some more clarification about
contract_requiring_verification_published
event. The doc, stated that "A webhook using the
contract_requiring_verification_published
should be configured to pass through the
${pactbroker.pactUrl}
and
${pactbroker.providerVersionNumber}
and
${pactbroker.providerVersionBranch}
to the provider verification build." I assume we need to pass version number (assume it is git SHA) so that we can checkout that GIT version before verifying the pact My questions is why do we need to pass
pactUrl
and
providerVersionBranch
& and how that can be useful?
m
The
pactUrl
is the thing that is being verified. Itโ€™s the pact that needs to be verified
the branch may not be required, if you can derive what version to checkout from the version number (e.g. itโ€™s a git SHA)
b
Some ci systems want the branch to be supplied when you trigger a build.
๐Ÿ‘ 1
This is because a commit can belong to multiple branches, and to populate the branch build properties correctly, it needs to know the branch.
๐Ÿ‘ 1
s
@Matt (pactflow.io / pact-js / pact-go) So instead of
consumerVersionTags
, we should use
pactUrl
to get the correct contract from
pact broker
right?
โ˜๏ธ 1
m
Only for the webhook, yes
s
Great ๐Ÿ‘. So what about the main build pipeline? Keep using consumerVersionTags?
โ˜๏ธ 1
Just one more question, let's say I have the master branch , test and prod environment. If a contract changes then does it trigger 3 builds?
m
If the provider versions that need to be verified are all different then yes, if they are the same then it will de-duplicate them