Logo F2FInterview

ASP .NET Interview Questions

Q   |   QA

Server.Transfer transfers page processing from one page directly to the next page without making a round-trip back to the client’s browser. This provides a faster response with a little less overhead on the server.Server.Transfer does not update the clients url history list or current url.
Response.Redirect is used toredirect the user’s browser to another page or site. This performs a trip back to the client where the client’s browser is redirected to the new page. The user’s browser history list is updated to reflect the new address.

private are stored in application / bin directory and public are stored in GAC.

A web farm is a multi-server scenario. So we may have a server in each state of US. If the load on one server is in excess then the other servers step in to bear the brunt.
How they bear it is based on various models.

  1. RoundRobin. (All servers share load equally)
  2. NLB (economical)
  3. HLB (expensive but can scale up to 8192 servers)
  4. Hybrid (of 2 and 3).
  5. CLB (Component load balancer).

A web garden is a multi-processor setup. i.e. a single server (not like the multi server above).
How to implement webfarms in .Net:
Go to web.config and

Here for mode you have 4 options.

  1. Say mode inproc (non web farm but fast when you have very few customers).
  2. Say mode StateServer (for webfarm)
  3. Say mode SqlServer (for webfarm)

Whether to use option b or c depends on situation. StateServer is faster but SqlServer is more reliable and used for mission critical applications.

Go to web.config and
Change the false to true. You have one more attribute that is related to webgarden in the same tag called cpuMask.

Is there any limit for query string? means what is the maximum size?
Servers should be cautious about depending on URI lengths above 255 bytes because some older client or proxy implementations may not properly support these lengths.
Query string length depends on browser compatability
IE supports upto 255
Firefox supports upto 4000

ASP.NET maps HTTP requests to HttpHandlers. Each HttpHandler enables processing of individual HTTP URLs or groups of URL extensions within an application. HttpHandlers have the same functionality as ISAPI extensions with a much simpler programming model

1.Default HttpHandler for all ASP.NET pages ->ASP.NET Page Handler (*.aspx)
2.Default HttpHandler for all ASP.NET service pages->ASP.NET Service Handler (*.asmx)

An HttpHandler can be either synchronous or asynchronous. A synchronous handler does not return until it finishes processing the HTTP request for which it is called. An asynchronous handler usually launches a process that can be lengthy and returns before that process finishes
After writing and compiling the code to implement an HttpHandler you must register the handler using your application’s Web.config file.

In order to link this F2FInterview's page as Reference on your website or Blog, click on below text area and pres (CTRL-C) to copy the code in clipboard or right click then copy the following lines after that paste into your website or Blog.

Get Reference Link To This Page: (copy below code by (CTRL-C) and paste into your website or Blog)
HTML Rendering of above code: