Hi, I have a general question about how breaking c...
# pactflow
s
Hi, I have a general question about how breaking changes in contracts should be managed for eg, if a provider changes an endpoint and updates the provider state accordingly, previously published consumer contract may no longer be valid. As a result, the provider verification tests start failing in the provider pipeline. What is the recommended approach for handling breaking changes in this scenario? How should providers and consumers coordinate contract updates to avoid pipeline failures while still ensuring compatibility?
m
Typically if you must release a breaking change, you would follow the expand-and-contract pattern. Add the new behaviour in a backwards compatible way. Consumers move to new behaviour Then you can deprecate/remove old behaviour
If you must force a breaking change through, you can do it, you just need to work around the can-i-deploy gates that are likely to block you
s
Thank you