SlideShare ist ein Scribd-Unternehmen logo
1 von 26
Hosting Windows Services in IIS Take advantage of the IIS platform for hosting your Always-On services. Brian Ritchie Chief ArchitectPayformance Corporation Email: brian.ritchie@gmail.com Blog: http://weblog.asp.net/britchie Web: http://www.dotnetpowered.com
Who am I? Brian Ritchie Chief Architect at Payformance Corporation Nearly 20 years of development experience Developing on .NET since 1.0 Beta 1 Contributed to Mono and other open source projects
Why build Windows Services? When you need always-on functionality Examples: File Watching & Processing Scheduled tasks Long-running tasks Queued processing
Why build Windows Services? Windows Services have been around forever, why change now?
Sometimes change is good
Reasons for change Windows Services have no User Interface making them hard to monitor, manage, and debug. Windows Services are harder to deploy & can’t use Web Deploy.
Who can save us from these problems? I’m IIS & I’m here to help!
Did you say IIS? More than just a web server, IIS is an application server platform. Web Applications: ASP.NET, PHP, and more Web Services: ASMX, WCF Multiple Protocols: HTTP, HTTPS, TCP, Named Pipes And now
 Always-On Services: Auto-start & Always Running
What makes IIS better?
IIS7: Your Single Hosting Framework
Monitoring via the IIS Manager Since all services will be hosted under the w3wp.exe process name, you can see the Worker Process associated with your application pool within the IIS manager:
Monitoring via Process Explorer Another approach is to use the SysInternals Process Explorer free from Microsoft.  Add the “Command Line” column to the grid, and the application pool name will be listed after the –ap switch.
Deployments
made easy Web Deploy 2.1  Deploy Package Build/Deploy Server Build Server (using MSBuild) Deployment Package IIS Server IIS MMC – Export Application IIS MMC – Import Application
Look Mom
I have a UI now! No longer “invisible”, your service can publish its own monitoring & management capability
OK
I’m sold!   How can I take this beauty home today?
Getting Started First off
Install the pre-reqs: IIS 7.5 (Windows 2008 R2 or Windows 7) Windows Server AppFabric .NET Framework 4.0 Next
Configure IIS: Set Application Pool to “Always Running” Configure Site with Net.Pipe Binding Set Application to “Auto Start”
Walk Thru: Configuring IIS
Building a service
Building a service What are some fundamental differences between a standard Web Service and a Windows Service? Request-Response vs. Event-based  State-less vs. State-full Transparent threading vs. Thread Management DLL vs. EXE All of the Above
Building a Service:Differences in Process Models Windows Service Process Model Service Controller Service (EXE) MMC
Building a Service:Differences in Process Models Windows Service Process Model IIS Worker Process Model Service Controller Service (EXE) MMC W3WP WWW Publishing Service svchost.exe -k iissvcs AppDomain Service (DLL) IIS Manager AppDomain
Building a service Where does the service perform it’s startup? Application_Startin Global.asax AppInitialize in AppStart.cs AppStartup in the session controller
Building a service What is the scope of a static variables? Class Thread AppDomain Process Machine
Visualizing the stack Machine Process AppDomain Your service runs here Thread Thread Static Scope Either you manage threads directly or use a Thread Pool or TPL
Walk Thru: Building a service
Twitter: @brian_ritchie Blog: http://weblogs.asp.net/britchie Thanks for coming!

Weitere Àhnliche Inhalte

Was ist angesagt?

introduction and configuration of IIS (in addition with printer)
introduction and configuration of IIS (in addition with printer)introduction and configuration of IIS (in addition with printer)
introduction and configuration of IIS (in addition with printer)Assay Khan
 
Hosting a website on IIS Server
Hosting a website on IIS ServerHosting a website on IIS Server
Hosting a website on IIS ServerDinesh Vasamshetty
 
Understanding iis part1
Understanding iis part1Understanding iis part1
Understanding iis part1Om Vikram Thapa
 
Iis it-slideshares.blogspot.com
Iis it-slideshares.blogspot.comIis it-slideshares.blogspot.com
Iis it-slideshares.blogspot.comphanleson
 
