Development Performance Improvements.txt

Card Set Information

Author:
mateotete
ID:
268221
Filename:
Development Performance Improvements.txt
Updated:
2014-03-27 19:28:22
Tags:
Software Development Performance Improvements
Folders:
Software Development Performance Improvements
Description:
Software Development Performance Improvements
Show Answers:

Home > Flashcards > Print Preview

The flashcards below were created by user mateotete on FreezingBlue Flashcards. What would you like to do?


  1. What areas should we consider in ASP.NET applications?
    All areas, specifically, the front end HTML/CSS/Javascript, the Server-side code (C#, ASP.NET), and the database. However, approximately 80% of performance improvements are achieved on the clients browser. So spend, approximately 80% of your time on the front-end improvements.
  2. What performance improvements can typically be made on the database?
    (1). Indexing and non-indexing (2). Normalization of database (reduces redundancy) (3). Improve queries by reducing column returns such as the elimination of the * in the select statement (4). Stored procedures (compiled, run faster) (5) Use few functions in stored procedures cuz it slows the stored procedure down (6). Use SQL Analyser to get hints (7) reduce size of some columns, ie, varchar vs char vs text
  3. What performance improvements can typically be made in C# / ASP.NET?
    (1). State management so less traffic across network: ie, ViewState (2). Better data type calls / immutable objects, array, etc.(3). Improved data structures (iList, Dictionary)(4). Greater use of stored procedures(5). Release unneeded objects (Dispose)(6). Remove unneeded content in web.config file (6) passing of large objects by reference instead of by value, (7) greater use of global assemblies such as libraries used by multiple applications which are then cached on the server.
  4. What performance improvements can typically be made on the client side (HTML/CSS/JavaScript)?
    (1). Load files externally rather than in-line into the HTML (JavaScript, JQuery, CSS) (2) Remove cluttered and unused code from various external files such as CSS and JavaScript since this increase load time, (3). Optimize image files and content so that items are smaller, perhaps placing them into .jpg files or converting certain images into CSS manipulated files, (4). Perform better client-side interaction and validation (reduces network load), (5) use of JQuery to improve web browser accessibility and speed, (6) consider use of AJAX to reduce page postBacks, (7) CSS sprites, (8) client-side caching, (9) compression (images and files), (10) minification, (11) combinining
  5. How much improvement can modern website typically expect and from where?
    Modern websites can typically expect an 80% performance improvement simply by improvements made on the front-end. The fact of the matter is, when loading a webpage, servers are typically very fast in their response and so bottle-necks are almost always on the client machine or the network to-and-from the client to the server.
  6. Why would you want to compress and minimize your CSS and JavaScript files?
    (a) quicker download times for users, (b) small file sizes means reduced bandwidth consumption, (c) reduced HTTP Requests since files have been combined, reducing server load, (d) elimination of comment code and white spaces from JavaScript files will improve execution time
  7. What is file compression?
    Proprietary algorithm technique used by application creators to reduce file size without losing file functionality. For example, WinZIP is a compression application that reduces any file types, however, this application must also be used to decompress these files. When using CSS or JavaScript files, a compression utility such as Microsoft's Ajax Minifier can be used.
  8. What is JavaScript minification?
    Also known as minimization, it is the process of eliminating comment code and white spaces from a JavaScript file while retaining its exact functionality. Reducing its size speeds up its execution, download time, and bandwidth across the network.
  9. What, besides reducing image sizes, is the biggest website performance gain?
    Biggest single gain would probably be to combine, compress, minify, and cache all CSS, JavaScript, and JQuery files. This would because it reduces file sizes, network load, server processing, client processing, HTTP Request calls, load time, execution time, reduction in latency times, and other performance improvements in this simple step.
  10. What are some VERY useful applications for improving web performance?
    Fiddler, FireBug, Microsoft AJAX Minify, IE F12 Developer Tools, CSS Sprite Generator, and dozens of others.
  11. What is caching?
    Caching is the ability of the browser or proxy server to reuse CSS, JavaScript, images, or other elements of a page again and again, without having to fetch it from the server (for example, the logo found on every page of a website or the styling and javascript used throughout a website). It is accomplished by setting an expiration tag within the header of a HTTP Response sent back to the browser and contain things like no-caching, private/public caching, caching expiration, cache version (used for development updates), file last modified, file contents (image, css, javascript, etc).
  12. How do you cache a JavaScript and CSS file on client browser?
    Caching on the browser is typically defaulted already, however, you would also need to make sure that HTTP Response header doesn't contain any details to prevent or force the caching. Modifying the cache statements in the headers can be done in IIS or by modification to the web.config file, such as this statement to force a 30 day reload of cache:
  13. How would you reduce HTTP calls?
    This can be done by moving all CSS files into a single CSS downloaded file and then caching it; Similarly, all JavaScript files and JQuery files can be combined in a similar fashion. You can configure the web.config file to make Visual Studio use and work with standard files, but in production, combine all necessary files to be used on the server.
  14. How would you validate performance improvements?
    You would begin by using Fiddler or similar program to monitor several performance items, most typically, (a) size of files or images being downloaded, (b) number of times an HTTPResponse is made (ie, Microsoft website does 99 of these for their default page), and (c) load times associated with sending the HTTP content back to the client. Once you've made your various improvements, then you would compare your final results with your original results to determine the difference.
  15. When dealing with photos and non-photo images (icons, logo, etc), what file types should be used?
    Photos should be saved as .JPG images and icons or other non-photos should be saved as either .PNG or .GIF files; Each of these can also gain additional size reduction by using a 10% or greater compression technique.
  16. What are other benefits of placing all CSS and JavaScript files into a single file?
    (a) reuse of code, (b) prevents compiler from having to read html, stop and format something, then go back to reading html again (c) all styling can be loaded at once, (d) most importantly, this information can be loaded once, then cached for a time period since it will almost definitely be used on other pages, so won't need to be fetched from the server every time a PostBack or new page is viewed.
  17. Why should ALL styling be done in an external file rather than within the HTML code?
    (a) reuse of code, (b) prevents compiler from having to read html, stop and format something, then go back to reading html again (c) all styling can be loaded at once, (d) most importantly, this information can be loaded once, then cached for a time period since it will almost definitely be used on other pages, so won't need to be fetched from the server every time a PostBack or new page is viewed.

What would you like to do?

Home > Flashcards > Print Preview