TWI735228B - Web server load balancing method - Google Patents

Web server load balancing method Download PDF

Info

Publication number
TWI735228B
TWI735228B TW109116008A TW109116008A TWI735228B TW I735228 B TWI735228 B TW I735228B TW 109116008 A TW109116008 A TW 109116008A TW 109116008 A TW109116008 A TW 109116008A TW I735228 B TWI735228 B TW I735228B
Authority
TW
Taiwan
Prior art keywords
work
load balancing
static
dynamic
tasks
Prior art date
Application number
TW109116008A
Other languages
Chinese (zh)
Other versions
TW202143687A (en
Inventor
謝哲人
李其融
朱玉峰
Original Assignee
遠東科技大學
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 遠東科技大學 filed Critical 遠東科技大學
Priority to TW109116008A priority Critical patent/TWI735228B/en
Application granted granted Critical
Publication of TWI735228B publication Critical patent/TWI735228B/en
Publication of TW202143687A publication Critical patent/TW202143687A/en

Links

Images

Abstract

A web server load balancing method is disclosed. The method comprises: classifying multiple work into static work or dynamic work and entering into the dynamic work queue or static work queue by using a web interface processor; performing the weight calculation procedure according to the work group of the work and the time in the dynamic work queue or static work queue by using the load balancing algorithm to obtain multiple weighted demands; and assigning the work to the multiple workstations based on the weighted demands of the work and the information of the multiple workstations by using the distributor.

Description

網頁伺服器負載平衡方法 Web server load balancing method

本發明是有關於一種平衡方法,特別是有關於一種網頁伺服器負載平衡方法。 The present invention relates to a balancing method, in particular to a load balancing method of a web server.

隨著網際網路技術與雲端運算技術快速發展,雲端運算服務具備可靠性高、建置成本低、擴展性佳等優勢,企業可隨時利用雲端環境快速部署虛擬機器以提供各式應用服務如Web檔案傳輸、影音隨選視訊、影音串流等,解決了傳統自主建置系統設備可能導致使用率不佳與設備維護之問題。雖然雲端運算服務帶來許多好處,對企業而言,如何有效率地依其用戶數量調整雲端系統服務規模以維持良好的服務品質,是一項重要的議題。 With the rapid development of Internet technology and cloud computing technology, cloud computing services have the advantages of high reliability, low construction cost, and good scalability. Enterprises can use the cloud environment to quickly deploy virtual machines at any time to provide various application services such as Web File transmission, video on-demand video, video streaming, etc., solve the problems of poor utilization and equipment maintenance that traditional self-built system equipment may cause. Although cloud computing services bring many benefits, how to efficiently adjust the scale of cloud system services according to the number of users to maintain good service quality is an important issue for enterprises.

有鑑於上述習知技藝之問題,本發明之一目的就是在提供一種網頁伺服器負載平衡方法,以解決習知技術的問題。 In view of the above-mentioned problems of the prior art, one purpose of the present invention is to provide a load balancing method for a web server to solve the problems of the prior art.

為達前述目的,本發明提出一種網頁伺服器負載平衡方法,包含:以網頁介面處理器將複數個工作區分成靜態工作或動態工作,並進入動態工作佇列或靜態工作佇列;以負載平衡演算法依據該些工作所屬之工作類群及 在該些動態工作佇列及該些靜態工作佇列中的時間進行權重演算,藉以獲得該些工作之複數個加權需求;以及以分配器依據該些工作之該些加權需求及複數個工作站資訊指派該些工作給複數個工作站。 To achieve the foregoing objective, the present invention proposes a load balancing method for a web server, which includes: using a web interface processor to divide a plurality of tasks into static tasks or dynamic tasks, and enter a dynamic task queue or a static task queue; and load balancing The algorithm is based on the work group to which the work belongs and Perform weighting calculations on the time in the dynamic work queues and the static work queues to obtain the weighted requirements of the tasks; and use the allocator to calculate the weighted requirements of the tasks and the information of the plurality of workstations Assign these tasks to multiple workstations.

其中該些工作站資訊係包含該些工作站之複數個狀態資訊。 The workstation information includes a plurality of status information of the workstations.

其中該些狀態資訊係該些工作站處於忙碌狀態或閒置狀態。 The status information is that the workstations are in a busy state or an idle state.

其中該分配器係先接收該些動態工作佇列及該些靜態工作佇列中的該些工作之需求,再以該負載平衡演算法依據該些工作所屬之工作類群及在該些動態工作佇列及該些靜態工作佇列中的時間進行權重演算,藉以獲得該些工作之該些加權需求。 The allocator first receives the needs of the jobs in the dynamic work queues and the static work queues, and then uses the load balancing algorithm according to the work group to which the jobs belong and in the dynamic work queues. Perform weight calculation on the time in the static work queue and the static work queue to obtain the weighted requirements of the work.

其中該些工作於該些動態工作佇列的權重高於該些靜態工作佇列中的權重。(該些工作於該些靜態工作佇列的權重高於該些動態工作佇列中的權重) The weights of the jobs in the dynamic job queues are higher than the weights in the static job queues. (The weights of the jobs in the static work queues are higher than the weights in the dynamic work queues)

其中該些工作在該些動態工作佇列及該些靜態工作佇列中的時間越長則權重越大。 The longer the time of the jobs in the dynamic job queues and the static job queues, the greater the weight.

其中複數個使用者係對一網站進行瀏覽或查詢,藉以產生該些工作之需求給該網頁介面處理器。 Among them, a plurality of users browse or query a website, so as to generate the needs of the tasks to the web interface processor.

其中該靜態工作為瀏覽或查詢無後臺資料庫、無程式和無交互性的網頁。 Among them, the static work is browsing or querying web pages without a back-end database, without programs, and without interactivity.

其中該動態工作為瀏覽或查詢有後臺資料庫、有程式和有交互性的網頁。 Among them, the dynamic task is to browse or query web pages with background databases, programs, and interactions.

承上所述,依本發明之網頁伺服器負載平衡方法,其可具有一或多個下述優點: In summary, according to the web server load balancing method of the present invention, it can have one or more of the following advantages:

(1)藉由網頁介面處理器,可將工作需求分成靜態工作及動態工作,並進入工作佇列。 (1) With the web interface processor, work requirements can be divided into static work and dynamic work, and enter the work queue.

(2)分配器可針對工作佇列需求、負載平衡演算法及工作站資訊,進行挑選工作進工作站處理。 (2) The allocator can select work into the workstation for processing according to the work queue requirements, load balancing algorithm and workstation information.

(3)負載平衡演算法可依照工作類群(靜態或動態)及在佇列時間進行權重演算法以挑出工作,藉以改善整個系統的工作效率。 (3) The load balancing algorithm can perform a weighting algorithm according to the work group (static or dynamic) and the queue time to pick out the work, thereby improving the work efficiency of the entire system.

茲為使鈞審對本發明的技術特徵及所能達到的技術功效有更進一步的瞭解與認識,謹佐以較佳的實施例及配合詳細的說明如後。 In order to enable Jun Shen to have a further understanding and understanding of the technical features of the present invention and the technical effects that can be achieved, the preferred embodiments and detailed descriptions are provided below.

10:網頁介面處理器 10: Web interface processor

20:分配器 20: Distributor

30:工作站 30: Workstation

A:工作 A: work

圖1為本發明之網頁伺服器負載平衡方法之示意圖。 FIG. 1 is a schematic diagram of the load balancing method for a web server of the present invention.

為利瞭解本創作之技術特徵、內容與優點及其所能達成之功效,茲將本創作配合圖式,並以實施例之表達形式詳細說明如下,而其中所使用之圖式,其主旨僅為示意及輔助說明書之用,未必為本創作實施後之真實比例與精準配置,故不應就所附之圖式的比例與配置關係解讀、侷限本創作於實際實施上的權利範圍。此外,為使便於理解,下述實施例中的相同元件係以相同的符號標示來說明。 In order to understand the technical features, content and advantages of this creation and its achievable effects, this creation is combined with the diagrams, and detailed descriptions are given in the form of embodiments as follows, and the diagrams used therein have only To illustrate and supplement the manual, it may not be the true proportions and precise configuration after the implementation of this creation. Therefore, the proportion and configuration relationship of the attached drawings should not be interpreted or limited to the scope of rights of the creation in actual implementation. In addition, in order to facilitate understanding, the same elements in the following embodiments are denoted by the same symbols.

本創作之網頁伺服器負載平衡方法包含下列技術手段: The web server load balancing method of this creation includes the following technical means:

(1)動態網頁的核心就是使用資料庫來儲存網頁資料,而且透過主機端的即時「解譯」過程將網頁傳送至瀏覽器,主機會把這些網頁程式碼的語 法轉換成為標準的HTML語法,傳送給使用者瀏覽器,所以動態網頁對網頁主機的負載會比較大,因為主機不是只有單純傳送HTML檔案的工作而已,而是須要作許多的處理之後才將HTML送出。 (1) The core of a dynamic web page is to use a database to store web page data, and the web page is sent to the browser through the real-time "interpretation" process on the host side. The method is converted into standard HTML grammar and sent to the user’s browser, so the load of dynamic web pages on the web host will be relatively large, because the host does not only send HTML files, but needs to do a lot of processing before sending the HTML Send out.

在網站設計中,純粹HTML(標準通用標記語言下的一個應用)格式的網頁通常被稱為“靜態網頁”,靜態網頁是標準的HTML文件,它的文件擴展名是.htm、.html,可以包含文本、圖像、聲音、FLASH動畫、客戶端腳本和ActiveX控制項及JAVA小程式等。靜態網頁是網站建設的基礎,早期的網站一般都是由靜態網頁製作的。靜態網頁是相對於動態網頁而言,是指沒有後臺資料庫、不含程式和不可交互的網頁。 In website design, webpages in pure HTML (an application under the standard Universal Markup Language) format are usually called "static webpages". Static webpages are standard HTML files whose file extensions are .htm and .html. Contains text, image, sound, FLASH animation, client script and ActiveX control items and JAVA applets. Static web pages are the basis of website construction. Early websites were generally made from static web pages. Static webpages are relative to dynamic webpages. They refer to webpages that have no back-end database, no programs, and no interaction.

靜態網頁有時也被稱為平面頁。靜態網頁的網址形式通常為htm(超文本標記語言)結尾,還有就是以超文本標記語言(.htm、.html)、.shtml、.xml(可擴展標記語言)等為尾碼的。在超文本標記語言格式的網頁上,也可以出現各種動態的效果,如.GIF格式的動畫、FLASH、滾動字幕等,這些“動態效果”只是視覺上的,與下麵將要介紹的動態網頁是不同的概念。靜態網頁面通常是超文本標記語言文檔存儲為文件在文件系統裡頭,並且可以通過HTTP訪問網路伺服器。 Static web pages are sometimes called flat pages. The URL form of a static webpage usually ends with htm (hypertext markup language), and also ends with hypertext markup language (.htm, .html), .shtml, .xml (extensible markup language), etc. On hypertext markup language format webpages, various dynamic effects can also appear, such as animation in .GIF format, FLASH, rolling subtitles, etc. These "dynamic effects" are only visual, and are different from the dynamic webpages that will be introduced below. the concept of. A static web page is usually a hypertext markup language document stored as a file in the file system, and the web server can be accessed via HTTP.

(2)使用者群對公司網站進行瀏覽或查詢,網頁介面處理器將工作需求分成靜態工作及動態工作並進入工作佇列。 (2) The user group browses or queries the company website, and the web interface processor divides the work requirements into static work and dynamic work and enters the work queue.

(3)分配器會有三方資訊進入,1是工作佇列需求,2是負載平衡演算法,以及3工作站資訊,供分配器進行挑選工作進工作站處理。 (3) The allocator will enter information from three parties, 1 is the work queue requirement, 2 is the load balancing algorithm, and 3 workstation information for the allocator to select and enter the workstation for processing.

(4)負載平衡演算法是依照工作類群(靜態或動態,靜態權重大)(或者是動態權重大)及在佇列時間(越長時間權重越大)進行權重演算法挑出工作,這樣會使整個系統工作效率比較好。 (4) The load balancing algorithm is based on the work group (static or dynamic, with high static weight) (or with high dynamic weight) and the queue time (the longer the weight, the greater the weight). Make the whole system work better.

(5)工作站群會有資訊顯示工作站是否是忙碌或閒置,忙碌工作站會因工作需求,內部會指派另一工作站幫忙處理。 (5) The workstation group will have information showing whether the workstation is busy or idle. The busy workstation will internally assign another workstation to help with the work requirements.

請參閱圖1,圖1為本發明之網頁伺服器負載平衡方法之示意圖。如圖1所示,本發明之網頁伺服器負載平衡方法,包含:以網頁介面處理器10將複數個工作A(工作A、工作B…工作N)區分成靜態工作或動態工作,並進入動態工作佇列或靜態工作佇列;以負載平衡演算法依據該些工作A所屬之工作類群及在該些動態工作佇列及該些靜態工作佇列中的時間進行權重演算,藉以獲得該些工作A之複數個加權需求;以及以分配器20依據該些工作A之該些加權需求及複數個工作站資訊指派該些工作A給複數個工作站30(工作站1、工作站2、工作站3…工作站N)。 Please refer to FIG. 1. FIG. 1 is a schematic diagram of the web server load balancing method of the present invention. As shown in FIG. 1, the load balancing method for a web server of the present invention includes: using a web interface processor 10 to classify a plurality of jobs A (work A, job B...work N) into static jobs or dynamic jobs, and enter dynamic jobs Work queue or static work queue; load balancing algorithm is used to perform weight calculation based on the work group to which the work A belongs and the time in the dynamic work queue and the static work queue to obtain the work A plurality of weighted requirements; and according to the weighted requirements of the tasks A and the plurality of workstation information, the distributor 20 assigns the tasks A to the plurality of workstations 30 (Workstation 1, Workstation 2, Workstation 3...Workstation N) .

該些工作站資訊係包含該些工作站30之複數個狀態資訊。 The workstation information includes a plurality of status information of the workstations 30.

該些狀態資訊係該些工作站30處於忙碌狀態或閒置狀態。 The status information indicates that the workstations 30 are in a busy state or an idle state.

分配器20係先接收該些動態工作佇列及該些靜態工作佇列中的該些工作A之需求,再以該負載平衡演算法依據該些工作A所屬之工作類群及在該些動態工作佇列及該些靜態工作佇列中的時間進行權重演算,藉以獲得該些工作A之該些加權需求。 The allocator 20 first receives the needs of the jobs A in the dynamic job queues and the static job queues, and then uses the load balancing algorithm according to the job group to which the jobs A belong and in the dynamic jobs The time in the queue and the static work queues are weighted to obtain the weighted demands of the work A.

該些工作A於該些動態工作佇列的權重較佳為高於該些靜態工作佇列中的權重。或者,該些工作A於該些靜態工作佇列的權重也可以高於該些動態工作佇列中的權重。 The weights of the tasks A in the dynamic task queues are preferably higher than the weights in the static task queues. Alternatively, the weights of the jobs A in the static job queues may also be higher than the weights in the dynamic job queues.

該些工作A在該些動態工作佇列及該些靜態工作佇列中的時間越長則權重越大。 The longer the time of the jobs A in the dynamic job queues and the static job queues, the greater the weight.

複數個使用者係對一網站進行瀏覽或查詢,藉以產生該些工作A之需求給該網頁介面處理器10。 A plurality of users browse or query a website, so as to generate the requirements of the tasks A to the web interface processor 10.

該靜態工作為瀏覽或查詢無後臺資料庫、無程式和無交互性的網頁。而該動態工作為瀏覽或查詢有後臺資料庫、有程式和有交互性的網頁。 The static task is to browse or query web pages without a back-end database, without programs, and without interactivity. The dynamic task is to browse or query web pages with background databases, programs, and interactions.

綜上所述,依本發明之網頁伺服器負載平衡方法,其可具有一或多個下述優點:(1)藉由網頁介面處理器,可將工作需求分成靜態工作及動態工作,並進入工作佇列。(2)分配器可針對工作佇列需求、負載平衡演算法及工作站資訊,進行挑選工作進工作站處理。(3)負載平衡演算法可依照工作類群(靜態或動態)及在佇列時間進行權重演算法以挑出工作,藉以改善整個系統的工作效率。 In summary, according to the web server load balancing method of the present invention, it can have one or more of the following advantages: (1) With the web interface processor, work requirements can be divided into static work and dynamic work, and enter Work queue. (2) The allocator can select work into the workstation for processing according to the work queue requirements, load balancing algorithm and workstation information. (3) The load balancing algorithm can perform a weighting algorithm according to the work group (static or dynamic) and the queue time to pick out the work, thereby improving the work efficiency of the entire system.

以上所述僅為舉例性,而非為限制性者。任何未脫離本發明之精神與範疇,而對其進行之等效修改或變更,均應包含於後附之申請專利範圍中。 The above descriptions are merely illustrative and not restrictive. Any equivalent modifications or alterations that do not depart from the spirit and scope of the present invention should be included in the scope of the appended patent application.

10:網頁介面處理器 10: Web interface processor

20:分配器 20: Distributor

30:工作站 30: Workstation

A:工作 A: work

Claims (8)

一種網頁伺服器負載平衡方法,包含:以網頁介面處理器將複數個工作區分成靜態工作或動態工作,並進入動態工作佇列或靜態工作佇列;以負載平衡演算法依據該些工作所屬之工作類群及在該些動態工作佇列及該些靜態工作佇列中的時間進行權重演算,藉以獲得該些工作之複數個加權需求;以及以分配器依據該些工作之該些加權需求及複數個工作站資訊指派該些工作給複數個工作站,其中該分配器係先接收該些動態工作佇列及該些靜態工作佇列中的該些工作之需求,再以該負載平衡演算法依據該些工作所屬之工作類群及在該些動態工作佇列及該些靜態工作佇列中的時間進行權重演算,藉以獲得該些工作之該些加權需求。 A load balancing method for a web server includes: using a web interface processor to divide a plurality of tasks into static tasks or dynamic tasks, and entering a dynamic task queue or a static task queue; using a load balancing algorithm according to which tasks belong to The work group and the time in the dynamic work queues and the static work queues are weighted to calculate the weighted requirements of the tasks; and the weighted requirements and the complex numbers of the tasks are based on the allocator A workstation information assigns the tasks to a plurality of workstations, wherein the distributor first receives the needs of the tasks in the dynamic task queues and the static task queues, and then uses the load balancing algorithm according to the tasks The work category to which the work belongs and the time in the dynamic work queues and the static work queues are weighted to obtain the weighted requirements of the tasks. 如申請專利範圍第1項所述之網頁伺服器負載平衡方法,其中該些工作站資訊係包含該些工作站之複數個狀態資訊。 In the web server load balancing method described in item 1 of the scope of patent application, the workstation information includes a plurality of status information of the workstations. 如申請專利範圍第2項所述之網頁伺服器負載平衡方法,其中該些狀態資訊係該些工作站處於忙碌狀態或閒置狀態。 In the web server load balancing method described in the second item of the scope of patent application, the state information is that the workstations are in a busy state or an idle state. 如申請專利範圍第1項所述之網頁伺服器負載平衡方法,其中該些工作於該些動態工作佇列的權重高於該些靜態工作佇列中的權重。 In the web server load balancing method described in claim 1, wherein the weights of the work in the dynamic work queues are higher than the weights in the static work queues. 如申請專利範圍第1項所述之網頁伺服器負載平衡方法,其中該些工作在該些動態工作佇列及該些靜態工作佇列中的時間越長則權重越大。 For example, in the web server load balancing method described in item 1 of the scope of the patent application, the longer the jobs are in the dynamic job queues and the static job queues, the greater the weight. 如申請專利範圍第1項所述之網頁伺服器負載平衡方法,其中複數個使用者係對一網站進行瀏覽或查詢,藉以產生該些工作之需求給該網頁介面處理器。 For example, in the web server load balancing method described in item 1 of the scope of patent application, a plurality of users browse or query a website to generate the work requirements for the web interface processor. 如申請專利範圍第6項所述之網頁伺服器負載平衡方法,其中該靜態工作為瀏覽或查詢無後臺資料庫、無程式和無交互性的網頁。 For example, in the web server load balancing method described in item 6 of the scope of patent application, the static work is browsing or querying web pages without a back-end database, no programs, and no interactivity. 如申請專利範圍第6項所述之網頁伺服器負載平衡方法,其中該動態工作為瀏覽或查詢有後臺資料庫、有程式和有交互性的網頁。 For example, in the web server load balancing method described in item 6 of the scope of patent application, the dynamic task is to browse or query web pages with background databases, programs, and interactions.
TW109116008A 2020-05-14 2020-05-14 Web server load balancing method TWI735228B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
TW109116008A TWI735228B (en) 2020-05-14 2020-05-14 Web server load balancing method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
TW109116008A TWI735228B (en) 2020-05-14 2020-05-14 Web server load balancing method

Publications (2)

Publication Number Publication Date
TWI735228B true TWI735228B (en) 2021-08-01
TW202143687A TW202143687A (en) 2021-11-16

Family

ID=78283437

Family Applications (1)

Application Number Title Priority Date Filing Date
TW109116008A TWI735228B (en) 2020-05-14 2020-05-14 Web server load balancing method

Country Status (1)

Country Link
TW (1) TWI735228B (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103391299A (en) * 2012-05-08 2013-11-13 深圳市腾讯计算机系统有限公司 Load balance method and load balance system
TW201824822A (en) * 2016-12-27 2018-07-01 英業達股份有限公司 Loading balance system for processing segment processing requests and method thereof
US20190253357A1 (en) * 2018-10-15 2019-08-15 Intel Corporation Load balancing based on packet processing loads
US20200026564A1 (en) * 2017-05-04 2020-01-23 Salesforce.Com, Inc. Systems, methods, and apparatuses for implementing a scheduler and workload manager with dynamic workload termination based on cost-benefit analysis

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103391299A (en) * 2012-05-08 2013-11-13 深圳市腾讯计算机系统有限公司 Load balance method and load balance system
TW201824822A (en) * 2016-12-27 2018-07-01 英業達股份有限公司 Loading balance system for processing segment processing requests and method thereof
US20200026564A1 (en) * 2017-05-04 2020-01-23 Salesforce.Com, Inc. Systems, methods, and apparatuses for implementing a scheduler and workload manager with dynamic workload termination based on cost-benefit analysis
US20190253357A1 (en) * 2018-10-15 2019-08-15 Intel Corporation Load balancing based on packet processing loads

Also Published As

Publication number Publication date
TW202143687A (en) 2021-11-16

Similar Documents

Publication Publication Date Title
US11194882B1 (en) Behavior based optimization for content presentation
JP4988729B2 (en) Method, apparatus, and computer program for generating a portal page including a plurality of portlets
US9317683B2 (en) Dynamic media content previews
US20140359491A1 (en) Pre-fetching of network page content
US20030097429A1 (en) Method of forming a website server cluster and structure thereof
JP6736440B2 (en) Device, method and program for providing document file generation service in cloud system
JP7038740B2 (en) Data aggregation methods for cache optimization and efficient processing
WO2015149307A1 (en) Systems and methods for optimizing content layout using behavior metrics
US20090204593A1 (en) System and method for parallel retrieval of data from a distributed database
WO2021047239A1 (en) Page acquisition method, device and system
CA2832911A1 (en) System and method for filtering documents
US20200151227A1 (en) Computing system with dynamic web page feature
TWI735228B (en) Web server load balancing method
US20240095298A1 (en) Systems and methods for rendering interactive web pages
EP3853744A1 (en) Provision of different content pages based on varying user interactions with a single content item
US9372840B1 (en) Method and system for accelerated transformation of content based on predictive chunking
US20020092012A1 (en) Smart-caching system and method
US11328030B2 (en) Systems and methods of generating or updating a design based on a universal resource locator (URL)
Kim et al. Video transcoding scheme of multimedia data-hiding for multiform resources based on intra-cloud
Yu et al. A distributed web crawler model based on cloud computing
CN109933382B (en) Online ppt file preview tool based on owa service
Huang et al. Study of performance measures and energy consumption for cloud computing centers based on queueing theory
US11210358B2 (en) Deep learning approach to mitigate the cold-start problem in textual items recommendations
US11550814B1 (en) Pagination processing and display of data sets
Lin et al. The adaptive load balancing algorithm in cloud computing