IIS for Developers
IIS for DevelopersIIS for Developers
IIS for DevelopersIdo Flatow
 
INTRODUCTION TO IIS
INTRODUCTION TO IISINTRODUCTION TO IIS
INTRODUCTION TO IISsanya6900
 
The complete ASP.NET (IIS) Tutorial with code example in power point slide show
The complete ASP.NET (IIS) Tutorial with code example in power point slide showThe complete ASP.NET (IIS) Tutorial with code example in power point slide show
The complete ASP.NET (IIS) Tutorial with code example in power point slide showSubhas Malik
 
Introduction To Iis 7
Introduction To Iis 7Introduction To Iis 7
Introduction To Iis 7amit_monty
 
All About Asp Net 4 0 Hosam Kamel
All About Asp Net 4 0  Hosam KamelAll About Asp Net 4 0  Hosam Kamel
All About Asp Net 4 0 Hosam KamelHosam Kamel
 
Owin from spec to application
Owin from spec to applicationOwin from spec to application
Owin from spec to applicationdamian-h
 
Microsoft/Zend Webcast on Cloud Computing
Microsoft/Zend Webcast on Cloud ComputingMicrosoft/Zend Webcast on Cloud Computing
Microsoft/Zend Webcast on Cloud ComputingJosh Holmes
 
Understanding a web server and types of web servers ppt
Understanding a web server and types of web servers pptUnderstanding a web server and types of web servers ppt
Understanding a web server and types of web servers pptNivi Sharma
 
Web Servers (ppt)
Web Servers (ppt)Web Servers (ppt)
Web Servers (ppt)webhostingguy
 
Windows Server AppFabric Caching - What it is & when you should use it?
Windows Server AppFabric Caching - What it is & when you should use it?Windows Server AppFabric Caching - What it is & when you should use it?
Windows Server AppFabric Caching - What it is & when you should use it?Robert MacLean
 

Was ist angesagt? (20)

introduction and configuration of IIS (in addition with printer)
introduction and configuration of IIS (in addition with printer)introduction and configuration of IIS (in addition with printer)
introduction and configuration of IIS (in addition with printer)
 
IIS-Settings
IIS-SettingsIIS-Settings
IIS-Settings
 
Hosting a website on IIS Server
Hosting a website on IIS ServerHosting a website on IIS Server
Hosting a website on IIS Server
 
Understanding iis part1
Understanding iis part1Understanding iis part1
Understanding iis part1
 
Understanding IIS
Understanding IISUnderstanding IIS
Understanding IIS
 
Iis it-slideshares.blogspot.com
Iis it-slideshares.blogspot.comIis it-slideshares.blogspot.com
Iis it-slideshares.blogspot.com
 
IIS for Developers
IIS for DevelopersIIS for Developers
IIS for Developers
 
INTRODUCTION TO IIS
INTRODUCTION TO IISINTRODUCTION TO IIS
INTRODUCTION TO IIS
 
The complete ASP.NET (IIS) Tutorial with code example in power point slide show
The complete ASP.NET (IIS) Tutorial with code example in power point slide showThe complete ASP.NET (IIS) Tutorial with code example in power point slide show
The complete ASP.NET (IIS) Tutorial with code example in power point slide show
 
Introduction To Iis 7
Introduction To Iis 7Introduction To Iis 7
Introduction To Iis 7
 
All About Asp Net 4 0 Hosam Kamel
All About Asp Net 4 0  Hosam KamelAll About Asp Net 4 0  Hosam Kamel
All About Asp Net 4 0 Hosam Kamel
 
Chapter 26
Chapter 26Chapter 26
Chapter 26
 
Owin from spec to application
Owin from spec to applicationOwin from spec to application
Owin from spec to application
 
Microsoft/Zend Webcast on Cloud Computing
Microsoft/Zend Webcast on Cloud ComputingMicrosoft/Zend Webcast on Cloud Computing
Microsoft/Zend Webcast on Cloud Computing
 
Understanding a web server and types of web servers ppt
Understanding a web server and types of web servers pptUnderstanding a web server and types of web servers ppt
Understanding a web server and types of web servers ppt
 
