Monday, September 24, 2012

Behind the scene when Surfing the Web

Have you ever thought about what happens when you surf the web? It’s not as simple as it seems:

    1.    You type an URL into address bar in your preferred browser.

    2.    The browser parses the URL to find the protocol, host, port, and path.

    3.    It forms a HTTP request (that was most likely the protocol)

    4.    To reach the host, it first needs to translate the human readable host into an IP number, and it does this by doing a DNS lookup on the host

    5.    Then a socket needs to be opened from the user’s computer to that IP number, on the port specified (most often port 80)

    6.    When a connection is open, the HTTP request is sent to the host

    7.    The host forwards the request to the server software (most often Apache) configured to listen on the specified port

    8.    The server inspects the request (most often only the path), and launches the server plugin needed to handle the request (corresponding to the server language you use, PHP, Java, .NET, Python?)

    9.    The plugin gets access to the full request, and starts to prepare a HTTP response.

    10.    To construct the response a database is (most likely) accessed. A database search is made, based on parameters in the path (or data) of the request

    11.    Data from the database, together with other information the plugin decides to add, is combined into a long string of text (probably HTML).

    12.    The plugin combines that data with some meta data (in the form of HTTP headers), and sends the HTTP response back to the browser.

    13.    The browser receives the response, and parses the HTML (which with 95% probability is broken) in the response

    14.    A DOM tree is built out of the broken HTML

    15.    New requests are made to the server for each new resource that is found in the HTML source (typically images, style sheets, and JavaScript files). Go back to step 3 and repeat for each resource.

    16.    Stylesheets are parsed, and the rendering information in each gets attached to the matching node in the DOM tree

    17.    Javascript is parsed and executed, and DOM nodes are moved and style information is updated accordingly

    18.    The browser renders the page on the screen according to the DOM tree and the style information for each node

    19.    You see the page on the screen

Thursday, September 13, 2012

Tips for ensuring great performance and Customer Experience of your Website.


Better, faster web experiences result in higher conversion rates, greater customer satisfaction and an edge over the competition. Monitoring users on your website allows you to find out how fast a website loads and how well it performs for your customers. Websites are rarely accessed in perfect conditions or from ideal circumstances; there are many variables, from platform and browser version through to connection quality and physical location. End user experience monitoring allows businesses to have visibility of the way real users with different localities, experience a website. Here’s a quick overview of what to consider:

1. Understand why you are doing it
Why do you need good performance on your website? Poor performance results in lost revenues, brand damage, increased support calls, higher costs, and forces expensive tactical decision making. Today’s internet users are not patient. In fact, 57% of people will abandon a site after a 3 second wait for a page to load; 80% of these people will not return, and of those people, almost half will go on to tell others of their negative experience. Users also perceive load times to be slower than they actually are, and increasingly slower when recounting the experience to others. In short, bad performance and slow site speed not only directly affects your bottom line; it can actually drive your customers away to your competitors – often for good.

2. Know what good performance looks like
To achieve good performance, you need to know how to define it. A customer is happy when a site performs to their expectations. How fast are your competitors’ websites? Where are you in terms of your industry’s average? What level of performance is realistic and affordable for you? Consider these points from the start of development and before you start to measure performance.

3. Find the right tools for the job
There are many performance monitoring tools out there that work in different ways and deliver different benefits. Know what’s out there, what you want to get out of your monitoring, and pick your tools accordingly. Consider a combination of solutions and make sure your team knows how the get the most out of each. It’s best to ask for guidance from an expert, as a lot of time could be spent looking over all the options available.

4. Understand normality
By analysing your website and knowing what is “normal”, you will understand your site better and will be able to make better recommendations to improve it. What does a “normal day” look like? If you don’t know this, you don’t know what your measurements really imply or what the appropriate response to these metrics could be. For example, if you have a cut off time for orders, it might be normal to see more visitors and slower pages just before this time each day, whereas a spike of slow page load times at a period where there is not usually a lot of visitors would warrant closer inspection.

5. Anticipate trends
You can’t directly influence the behaviour of your customers, but you can anticipate what they are likely to do based on watching current trends, acting accordingly and staying ahead of the competition. This could mean any number of customer behaviours, from the type of devices they are using (such as mobile, desktops, tablets), the time of day they are accessing certain areas of your site, or increasing expectations around the speed of websites. This can be done through investigation of your website’s analytics or from the advisement of industry leaders and experts.

6. Stay close to the end user
While you must monitor performance from the backbone of your system, it’s also vitally important to make sure your end users are getting the best possible experience with your website. It always makes sense to take on your customers’ viewpoint to make sure they are getting the service you are aiming to deliver. Make sure you use the right tools for this job and have good visibility of your users, wherever they may be and however they might be accessing your site.

7. Measure all components
As well as measuring the parts of your site you have control over, you must also understand the effect of external (third party) elements have on your site. This could be social plugins like Facebook and Twitter buttonsor any content hosted externally. You may not have direct control over them, but if they’re on your site, you need to know all about how they are affecting the end user experience.

8. Serve key customer groups
With the huge variety of devices, browsers, browser versions, locations and connections that could be used by your potential end users, it’s virtually impossible to account for everyone equally when optimising your website. Know who your key customer groups are and make sure they are the ones who are driving your business decisions. Crucially, continue to monitor who these people are and, again, where the trends are heading to keep your business focused.

9. Set iterative goals
Assuming you understand where your customers are, how they are accessing your site, and how well your competitors are performing, you will be able to set manageable goals leading to increased commercial success for your business. Know what’s possible and how to go about making those things happen.

10. Make Performance holistic
Performance is not just about technicians and monitoring, it is driven by the line of business. Good performance, considered early on in a project, allows you to take your strategy to the market; a holistic view of your performance should bridge gaps between teams and departments, aligning business and technical goals. This goes all the way from developers and QA through to marketing and C level.

Change Or Be Extinct

All the slow hedgehogs are dead

For fifty years, it was a national disgrace.

Motor cars in the UK often left behind road kill. Hedgehogs would meander across the road and splat.
Today, you hardly see that anymore. One reason is that there are fewer hedgehogs due to suburbanization.

The real reason, though, is that slow hedgehogs became former hedgehogs, which meant that they were unable to produce more slow hedgehog kids. The new hedgehogs are fast.


Draw your own organizational analogy.

-Seth Goden