微服務負載均衡實現高可用
Written by Yona Gidalevitz
由Yona Gidalevitz撰寫
Most users of the web are blissfully unaware of the sheer scale of the process responsible for bringing content across the Internet. There are literally miles of Internet between you and the server you’re accessing.
Web的大多數用戶都非常不了解負責通過Internet傳遞內容的過程的規模 。 您和您要訪問的服務器之間實際上有數英里的Internet。
To make things worse, sites that become extremely popular have to deal with consistent increases in monthly traffic, which can slow down the experience for everyone involved. Some sites can draw more visits in a month than comparable sites do in a year.
更糟的是,非常受歡迎的網站必須應對每月流量的持續增長,這可能會減慢每個參與人員的體驗。 與同類網站一年相比,某些網站在一個月內可以吸引更多訪問。
Sites which bring in high-volume traffic may inadvertently be faced with frequent server upgrades, so that page speed and, in turn, usability, doesn’t suffer for their loyal customers.
帶來大量流量的站點可能會無意間面臨頻繁的服務器升級,因此頁面速度以及相應的可用性不會因其忠實的客戶而受到影響。
Often, however, simple hardware upgrades aren’t enough to handle the vast traffic that some sites draw.
但是,通常,簡單的硬件升級不足以處理某些站點吸引的大量流量。
So, the question that business owners, their UX designers, and their developers ought to be asking themselves is not only how to keep day-to-day speed at a level which doesn’t impact usability, but also how to prepare for the kind of traffic your site may experience down the road.
因此,企業所有者,他們的UX設計師和他們的開發人員應該問自己的問題不僅是如何將日常速度保持在不影響可用性的水平上,還包括如何為這種速度做準備您的網站可能會遇到的流量。
通過負載平衡為最壞的情況做好準備 (Prepare for the Worst with Load Balancing)
So how do you ensure that your site won’t burst into figurative flames as page visits skyrocket? Consider employing a technique called load balancing.
那么,如何確保您的網站不會因為頁面訪問量的激增而大打折扣呢? 考慮采用一種稱為負載平衡的技術。
Load balancing distributes server loads across multiple resources — most often across multiple servers. The technique aims to reduce response time, increase throughput, and in general speed things up for each end user.
負載平衡可將服務器負載分布在多個資源上-最常見的是分布在多個服務器上。 該技術旨在減少響應時間,增加吞吐量,并總體上加快每個最終用戶的工作速度。
Loads are broken up based on a set of predefined metrics, such as by geographical location, or by number of concurrent site visitors.
根據一組預定義的指標(例如,地理位置或并發站點訪問者的數量)分解負載。
Members of a certain group — such as ‘people living in Europe’, for example may be directed to a server within Europe, while members of another group take, for instance, ‘North Americans’ may be directed to another server, closer to them.
某個組的成員(例如“居住在歐洲的人”)可以被定向到歐洲內的一臺服務器,而另一組的成員例如可以將“北美人”定向到與其更近的另一臺服務器。
我的網站真的需要負載平衡嗎? (Does My Site Really Need Load Balancing?)
Load balancing is a powerful technique, and while most sites will benefit from it, the cost of implementing and maintaining the additional server(s) may not be worth the increase in performance, unless your monthly visits average at least in the ballpark of a few hundred thousand. Some industry experts will even tell you that load balancing will not be worthwhile until your monthly page views average a few million.
負載平衡是一項強大的技術,盡管大多數站點都將從中受益,但除非您每月的訪問量至少平均達到幾個,否則實現和維護額外服務器的成本可能不值得提高性能。 十萬 。 一些行業專家甚至會告訴您,只有當您的平均每月頁面瀏覽量達到數百萬次時,負載平衡才有意義。
One thing is for sure — before you start investing in parallel hardware, you ought to take a good look at not only your average traffic, but also your forecasted traffic.
可以肯定的一件事-在開始投資并行硬件之前,您不僅應該仔細研究平均流量,還應該仔細研究預測流量 。
Servers running popular sites can be bogged down by an overabundance of requests. Business owners whose sites cater to a niche audience of avid internet users may find that they simply cannot keep up with the traffic that internet fandom can generate.
運行過多站點的服務器可能會因請求過多而陷入癱瘓。 其站點迎合了狂熱的互聯網用戶的小眾受眾的企業主可能會發現,他們根本無法跟上互聯網擁護者可能產生的流量。
Sites that cater to the committed Apple user, for example, consistently serve millions of requests every month, and typically require some serious hardware. But this is only part of the story.
例如,迎合Apple忠實用戶的網站每月都會持續處理數百萬個請求,并且通常需要一些嚴重的硬件。 但這只是故事的一部分。
Sites like Macworld and 9to5Mac tend to see massive swells in traffic whenever Apple executives give keynote speeches, for example.
例如,每當Apple高管發表主旨演講時, Macworld和9to5Mac之類的網站就會看到大量的流量增長。
Apple product launches, keynote speeches, and press events generate incomparable amounts of internet buzz. Often, such events can lead to drastic surges in traffic among relevant sites. If you aren’t prepared for the swells in traffic, your servers might be left gasping for air.
蘋果產品發布會,主題演講和新聞發布會產生無與倫比的互聯網嗡嗡聲。 通常,此類事件可能導致相關站點之間的流量激增。 如果您不為流量激增做好準備,則服務器可能會喘不過氣來。
Whenever major events trigger sudden increases in traffic, there is a chance that your server won’t keep up. If you find yourself encountering more traffic than you are used to, your servers might get reduced to a crawl, with significantly reduced speeds for the users of your site.
每當重大事件觸發流量突然增加時,您的服務器就有可能無法跟上。 如果發現自己遇到的流量比以前更多,則服務器可能會被簡化為爬網,從而大大降低了站點用戶的速度。
UX designers know that quick page loads are an important aspect of the user experience, and that the user experience, in turn, is one of two things bringing your users back (the other being good content).
UX設計人員知道快速頁面加載是用戶體驗的重要方面,而用戶體驗又是使用戶返回的兩件事之一(另一件事是很好的內容)。
Ultimately, the danger that unbalanced, high volume sites are faced with is one of survival: users have options. There may be dozens of other sites that cater to the same audience and that can handle the traffic. Your users will not hesitate to take their page views elsewhere.
歸根結底,不平衡,高容量站點所面臨的危險是生存之道: 用戶可以選擇 。 可能還有許多其他網站可以滿足相同的受眾需求,并且可以處理流量。 您的用戶會毫不猶豫地將其頁面瀏覽量移至其他位置。