Web Servers (ppt)
Web Servers (ppt)Web Servers (ppt)
Web Servers (ppt)
 
ASP.NET Web form
ASP.NET Web formASP.NET Web form
ASP.NET Web form
 
Windows Server AppFabric Caching - What it is & when you should use it?
Windows Server AppFabric Caching - What it is & when you should use it?Windows Server AppFabric Caching - What it is & when you should use it?
Windows Server AppFabric Caching - What it is & when you should use it?
 
App fabric introduction
App fabric introductionApp fabric introduction
App fabric introduction
 
IIS 7.0 +
IIS 7.0 +IIS 7.0 +
IIS 7.0 +
 

Andere mochten auch

PHP em Background
PHP em BackgroundPHP em Background
PHP em BackgroundVitor Mattos
 
Technical writing training 2013 14 (2)
Technical writing training 2013 14 (2)Technical writing training 2013 14 (2)
Technical writing training 2013 14 (2)laxmi16101981
 
Troubleshooting SQL Server
Troubleshooting SQL ServerTroubleshooting SQL Server
Troubleshooting SQL ServerStephen Rose
 
Troubleshooting SQL Server 2000 Virtual Server /Service Pack ...
Troubleshooting SQL Server 2000 Virtual Server /Service Pack ...Troubleshooting SQL Server 2000 Virtual Server /Service Pack ...
Troubleshooting SQL Server 2000 Virtual Server /Service Pack ...webhostingguy
 
Building your first sql server cluster
Building your first sql server clusterBuilding your first sql server cluster
Building your first sql server clusterJoseph D'Antoni
 
Sql Cluster Tech Net 0401(Pm)
Sql Cluster Tech Net 0401(Pm)Sql Cluster Tech Net 0401(Pm)
Sql Cluster Tech Net 0401(Pm)bigqiang zou
 
How To Set Up SQL Load Balancing with HAProxy - Slides
How To Set Up SQL Load Balancing with HAProxy - SlidesHow To Set Up SQL Load Balancing with HAProxy - Slides
How To Set Up SQL Load Balancing with HAProxy - SlidesSeveralnines
 
Sql server troubleshooting
Sql server troubleshootingSql server troubleshooting
Sql server troubleshootingNathan Winters
 
SQL Server Cluster Presentation
SQL Server Cluster PresentationSQL Server Cluster Presentation
SQL Server Cluster Presentationwebhostingguy
 
Technical Writing PowerPoint
Technical Writing PowerPointTechnical Writing PowerPoint
Technical Writing PowerPointkgillesss
 
Always on in SQL Server 2012
Always on in SQL Server 2012Always on in SQL Server 2012
Always on in SQL Server 2012Fadi Abdulwahab
 
Introduction to technical writing
Introduction to technical writingIntroduction to technical writing
Introduction to technical writingAdam Tablante
 
All About Technical Writing
All About  Technical  WritingAll About  Technical  Writing
All About Technical Writingshravanpalvai
 
Qualities of good technical writing with examples
Qualities of good technical writing with examplesQualities of good technical writing with examples
Qualities of good technical writing with examplesmuhammad ilyas
 
ENG 131: Technical Writing Introduction PowerPoint
ENG 131: Technical Writing Introduction PowerPointENG 131: Technical Writing Introduction PowerPoint
ENG 131: Technical Writing Introduction PowerPointElizabeth Lohman
 

Andere mochten auch (17)

PHP em Background
PHP em BackgroundPHP em Background
PHP em Background
 
Technical writing training 2013 14 (2)
Technical writing training 2013 14 (2)Technical writing training 2013 14 (2)
Technical writing training 2013 14 (2)
 
Troubleshooting SQL Server
Troubleshooting SQL ServerTroubleshooting SQL Server
Troubleshooting SQL Server
 
Troubleshooting SQL Server 2000 Virtual Server /Service Pack ...
Troubleshooting SQL Server 2000 Virtual Server /Service Pack ...Troubleshooting SQL Server 2000 Virtual Server /Service Pack ...
Troubleshooting SQL Server 2000 Virtual Server /Service Pack ...
 
Ntlm
NtlmNtlm
Ntlm
 
