Front: form their own methodology

Methodology, by definition, is through baptism everyday items, through their own temper, form a set methodology.

In the front end, with a variety of methodologies, everyone's not the same methodology. So my idea is to form a set of how to troubleshoot error methodology.

Our project on the line, my thinking is: disaster recovery and monitoring is the last safeguard of our project, we should as far as possible in the coding and testing phase, circumvention.

  • Coding phase: the implementation of code review, code review of the use of Git mechanism, so that the same group of colleagues in the current project code review, code guide unreasonable, modify as soon as possible.
  • Unit of testing: unit not to write large coverage, through the code, but to the user (caller) point of view, various possibilities to test code logic, and further enhance the auxiliary code robustness

Throughout the project we are adding a variety of monitoring and logging mechanisms, such as we use in front-end performanceto monitor the performance of the page, and we also set up an early warning mechanism, when we set the upper limit is exceeded, provide us with alarm information, help us to respond in a timely manner.

1. troubleshoot problems arise online

For example, one day we suddenly receive a warning message, increase overall page load time, the error rate increase, exceeding the threshold value I set, and then view a detailed log and found loaded with a lot of blank image, and through this information after in-depth investigation, found that the final question is: avatar image server fluctuations, resulting in the interface returns an empty picture address, and then loaded a variety of front-end empty picture. After finding the reason for the repair measures that I do here is: the avatar picture as lazy loading, at the same time, add a default avatar picture address null address.

Troubleshoot problems arise online

2. A summary of the methodology

Just by the above examples, we can summarize the methodology set troubleshoot the problem:

  1. Detailed efficient feedback mechanism;
  2. problem found;
  3. Analysis of the positioning problem;
  4. Solve the problem

Ultimately form their own set of methodologies.

This methodology can be used to promote other projects, when there is a new on-line project, should first establish an effective mechanism for collecting feedback and error before you can make a quick response, and ultimately solve the problem. Rather than always waiting for user feedback when the user's feedback appears inevitable that there is a particularly serious problem.

Guess you like

Origin www.cnblogs.com/xumengxuan/p/11464760.html
own