Migrating SaaS Applications to Windows Azure Lessons Learned 04.04.2012
Speaker Introduction Deepthi Raju Marketing Technology Services Deepthi joined Smartbridge in 2005 and has over twenty years of technology consulting experience in energy and retail industries. Deepthi currently leads the product development of SmartMPM which is a state-of-theart marketing performance measurement tool used by marketers across variety of industries. Deepthi recently led the migration of Smartbridge products from private cloud to public hosted cloud environments and is an expert in technology architectures developed for cloud applications. Prior to Smartbridge, Deepthi was an architect and senior developer at Schlumberger responsible for the development of drilling log analysis technologies. 2
What we are here to talk about? 3
Outline 1. What are the market trends? 2. Cloud characteristics and options 3. SmartMPM, a SaaS Case Study 4. Azure Component breakdown 5. Key Challenges 6. Architectural Best Practices 7. Cost Considerations 4
What are the market trends? Majority of large enterprises consider speed and agility to be the primary benefit of cloud. We ll see about a 10x increase in private cloud deployments in 2012 - Gartner business groups are adopting cloud 2.5 times faster than IT groups. Forrester 5
What are your options? You manage (On-Premises) IaaS PaaS SaaS Applications Data Runtime Middleware O/S Virtualization Servers Storage Networking You manage Applications Data Runtime Middleware O/S Virtualization Servers Storage Networking You manage Managed by vendor Applications Data Runtime Middleware O/S Virtualization Servers Storage Networking Managed by vendor Applications Data Runtime Middleware O/S Virtualization Servers Storage Networking Managed by vendor 6
Benefits of SaaS Applications on the cloud Faster customer acquisition Higher availability; greater scalability Enables companies to focus on core product features Opens new markets Lower cost of ownership Ease of administering multi-tenancy Lower cost of maintenance and deployment 7
SmartMPM a SaaS solution for marketers Radio Web Web email TV email Mobile Facebook Search Engine Radio Paid Search Print Mobile TV YouTube Search Engine Facebook Print Twitter Paid Search YouTube Twitter Manual Extraction & Compilation Excel is the consolidation solution Continuously changing data ROI? Not sure where to start Convenience Accuracy Customization Better executive decisions based on ROI 8
SmartMPM our SaaS Marketing Solution 9
SmartMPM Requirements 1. Support multi-tenancy. 2. Scale efficiently. 3. Have functions in place to monitor, configure, and manage the application and tenants. 4. Support unique user identification and authentication. 5. Support some level of customization for each tenant. 10
Components of Windows Azure Cloud Applications Data Management Web/Worker Roles SQL Azure Tables Blobs Business Analytics SQL Azure Reporting (in CTP) Networking Traffic Manager Connect Service Bus In-Memory Messaging Caching Queues CDN SDKs.NET Java PHP Node.js HPC HPC Scheduler Identity Windows Azure Active Directory Commerce Marketplace 11
SmartMPM Pre-Azure Architecture (On-Premise) On-Premise Load Balancer Third Party Data Providers Internet Web servers Mirrored Database Servers File Storage 12
SmartMPM Architecture on Azure Third Party Data Providers Background processes Worker Role Instances Logs Table Storage Windows Azure Diagnostics SQL Azure Binary Files Blob Storage Web application on Web Role Instances Session State Windows Azure Cache Third Party Data Providers 13
SmartMPM Migration Process Migration Platform Selection Proto Type Phase 1 Execute (Agile Approach) Phase 2 Phase 3 Monitor Establish Driving Factors for Cloud Migration Establish Cloud Center of Excellence Setup Windows Azure Account, Subscriptions & Users Identify technical risks & define diagnostics strategy Design Worker Roles for background processes Capacity Utilization Decide Cloud Type (Public, Private, Hybrid) Setup Windows Azure dev environment. Setup Dev, QA & Production environments on Azure Research & Design Azure solution Develop Worker Roles Performance Evaluate Platform Options and finalize platform Develop, Deploy & Test Prototype on Trial Subscription Migrate database to SQL Azure Rewrite the application components Test & Rollout Usage Cost Plan Migration Phases Test & Rollout Test & Rollout Take on-premise Infrastructure down Deployment Model On-Premise Hybrid Hybrid Public Cloud Public Cloud 14
Challenges SQL Azure 1. Connectivity Issues Provides a large-scale multi-tenant database service on shared resources Connections may close or may not be available when requested Retry logic around every connection request is needed Transactions should be coded to self-recover 2. Migration Process No support for RESTORE and BACKUP Use SSIS or bulk copy utility/migration wizard/red Gate SQL Azure Backup 3. Clustered Index Is a requirement SELECT INTO is not supported 4. Size Limitation Web Edition 5GB Business Edition 150 GB 5. Security Data Encryption methods not supported. Uses SSL for data transfers Authentication only supports database logins not network logins 15
Challenges Application Development 1. Lack of Session Affinity In-Proc sessions do not work 2. Persistent Storage on Server Storage on local web server is absolute No 3. Integration with on-premise systems Legacy APIs and Interfaces between systems may not work. Take advantage of Connect, Service Bus & Queues. 4. Latency Choose appropriate data center Cache as much as possible 5. Debugging & Troubleshooting Traditional logging utilities may not work. Take advantage of windows Azure Diagnostics. 16
Deployment Considerations 1. Deployment During development Redeploying whole package can be time consuming Use Web deploy for upgrading a single role instance Production Redeploying whole package is the only option 2. Choose a deployment option that matches your need Small Teams - Publish from Visual Studio IDE directly to Azure Mid Sized Teams - Generate Package and upload from Management portal Large Teams - Build scripts to auto deploy package to Azure using PowerShell scripts 17
Architectural best practices Scale out, not up 1. No local state or affinity 2. Minimize dependencies Single big box Multiple small boxes Avoid Synchronicity 1. Minimize dependency 2. Loosely couple process from process-trigger 3. Queue the work 18
Architectural best practices Cache Cache everything you can: 1. Windows Azure Cache 2. Table Storage 3. SQL Azure 4. Content Distribution Network Monitor Health & Performance Use Azure diagnostics API to collect 1. Event Logs 2. Performance Counters 3. Trace/Debug Information (Logs) 4. IIS Logs, Failed Request Logs 19
Architectural best practices Scale data tier 1. Prevent data tier bottleneck 2. Put compute and storage in the same data center 3. Build an informed data partitioning strategy using SQL federations Security 1. Consider all cases where data can flow over insecure links. 2. Take steps to protect data HTTPS Message-level signing/encryption VPN Options (e.g. Windows Azure Connect) 20
Architectural considerations impacting cost 1. Purchasing models Consumption pay as you go Subscription value for commitment Additional Licensing coordinated purchasing (volume discounts) 2. Basis for Consumption Prices Compute - instance size & hours of utilization Storage - size and transactions Bandwidth amount of data transferred Distributed Cache Service size Messaging (Queues, Service Bus) - number of messages 3. Predicting Cost Convert to units that make sense for your service user, feature, business transaction Simulate variable costs on top of the fixed cost Use the pricing calculator for rough estimate 21
Architectural considerations impacting cost 4. Factoring Cost into architecture decisions Data Storage: SQL Azure or Azure Storage or Blob? Session State: Azure Cache, SQL Azure or Azure Storage? Integration: App Fabric Service Bus or Azure Connect? 5. Optimize Cost Measure everything and anything Improve performance because better performance = lower cost Whenever possible use cache and compress content Use different storage accounts for application data and diagnostics data Pick the correct VM size (1 VM is not equal to 1 task) Bandwidth reduction aggregate, protocol KEEP IN MIND YOU ARE CHARGED EVEN IF YOU ARE NOT USING SO DELETE WHAT YOU ARE NOT USING. 22
Smartbridge Services Helping clients find the right answer Strategy, Assessment & Planning Solution Architecture Program & Project Management Implementation Quality Assurance Agile Methodology Enterprise Systems Enterprise Information Management Emerging Technologies Global Delivery IT Strategy ERP JD Edwards Retail POS/BOS Systems Restaurant Technology Information Portals Application Development Business Intelligence & Analytics Cloud Services Performance Management Enterprise Mobility Enterprise Integration Mobile Applications Data Governance Marketing Performance & Master Data Management Analytics Simulations & Forecasting Optimization 23
Smartbridge Cloud Advisory Services Leveraging our Hands On Experience with the cloud Current state Assessment Assessment & Strategy Future computing environment needs assessment Opportunities to leverage the cloud Risks and mitigation strategies Implementation roadmap Establish cloud infrastructure Servers and Storage Commodity App Migration Mail Migration to Office365 Sharepoint Security and Malware Low criticality app migration Architecture development for complex applications Application Development / Migration Development / migration to Cloud architecture Integration into the enterprise Deployment on the cloud 24
Smartbridge Houston Office sbinfo@smartbridge.com 713-360-2500 Deepthi Raju Director, Marketing Technology Services draju@smartbridge.com 713.501.3415 Jon Shale Director, Enterprise Mobility & Cloud Technologies jshale@smartbridge.com 713.516.3098
Sample Hybrid Enterprise Web Application Web Browser Enterprise Application ASP.NET ASP.NET (Web (Web Role) Role) ASP.NET (Web Role) Web Svc (Web Role) Web Svc (Web Role) Jobs Web Svc (Worker (Web Role) Enterprise Web Svc Table Storage Service Blob Storage Service Queue Service Third Party SaaS App Service Enterprise Data Enterprise Identity User Data Application Data Reference Data Service Bus Access Control Service Private Cloud Public Cloud 26