Building your first sql server cluster
Building your first sql server clusterBuilding your first sql server cluster
Building your first sql server cluster
 
Sql Cluster Tech Net 0401(Pm)
Sql Cluster Tech Net 0401(Pm)Sql Cluster Tech Net 0401(Pm)
Sql Cluster Tech Net 0401(Pm)
 
How To Set Up SQL Load Balancing with HAProxy - Slides
How To Set Up SQL Load Balancing with HAProxy - SlidesHow To Set Up SQL Load Balancing with HAProxy - Slides
How To Set Up SQL Load Balancing with HAProxy - Slides
 
Troubleshooting sql server
Troubleshooting sql serverTroubleshooting sql server
Troubleshooting sql server
 
Sql server troubleshooting
Sql server troubleshootingSql server troubleshooting
Sql server troubleshooting
 
SQL Server Cluster Presentation
SQL Server Cluster PresentationSQL Server Cluster Presentation
SQL Server Cluster Presentation
 
Technical Writing PowerPoint
Technical Writing PowerPointTechnical Writing PowerPoint
Technical Writing PowerPoint
 
Always on in SQL Server 2012
Always on in SQL Server 2012Always on in SQL Server 2012
Always on in SQL Server 2012
 
Introduction to technical writing
Introduction to technical writingIntroduction to technical writing
Introduction to technical writing
 
All About Technical Writing
All About  Technical  WritingAll About  Technical  Writing
All About Technical Writing
 
Qualities of good technical writing with examples
Qualities of good technical writing with examplesQualities of good technical writing with examples
Qualities of good technical writing with examples
 
ENG 131: Technical Writing Introduction PowerPoint
ENG 131: Technical Writing Introduction PowerPointENG 131: Technical Writing Introduction PowerPoint
ENG 131: Technical Writing Introduction PowerPoint
 

Ähnlich wie IIS Always-On Services

Scaling Out .NET
Scaling Out .NETScaling Out .NET
Scaling Out .NETBrian Ritchie
 
Scalable And Usable Web Applications
Scalable And Usable Web ApplicationsScalable And Usable Web Applications
Scalable And Usable Web ApplicationsClint Edmonson
 
Windows Server 2008 R2 Dev Session 03
Windows Server 2008 R2 Dev Session 03Windows Server 2008 R2 Dev Session 03
Windows Server 2008 R2 Dev Session 03Clint Edmonson
 
IBM Impact Session 2351 hybrid apps
IBM Impact Session 2351 hybrid appsIBM Impact Session 2351 hybrid apps
IBM Impact Session 2351 hybrid appsnick_garrod
 
Office Add ins community call-February 2019
Office Add ins community call-February 2019Office Add ins community call-February 2019
Office Add ins community call-February 2019Microsoft 365 Developer
 
Guide to Vite JS – Modern Fron-End Development Tool
Guide to Vite JS – Modern Fron-End Development ToolGuide to Vite JS – Modern Fron-End Development Tool
Guide to Vite JS – Modern Fron-End Development ToolAlbiorix Technology
 
ArcReady - Scalable And Usable Web Applications
ArcReady - Scalable And Usable Web ApplicationsArcReady - Scalable And Usable Web Applications
ArcReady - Scalable And Usable Web ApplicationsMicrosoft ArcReady
 
Service Oriented UI Architecture in the world of web, desktop, & mobile appli...
Service Oriented UI Architecture in the world of web, desktop, & mobile appli...Service Oriented UI Architecture in the world of web, desktop, & mobile appli...
Service Oriented UI Architecture in the world of web, desktop, & mobile appli...Axway Appcelerator
 
SD Forum Java SIG - Service Oriented UI Architecture
SD Forum Java SIG - Service Oriented UI ArchitectureSD Forum Java SIG - Service Oriented UI Architecture
SD Forum Java SIG - Service Oriented UI ArchitectureJeff Haynie
 
OWIN (Open Web Interface for .NET)
OWIN (Open Web Interface for .NET)OWIN (Open Web Interface for .NET)
OWIN (Open Web Interface for .NET)Folio3 Software
 
