Should a business rule violation throw an exception?

后端 未结 14 648
误落风尘
误落风尘 2021-02-04 04:18

Should a business rule violation throw an exception?

14条回答
  •  后悔当初
    2021-02-04 05:01

    No Violating a business rule is a BUSINESS issue where an exception is a technical one. Violating a business rule is something that the system should regard as normal operation and for which it should have a programmed response, not an exception.

提交回复
热议问题