Question: Code of return code specification design?

Source: Internet
Author: User

Return code Specification

Preferably in a system, or even a team, a company that follows a set of return status code rules and plans ahead, such as:
0001 ~ 1999, 2000 ~ 2999,4000 ~ 4999

These code segments can be as follows: Business type, according to the type of work, according to the architectural level ahead of planning, such as X~y is the network segment, which section for the error code, which is used for the success code, feel this from the architectural level of the relatively clear, all of a sudden know whether success or failure, And then according to the number of other bits can also identify the business layer above the characteristics, feel that these plans together have the best effect, give the code segment. So the overall plan can be unified.
ABCD four-bit
A:?
B:?
C:?
D:?

More mature systems, for example, some software, the site in various situations, or a variety of errors will have a return status code, I know that the status code of each business has, a system of business so much, there must be a good return code design specifications.

I would like to ask you general how to design this standard, according to what standards, where can find reference information?
(I remember where I've seen the design standard of the interface return code of the American group Takeout, now forget to find it)

Reply content:

Return code Specification

Preferably in a system, or even a team, a company that follows a set of return status code rules and plans ahead, such as:
0001 ~ 1999, 2000 ~ 2999,4000 ~ 4999

These code segments can be as follows: Business type, according to the type of work, according to the architectural level ahead of planning, such as X~y is the network segment, which section for the error code, which is used for the success code, feel this from the architectural level of the relatively clear, all of a sudden know whether success or failure, And then according to the number of other bits can also identify the business layer above the characteristics, feel that these plans together have the best effect, give the code segment. So the overall plan can be unified.
ABCD four-bit
A:?
B:?
C:?
D:?

More mature systems, for example, some software, the site in various situations, or a variety of errors will have a return status code, I know that the status code of each business has, a system of business so much, there must be a good return code design specifications.

I would like to ask you general how to design this standard, according to what standards, where can find reference information?
(I remember where I've seen the design standard of the interface return code of the American group Takeout, now forget to find it)

  • Contact Us

    The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

    If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.