Mobile Commerce ppt....... Provides a website interface to the customers to b...
Mobile Commerce ppt....... Provides a website interface to the customers to b...Mobile Commerce ppt....... Provides a website interface to the customers to b...
Mobile Commerce ppt....... Provides a website interface to the customers to b...punita_uttam
 
Best practices for upgrading vb 6.0 projects to vb.net
Best practices for upgrading vb 6.0 projects to vb.netBest practices for upgrading vb 6.0 projects to vb.net
Best practices for upgrading vb 6.0 projects to vb.netajmal_fuuast
 
The Power of IBM API Management. API connect 2016 Vegas
The Power of IBM API Management. API connect 2016 VegasThe Power of IBM API Management. API connect 2016 Vegas
The Power of IBM API Management. API connect 2016 VegasSaaS-Journal
 
Building CI/CD Pipelines for Serverless Applications
Building CI/CD Pipelines for Serverless ApplicationsBuilding CI/CD Pipelines for Serverless Applications
Building CI/CD Pipelines for Serverless ApplicationsDaniel Zivkovic
 
How DotNet, SharePoint, and Azure helps to build a Custom Web Application wi...
 How DotNet, SharePoint, and Azure helps to build a Custom Web Application wi... How DotNet, SharePoint, and Azure helps to build a Custom Web Application wi...
How DotNet, SharePoint, and Azure helps to build a Custom Web Application wi...Aimore Technologies
 
HAM 1032 Combining the Power of IBM API Management and IBM Integration Bus
HAM 1032 Combining the Power of IBM API Management and IBM Integration BusHAM 1032 Combining the Power of IBM API Management and IBM Integration Bus
HAM 1032 Combining the Power of IBM API Management and IBM Integration BusKaren Broughton-Mabbitt
 
Development of skype for business and knowledge of
Development of skype for business and knowledge ofDevelopment of skype for business and knowledge of
Development of skype for business and knowledge ofayemyatmoe069
 

Ähnlich wie IIS Always-On Services (20)

Scaling Out .NET
Scaling Out .NETScaling Out .NET
Scaling Out .NET
 
Scalable And Usable Web Applications
Scalable And Usable Web ApplicationsScalable And Usable Web Applications
Scalable And Usable Web Applications
 
Windows Server 2008 R2 Dev Session 03
Windows Server 2008 R2 Dev Session 03Windows Server 2008 R2 Dev Session 03
Windows Server 2008 R2 Dev Session 03
 
IBM Impact Session 2351 hybrid apps
IBM Impact Session 2351 hybrid appsIBM Impact Session 2351 hybrid apps
IBM Impact Session 2351 hybrid apps
 
Office Add ins community call-February 2019
Office Add ins community call-February 2019Office Add ins community call-February 2019
Office Add ins community call-February 2019
 
Guide to Vite JS – Modern Fron-End Development Tool
Guide to Vite JS – Modern Fron-End Development ToolGuide to Vite JS – Modern Fron-End Development Tool
Guide to Vite JS – Modern Fron-End Development Tool
 
ArcReady - Scalable And Usable Web Applications
ArcReady - Scalable And Usable Web ApplicationsArcReady - Scalable And Usable Web Applications
ArcReady - Scalable And Usable Web Applications
 
Service Oriented UI Architecture in the world of web, desktop, & mobile appli...
Service Oriented UI Architecture in the world of web, desktop, & mobile appli...Service Oriented UI Architecture in the world of web, desktop, & mobile appli...
Service Oriented UI Architecture in the world of web, desktop, & mobile appli...
 
SD Forum Java SIG - Service Oriented UI Architecture
SD Forum Java SIG - Service Oriented UI ArchitectureSD Forum Java SIG - Service Oriented UI Architecture
SD Forum Java SIG - Service Oriented UI Architecture
 
OWIN (Open Web Interface for .NET)
OWIN (Open Web Interface for .NET)OWIN (Open Web Interface for .NET)
OWIN (Open Web Interface for .NET)
 
Startups without Servers
Startups without ServersStartups without Servers
Startups without Servers
 
Final ppt
Final pptFinal ppt
Final ppt
 
