Which is the better approach to web services - contract first or contract last?

后端 未结 3 869
长情又很酷
长情又很酷 2021-02-07 18:06

Which is the better approach to developing web services; contract first or contract last?
What are the advantages and disadvantages of each?

Which do you have experi

3条回答
  •  一向
    一向 (楼主)
    2021-02-07 18:24

    I suspect the answer is a definite "it depends."

    The issue is that if you build and publish your contract, you're bound by it. This makes change harder. not impossible, but harder.

    On the other hand, it's quicker to mess with the contract than with code, if you're comfortable with schemata etc. So you can do some incremental change in the contract.

    Aren't there also tools that will generate a code skeleton from the WSDL? I'm almost positive there are. If so, you might do well to make the schemata the "code" item, and generate code from it.

提交回复
热议问题