As a UX designer, it is important that you test your site (often) to make sure that it is loading quickly. A great website for testing the speed of a live site is Load Impact. Simply enter the URL of your site, and watch as Load Impact conducts its tests live, showing you real-time results.
作為用戶體驗設計師,重要的是(經常) 測試站點以確保其快速加載。 一個用于測試實時網站速度的出色網站是Load Impact 。 只需輸入您的站點的URL,然后觀察Load Impact實時進行的測試,并向您顯示實時結果。
我該怎么做? (How do I do it?)
Assuming you have the financial resources to do it, your business is faced with two options when it comes to load balancing: build it yourself, or pay someone else to do it.
假設您有足夠的資金來做到這一點,那么在進行負載平衡時,您的企業將面臨兩種選擇:自己構建,或付錢給其他人做。
Should you choose to undertake the task of load balancing your site, you will be faced with a very technical (and costly) task. There will be a number of tasks that will require both knowledge of server hardware, and software expertise.
如果您選擇承擔負載平衡站點的任務,那么您將面臨一項技術性(且成本高昂)的任務。 將有許多任務需要服務器硬件知識和軟件專業知識。
You will have to set up multiple servers, each of which may be running a different custom software stack, and you will likely need to hire some server maintenance and scalability staff.
您將必須設置多個服務器,每個服務器可能運行不同的自定義軟件堆棧,并且可能需要雇用一些服務器維護和可伸縮性人員。
For companies with technical staff on hand, this can often be the best approach. For larger, non-technical companies, however, the best choice can often be to partner with an agency that specializes in server set-up and maintenance.
對于擁有技術人員的公司,這通常是最好的方法。 但是,對于較大的非技術性公司,最好的選擇通常是與專門從事服務器設置和維護的機構合作。
想了解更多? (Want to learn more?)
Are you interested in the managerial and strategic aspects of UX? The online course on UX Management and Strategy can teach you the necessary skills on the subject and earn you an industry-recognized course certificate to advance your career. If, on the other hand, you want to brush up on the basics of UX and Usability, the online course on User Experience might be a better fit for you (or another design topic). Good luck on your learning journey!
您對UX的管理和戰略方面感興趣嗎? 在線用戶體驗管理和策略課程可以教會您有關該主題的必要技能,并為您贏得行業認可的課程證書,以促進您的職業發展。 另一方面,如果您想了解UX和可用性的基礎知識,則有關用戶體驗的在線課程可能更適合您(或其他設計主題 )。 祝您學習愉快!
(Lead image: Depositphotos)
(領導形象: Depositphotos )
Originally published at UsabilityGeek by Yona Gidalevitz. He is Codal’s technical writer. At Codal, he is responsible for content strategy, documentation, blogging, and editing. He works closely with Codal’s UX, development, marketing, and administrative teams to produce all manner of written content.
最初由Yona Gidalevitz發表在UsabilityGeek上 。 他是Codal的技術作家。 在Codal ,他負責內容策略,文檔,博客和編輯。 他與Codal的UX,開發,營銷和管理團隊緊密合作,以編寫各種形式的書面內容。
翻譯自: https://medium.com/usabilitygeek/using-load-balancing-for-large-volume-usability-fa9a201bd7a5
微服務負載均衡實現高可用
本文來自互聯網用戶投稿,該文觀點僅代表作者本人,不代表本站立場。本站僅提供信息存儲空間服務,不擁有所有權,不承擔相關法律責任。 如若轉載,請注明出處:http://www.pswp.cn/news/274811.shtml 繁體地址,請注明出處:http://hk.pswp.cn/news/274811.shtml 英文地址,請注明出處:http://en.pswp.cn/news/274811.shtml
如若內容造成侵權/違法違規/事實不符,請聯系多彩編程網進行投訴反饋email:809451989@qq.com,一經查實,立即刪除!