Mobile Commerce ppt....... Provides a website interface to the customers to b...
Mobile Commerce ppt....... Provides a website interface to the customers to b...Mobile Commerce ppt....... Provides a website interface to the customers to b...
Mobile Commerce ppt....... Provides a website interface to the customers to b...
 
Best practices for upgrading vb 6.0 projects to vb.net
Best practices for upgrading vb 6.0 projects to vb.netBest practices for upgrading vb 6.0 projects to vb.net
Best practices for upgrading vb 6.0 projects to vb.net
 
The Power of IBM API Management. API connect 2016 Vegas
The Power of IBM API Management. API connect 2016 VegasThe Power of IBM API Management. API connect 2016 Vegas
The Power of IBM API Management. API connect 2016 Vegas
 
Building CI/CD Pipelines for Serverless Applications
Building CI/CD Pipelines for Serverless ApplicationsBuilding CI/CD Pipelines for Serverless Applications
Building CI/CD Pipelines for Serverless Applications
 
Microsoft Tech Ed 2006 #2
Microsoft Tech Ed 2006 #2Microsoft Tech Ed 2006 #2
Microsoft Tech Ed 2006 #2
 
How DotNet, SharePoint, and Azure helps to build a Custom Web Application wi...
 How DotNet, SharePoint, and Azure helps to build a Custom Web Application wi... How DotNet, SharePoint, and Azure helps to build a Custom Web Application wi...
How DotNet, SharePoint, and Azure helps to build a Custom Web Application wi...
 
HAM 1032 Combining the Power of IBM API Management and IBM Integration Bus
HAM 1032 Combining the Power of IBM API Management and IBM Integration BusHAM 1032 Combining the Power of IBM API Management and IBM Integration Bus
HAM 1032 Combining the Power of IBM API Management and IBM Integration Bus
 
Development of skype for business and knowledge of
Development of skype for business and knowledge ofDevelopment of skype for business and knowledge of
Development of skype for business and knowledge of
 

Mehr von Brian Ritchie

Transforming your application with Elasticsearch
Transforming your application with ElasticsearchTransforming your application with Elasticsearch
Transforming your application with ElasticsearchBrian Ritchie
 
Building Event-Driven Systems with Apache Kafka
Building Event-Driven Systems with Apache KafkaBuilding Event-Driven Systems with Apache Kafka
Building Event-Driven Systems with Apache KafkaBrian Ritchie
 
From Dev to Ops:Delivering an API to Production with Splunk
From Dev to Ops:Delivering an API to Production with SplunkFrom Dev to Ops:Delivering an API to Production with Splunk
From Dev to Ops:Delivering an API to Production with SplunkBrian Ritchie
 
Extending the Enterprise with MEF
Extending the Enterprise with MEFExtending the Enterprise with MEF
Extending the Enterprise with MEFBrian Ritchie
 
CQRS: Command/Query Responsibility Segregation
CQRS: Command/Query Responsibility SegregationCQRS: Command/Query Responsibility Segregation
CQRS: Command/Query Responsibility SegregationBrian Ritchie
 
Document Databases & RavenDB
Document Databases & RavenDBDocument Databases & RavenDB
Document Databases & RavenDBBrian Ritchie
 

Mehr von Brian Ritchie (6)

Transforming your application with Elasticsearch
Transforming your application with ElasticsearchTransforming your application with Elasticsearch
Transforming your application with Elasticsearch
 
Building Event-Driven Systems with Apache Kafka
Building Event-Driven Systems with Apache KafkaBuilding Event-Driven Systems with Apache Kafka
Building Event-Driven Systems with Apache Kafka
 
From Dev to Ops:Delivering an API to Production with Splunk
From Dev to Ops:Delivering an API to Production with SplunkFrom Dev to Ops:Delivering an API to Production with Splunk
From Dev to Ops:Delivering an API to Production with Splunk
 
Extending the Enterprise with MEF
Extending the Enterprise with MEFExtending the Enterprise with MEF
Extending the Enterprise with MEF
 
CQRS: Command/Query Responsibility Segregation
CQRS: Command/Query Responsibility SegregationCQRS: Command/Query Responsibility Segregation
CQRS: Command/Query Responsibility Segregation
 
Document Databases & RavenDB
Document Databases & RavenDBDocument Databases & RavenDB
Document Databases & RavenDB
 

