Introduction to ASP.NET

Introduction to ASP.NET

Configuring .NET Web Applications MIS 424 Professor Sandvig Today 1. Why Web Applications? 2. IIS Role in handing a request IIS Applications

3. .NET Request Handling Global.asax 4. Configuration files Machine.config Web.Config

Why Applications? Dark ages (pre-2003) Server crashes not unusual Single failure bring down whole system Worse yet: Memory leaks

Cause IIS hang Stop serving pages Required manual intervention (reboot) Why Applications? Today Applications still crash Applications are compartmentalized OS handles gracefully

System rarely affected OS monitors application health Recycles unhealthy processes Result: system stable & reliable IIS Applications Folders may be configured as Applications

IIS configuration interface IIS Applications Many configuration options IIS Applications Each application is assigned to an Application Pool IIS Application Pools Each application pool has a unique Windows

process Specify error handling, timeouts, etc. for each Request Handling https://yorktown.cbe.wwu.edu/students/174/csandvig/music/index Source: https://codeteddy.com/2013/08/19/mvc3-interview-questions-and-answers/ .NET Application When URL points to IIS Application

IIS passes request to .NET .NET checks configuration files: Located in root folder global.asax Application event handler web.config Application configuration settings Global.asax

Handles application & session events 15+ events Application_start Application_error Session_start Located in root folder of application Triggered each page request

Global.asax Configures MVC application: public class WebApiApplication : System.Web.HttpApplication { protected void Application_Start() { AreaRegistration.RegisterAllAreas(); GlobalConfiguration.Configure(WebApiConfig.Register); FilterConfig.RegisterGlobalFilters(GlobalFilters.Filters); RouteConfig.RegisterRoutes(RouteTable.Routes); BundleConfig.RegisterBundles(BundleTable.Bundles); } }

web.config Located in root folder XML format Many settings:

Connection strings Authentication Debugging .NET version Exception handling Timeouts Others .Net Application Example Example:

Create new application on server Summary Application Objectives: Reliability Convenient Configuration Flexibility Security

IIS Handles requests Passes to .NET MVC Configuration Global.asax Web.config

Recently Viewed Presentations

  • Math 1330

    Math 1330

    Unit Circle Trigonometry. An angle is in standard position if its vertex is at the origin and its initial side is along the positive x axis. Positive angles are measured counterclockwise from the initial side. Negative angles are measured clockwise....
  • Chapter 13 Soil Analysis - Ms. Scholle

    Chapter 13 Soil Analysis - Ms. Scholle

    Arial Arial Black Wingdings Zapf Dingbats Default Design Chapter 13 Soil Analysis Forensic Geology Forensic Geologist Tools Forensic Geology History History Soil Soil Soil Soil Soil Comparisons Probative Value of Soil Increasing Probative Value Minerals Rocks Fossils Palynology Soil Evidence...
  • Presentation Template

    Presentation Template

    Burdett Trust for Nursing £200k funding to develop a programme of lifestyle support , Best Start, for women with a BMI ≥30 until March 2018. R&D support for ethical approval underway. Delivered in community venues . Delivered by Maternity Support...
  • Frequency Distributions

    Frequency Distributions

    Describing Data Lesson 3 Psychology & Statistics Goals of Psychology Describe, predict, influence behavior & cognitive processes Role of statistics Descriptive statistics Describe, organize & summarize data Efficient communication Inferential statistics Draw conclusions about data Aid decision making ~ Organizing...
  • Gnutella2: A Better Gnutella? - Carleton University

    Gnutella2: A Better Gnutella? - Carleton University

    Gnutella2: A Better Gnutella? COMP 5204: Data Networks Julie Thorpe School of Computer Science Carleton University Introduction Gnutella and Gnutella2 are P2P application protocols. Gnutella has an interesting history - essentially a reverse engineered Beta version. Changes governed by Gnutella...
  • Causes of WWI - MANIA!

    Causes of WWI - MANIA!

    Aftermath of the First World War "Picture Book Assignment" Reading and talking about major conflicts fails to provide a true understanding of these events. This is why you are going make a picture event of the First World War, showing...
  • SMART GOALS: Student Achievement Goal Setting: An Option

    SMART GOALS: Student Achievement Goal Setting: An Option

    SMART GOALS:Student Achievement Goal Setting: An Option for Connecting Teacher Performance to Academic Progress One approach to linking student achievement to teacher performance involves building the capacity for teachers and their supervisors to interpret and use student achievement data to...
  • Genetic Diseases and disorders - Betsy Sanford's Website

    Genetic Diseases and disorders - Betsy Sanford's Website

    Down Syndrome. What causes someone to get it? Down syndrome is caused by an extra chromosome on the 21st pair. Trisomy 21 is the most common form and is caused by every cell having 3 instead of 2 chromosomes on...