Web front end about function monitoring explained

Source: Internet
Author: User
Tags webpagetest

First, what is the front-end point?

On the Web site, the same as usual refers to the site of the front desk, which is the web use of users can see the tools.

Second, because what to do front-end monitoring?

Front-end resource loading is the biggest impact on the function, the load of resources, the number of concurrent, there are a lot of homework to do: for example, if you create a CSS before loading the obstruction time is very long, it is likely that the resource load is unreasonable, which will inevitably cause the reader foil delay.

Third, the front-end Function monitoring policy

White screen Hour: Users from the beginning of the page to the beginning of the page has tools to appear

First screen hour: the user Reader in the first screen of all the content has come out of the hour of breaking

User can interact hours: The user can stop the normal click, input and other control, the default promises to accounting Domready hour, because the same will be at this time the sub-binding work control

Total download Time: Page All the resources are loaded to the end of the time it took to appear, that is, the page onload hour

Determining the starting point for accounting

Requirements in the user input URL may click on the link at the beginning of accounting, due to the ability to weigh the user's waiting hour. High-end reader navigation timing interface; As usual, the reader is calculated by means of a cookie in real time, and the demand is that the cookie method only accounts for the data that jumps in the station.

The accounting of white screen Hour

White screen hour refers to the user perceive see the content of the hour, also known as perceive foil hour, chrome high version has Firstpainttime interface to get this time-consuming, but large local reader does not support, it is necessary to think of other methods to monitor. Detailed query Worship Webpagetest view decomposition creation, white screen hour is now the head outside the chain resources loaded near, because the reader only load and parse the head resources will actually foil page. According to this can be obtained after the head resources loaded time to approximate accounting white screen hour. Although it is not true, it considers the primary identity that affects white screen: the first byte hour and the head resource loading hour.

How to calculate the head resource load? Create the head embedded JS as usual need to wait for the front of the js\css load will be fulfilled, is not in the head of the reader in the bottom add a sentence JS accounting head resource loading finish point? You can stop an exam with a simple example:

Web front end about function monitoring explained

Accounting of the head load hour just fall down the resources download hour around, and to a performance time is very long JS will also be the ratio of JS performance after accounting. This method is feasible (detailed reason can be procuratorial reader foil affair and JS single-line Superelectron introduction).

Accounting for the first screen hour

The first screen hour of accounting bucket strength disorder, due to the involvement of various elements such as pictures and asynchronous foil and other methods. Query the load view of the loading views can create, affect the first screen of the image of the primary identity. Through the calculation of the first screen image loading hour can get the first screen foil end of the hour. The process of accounting is as follows:

First screen orientation misappropriation API start Accounting-binding first screen inside all pictures of load work-page after loading to determine whether the picture in the first screen, find the slowest loading of a first screen hour.

There is an IFRAME in the case of the need to judge loading hour

GIF images may trigger load on IE frequently to be cleaned

In the case of asynchronous foil, the first screen should be calculated after getting the data into the asynchronous

CSS important background image can be calculated via JS voices Image URL (reader will not load frequently)

There is no picture to account JS performance hour-led screen, that is, the words appear hour

Accounting for total user control and total downloads

The user can control the tacit promise to calculate domready hour, because the same as usual will be at this time sub-binding work control. On the use of modular asynchronous loading JS can be in the code to actively sign the important JS loading hour, which is the product policy accounting method

Total download Shicheneme promised to calculate the onload hour, such as promised to account for the synchronization load of all the time-loaded resources. If there is a lot of asynchronous foil on the page, you can end the asynchronous foil as the total download hour

Iv. Functional Monitoring Tools

Because the method and policy of aggregating data are different, the front-end Function monitoring is divided into two types, non-intrusive type and intrusive type.

Type

Interests

Defects

Example

Non-intrusive

The policy is thorough, the client actively monitors, competes the product to monitor

Can not know the function affects the number of users, sampling less simple distortion, unable to detect the use of disorders and subdivision function

Yslow, Pagespeed, Dynatrace, Fiddler, Webpagetest (online), Gtmetrix (online)

Invasive type

In fact, a huge amount of user data, can monitor the use of disorders and business functions, user clicks and regional foil

Need to stab into the script accounting, collection policy is not complete, unable to monitor the competition goods

Navigation Timing API, Resource Timing API

Two prerequisites for accounting for screenplay requirements

1. Prevention of aggression against business code

2, does not affect the measurement of the function of the page

Want to further study the small partner can add my front-end Learning Exchange Group 606721798, the latest free learning materials, video. Reception yours faithfully arrival, feel write can also point under attention.

Web front end about function monitoring explained

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.