KĂŒrzlich hochgeladen

Advantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessAdvantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessPixlogix Infotech
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Servicegiselly40
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsJoaquim Jorge
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)Gabriella Davis
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...apidays
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024The Digital Insurer
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024Results
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘RTylerCroy
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...Neo4j
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxMalak Abu Hammad
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUK Journal
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking MenDelhi Call girls
 
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxKatpro Technologies
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024Rafal Los
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Igalia
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationRadu Cotescu
 

KĂŒrzlich hochgeladen (20)

Advantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessAdvantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your Business
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 

IIS Always-On Services

  • 1. Hosting Windows Services in IIS Take advantage of the IIS platform for hosting your Always-On services. Brian Ritchie Chief ArchitectPayformance Corporation Email: brian.ritchie@gmail.com Blog: http://weblog.asp.net/britchie Web: http://www.dotnetpowered.com
  • 2. Who am I? Brian Ritchie Chief Architect at Payformance Corporation Nearly 20 years of development experience Developing on .NET since 1.0 Beta 1 Contributed to Mono and other open source projects
  • 3. Why build Windows Services? When you need always-on functionality Examples: File Watching & Processing Scheduled tasks Long-running tasks Queued processing
  • 4. Why build Windows Services? Windows Services have been around forever, why change now?
  • 6. Reasons for change Windows Services have no User Interface making them hard to monitor, manage, and debug. Windows Services are harder to deploy & can’t use Web Deploy.
  • 7. Who can save us from these problems? I’m IIS & I’m here to help!
  • 8. Did you say IIS? More than just a web server, IIS is an application server platform. Web Applications: ASP.NET, PHP, and more Web Services: ASMX, WCF Multiple Protocols: HTTP, HTTPS, TCP, Named Pipes And now
 Always-On Services: Auto-start & Always Running
  • 9. What makes IIS better?
  • 10. IIS7: Your Single Hosting Framework
  • 11. Monitoring via the IIS Manager Since all services will be hosted under the w3wp.exe process name, you can see the Worker Process associated with your application pool within the IIS manager:
  • 12. Monitoring via Process Explorer Another approach is to use the SysInternals Process Explorer free from Microsoft.  Add the “Command Line” column to the grid, and the application pool name will be listed after the –ap switch.
  • 13. Deployments
made easy Web Deploy 2.1 Deploy Package Build/Deploy Server Build Server (using MSBuild) Deployment Package IIS Server IIS MMC – Export Application IIS MMC – Import Application
  • 14. Look Mom
I have a UI now! No longer “invisible”, your service can publish its own monitoring & management capability
  • 15. OK
I’m sold! How can I take this beauty home today?
  • 16. Getting Started First off
Install the pre-reqs: IIS 7.5 (Windows 2008 R2 or Windows 7) Windows Server AppFabric .NET Framework 4.0 Next
Configure IIS: Set Application Pool to “Always Running” Configure Site with Net.Pipe Binding Set Application to “Auto Start”
  • 19. Building a service What are some fundamental differences between a standard Web Service and a Windows Service? Request-Response vs. Event-based State-less vs. State-full Transparent threading vs. Thread Management DLL vs. EXE All of the Above
  • 20. Building a Service:Differences in Process Models Windows Service Process Model Service Controller Service (EXE) MMC
  • 21. Building a Service:Differences in Process Models Windows Service Process Model IIS Worker Process Model Service Controller Service (EXE) MMC W3WP WWW Publishing Service svchost.exe -k iissvcs AppDomain Service (DLL) IIS Manager AppDomain
  • 22. Building a service Where does the service perform it’s startup? Application_Startin Global.asax AppInitialize in AppStart.cs AppStartup in the session controller
  • 23. Building a service What is the scope of a static variables? Class Thread AppDomain Process Machine
  • 24. Visualizing the stack Machine Process AppDomain Your service runs here Thread Thread Static Scope Either you manage threads directly or use a Thread Pool or TPL
  • 25. Walk Thru: Building a service
  • 26. Twitter: @brian_ritchie Blog: http://weblogs.asp.net/britchie Thanks for coming!