mc714 sistemas distribu dos
play

MC714: Sistemas Distribu dos Prof. Lucas Wanner Instituto de - PowerPoint PPT Presentation

MC714: Sistemas Distribu dos Prof. Lucas Wanner Instituto de Computac ao, Unicamp Aula 27: Sistemas Web Distribu dos Distributed Web-based systems Essence The WWW is a huge client-server system with millions of servers; each


  1. MC714: Sistemas Distribu´ ıdos Prof. Lucas Wanner Instituto de Computac ¸ ˜ ao, Unicamp Aula 27: Sistemas Web Distribu´ ıdos

  2. Distributed Web-based systems Essence The WWW is a huge client-server system with millions of servers; each server hosting thousands of hyperlinked documents. Documents are often represented in text (plain text, HTML, XML) Alternative types: images, audio, video, applications (PDF, PS) Documents may contain scripts, executed by client-side software 2. Server fetches Client machine Server machine document from local file Browser Web server OS 3. Response 1. Get document request (HTTP) Source: Maarten van Steen, Distributed Systems: Principles and Paradigms 2 / 13

  3. Multi-tiered architectures Observation Already very soon, Web sites were organized into three tiers. 3. Start process to fetch document 1. Get request 4. Database interaction HTTP� CGI� request� program handler 6. Return result 5. HTML document� created Web server CGI process Database server Source: Maarten van Steen, Distributed Systems: Principles and Paradigms 3 / 13

  4. Web services Observation At a certain point, people started recognizing that it is was more than just user ↔ site interaction: sites could offer services to other sites ⇒ standardization is then badly needed. Client machine Server machine Look up� a service Client� Server� Publish service application application Stub Stub SOAP Communication� Communication� subsystem subsystem Generate stub� Generate stub� from WSDL� from WSDL� description description Service description (WSDL) Service description (WSDL) Service description (WSDL) Directory service (UDDI) Source: Maarten van Steen, Distributed Systems: Principles and Paradigms 4 / 13

  5. Clients: Web browsers Observation Browsers form the Web’s most important client-side sofware. They used to be simple, but that was long ago. Display back end User interface Browser engine Rendering engine Client-side� Network� HTML/XML� script� interpreter comm. parser Source: Maarten van Steen, Distributed Systems: Principles and Paradigms 5 / 13

  6. Apache Web server Observation: More than 46% of all ∼ 170 million active Web sites are Apache. Module Module Module Function ... ... ... Link between� function and hook Hook Hook Hook Hook Apache core Functions called per hook Request Response Source: Maarten van Steen, Distributed Systems: Principles and Paradigms 6 / 13

  7. Server clusters Essence To improve performance and availability, WWW servers are often clustered in a way that is transparent to clients. Web Web Web Web server server server server LAN Front end handles Front all incoming requests end and outgoing responses Request Response Source: Maarten van Steen, Distributed Systems: Principles and Paradigms 7 / 13

  8. Server clusters Problem The front end may easily get overloaded, so that special measures need to be taken. Transport-layer switching: Front end simply passes the TCP request to one of the servers, taking some performance metric into account. Content-aware distribution: Front end reads the content of the HTTP request and then selects the best server. Source: Maarten van Steen, Distributed Systems: Principles and Paradigms 8 / 13

  9. Server Clusters 6. Server responses Web 5. Forward server 3. Hand of other f TCP connection messages Distributor Other messages Dis- Client Switch 4. Inform patcher switch Setup request 1. Pass setup request Distributor 2. Dispatcher selects to a distributor server Web server Source: Maarten van Steen, Distributed Systems: Principles and Paradigms 9 / 13

  10. Web proxy caching Basic idea (cnt’d) Cooperative caching, by which you first check your neighbors on a cache miss Web server 3. Forward request to Web server 1. Look in local cache Web 2. Ask neighboring proxy caches Web proxy proxy Cache Cache Client Client Client Client Client Client Web proxy HTTP Get request Cache Client Client Client Source: Maarten van Steen, Distributed Systems: Principles and Paradigms 10 / 13

  11. Replication in Web hosting systems Observation By-and-large, Web hosting systems are adopting replication to increase performance. Much research is done to improve their organization. Follows the lines of self-managing systems. Uncontrollable parameters (disturbance / noise) Initial configuration Corrections Observed output Web hosting system +/- +/- +/- Reference input Replica� Consistency� Request� Metric� placement enforcement routing estimation Analysis Measured output Adjustment triggers Source: Maarten van Steen, Distributed Systems: Principles and Paradigms 11 / 13

  12. Handling flash crowds Observation We need dynamic adjustment to balance resource usage. Flash crowds introduce a serious problem. 2 days 2 days (b) (a) 6 days 2.5 days (c) (d) Source: Maarten van Steen, Distributed Systems: Principles and Paradigms 12 / 13

  13. Server replication Content Delivery Network CDNs act as Web hosting services to replicate documents across the Internet providing their customers guarantees on high availability and performance (example: Akamai). 6. Get embedded documents� (if not already cached) CDN� Cache server 5. Get embedded� documents Return IP address� 7. Embedded documents client-best server 1. Get base document CDN DNS� Origin� 4 Client server server 2. Document with refs� to embedded documents 3 DNS lookups Regular� DNS system Source: Maarten van Steen, Distributed Systems: Principles and Paradigms 13 / 13

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend