JPWO2014199606A1 - Load distribution apparatus, load distribution method and program, and event processing system - Google Patents
Load distribution apparatus, load distribution method and program, and event processing system Download PDFInfo
- Publication number
- JPWO2014199606A1 JPWO2014199606A1 JP2015522528A JP2015522528A JPWO2014199606A1 JP WO2014199606 A1 JPWO2014199606 A1 JP WO2014199606A1 JP 2015522528 A JP2015522528 A JP 2015522528A JP 2015522528 A JP2015522528 A JP 2015522528A JP WO2014199606 A1 JPWO2014199606 A1 JP WO2014199606A1
- Authority
- JP
- Japan
- Prior art keywords
- event
- load
- distribution
- transmission
- distribution device
- Prior art date
- Legal status (The legal status 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 status listed.)
- Pending
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
- G06F9/46—Multiprogramming arrangements
- G06F9/50—Allocation of resources, e.g. of the central processing unit [CPU]
- G06F9/5005—Allocation of resources, e.g. of the central processing unit [CPU] to service a request
- G06F9/5027—Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resource being a machine, e.g. CPUs, Servers, Terminals
- G06F9/505—Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resource being a machine, e.g. CPUs, Servers, Terminals considering the load
Landscapes
- Engineering & Computer Science (AREA)
- Software Systems (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Computer And Data Communications (AREA)
Abstract
イベント処理システムにおいて、適切な負荷分散を実現する負荷分散装置等を提供する。負荷分散装置は、振り分け装置が所定期間内に受信するイベントの、数量または情報サイズを表す情報である受信状況を取得する取得手段と、受信状況に基づいて、振り分け装置がイベント生成源から処理装置へとイベントを転送する際に振り分け装置にかかる負荷が、複数の振り分け装置の間で平準化されるように、送信先決定ルールを更新する更新手段を備える。In an event processing system, a load distribution device or the like for realizing appropriate load distribution is provided. The load distribution apparatus includes: an acquisition unit that acquires a reception status that is information representing a quantity or an information size of an event received by the distribution device within a predetermined period; Update means for updating the transmission destination determination rule so that the load applied to the distribution device when the event is transferred to the destination is leveled among the plurality of distribution devices.
Description
本発明は、イベント処理システムにおいて用いられる負荷分散装置、負荷分散方法および記憶媒体ならびにイベント処理システム等に関する。 The present invention relates to a load distribution device, a load distribution method, a storage medium, an event processing system, and the like used in an event processing system.
近年では、大量のセンサーが、通信ネットワーク(以下、「ネットワーク」と記載)に接続されている。これらセンサーは、例えば電力消費量、交通情報、気温、株価の変動または位置情報など、様々な情報(イベント)を収集する。 In recent years, a large number of sensors are connected to a communication network (hereinafter referred to as “network”). These sensors collect various information (events) such as power consumption, traffic information, temperature, stock price fluctuations or position information.
また、近年では、大量のアプリケーションが、ネットワークに接続されている。これらアプリケーションは、ネットワークを介して、オペレータから、または、外部装置からの操作を受け付ける。 In recent years, a large number of applications are connected to a network. These applications accept operations from an operator or an external device via a network.
このような背景に基づいて、M2M (Machine to Machine)という技術が注目を集めている。M2Mという技術によれば、アプリケーションは、センサーが収集したイベントをネットワークを介して受信する。そして、アプリケーションは、受信したイベントに基づいて状況を判断したり、処理を実行したりする。このようにM2Mという技術によれば、アプリケーションは、センサーが収集したイベントに基づいて人手を介することなく自律的に制御される。 Based on this background, a technology called M2M (Machine to Machine) has attracted attention. According to the technology called M2M, an application receives events collected by sensors via a network. And an application judges a condition based on the received event, or performs a process. As described above, according to the technology called M2M, the application is autonomously controlled based on the events collected by the sensors without any manual intervention.
通信ネットワークに接続されるセンサーの数量の増加に伴い、M2Mサービスは、今後更に大規模化することが予想される。そのため、サービスの大規模化に対応可能なイベント処理システムが求められる。 As the number of sensors connected to the communication network increases, the M2M service is expected to become even larger in the future. Therefore, there is a need for an event processing system that can cope with an increase in the scale of services.
特許文献1は、イベント処理システムの一例を開示する。図33は、特許文献1が開示するイベント処理システムの概要を示す図である。
図33に示すように、特許文献1が開示するイベント処理システムは、アプリケーション(AP)5000と、処理サーバ4000と、コンテキスト依存振り分け器3000と、デバイス2000と、イベント処理分散制御装置6000と、コンテキスト非依存振り分け器7000と、を含む。
As shown in FIG. 33, the event processing system disclosed in
処理サーバ4000は、コンテキスト依存振り分け器3000からイベントを受信し、受信したイベントを処理し、アプリケーション5000にイベントの処理結果を通知する。コンテキスト依存振り分け器3000は、デバイス2000が生成したイベントを処理サーバ4000に振り分ける。デバイス2000は、イベントを生成する。
The
イベント処理分散制御装置6000は、アプリケーション5000からの要求に基づき以下の処理を行う。すなわちイベント処理分散制御装置6000は、イベントの内容(コンテキスト)に基づく処理を示す処理ルールを、処理サーバ4000に設定する。イベント処理分散制御装置6000は、更に、処理ルールを実行するために必要なイベントが、処理サーバ4000に適切に分配されるように、振り分けルールをコンテキスト依存振り分け器3000に設定する。
The event processing distributed control device 6000 performs the following processing based on a request from the
コンテキスト依存振り分け器3000には、イベント処理分散制御装置6000により、振り分けルールがあらかじめ設定されている。コンテキスト依存振り分け器3000は、イベントを受信する。そして、コンテキスト依存振り分け器3000は、受信したイベントの内容(コンテキスト)と振り分けルールとに基づいて、受信したイベントを、複数の処理サーバ4000のうちいずれの処理サーバ4000に転送するかを決定する。
In the context
処理サーバ4000には、イベント処理分散制御装置6000により、処理ルールが、あらかじめ設定されている。処理サーバ4000は、転送されたイベントを、処理ルールに基づいて処理し、イベント処理結果をアプリケーション5000に送信する。
Processing rules are set in advance in the
特許文献1が開示するコンテキスト非依存振り分け器7000は、複数のコンテキスト依存振り分け器3000の間で負荷分散を実現するための構成である。コンテキスト非依存振り分け器7000は、デバイス2000からイベントを受信し、コンテキスト依存振り分け器3000に受信したイベントをランダムに転送する。このように、デバイス2000とコンテキスト依存振り分け器3000との間にコンテキスト非依存振り分け器7000が介在することにより、コンテキスト依存振り分け器3000が受信するイベントの数量が平準化される。
The context-independent distributor 7000 disclosed in
コンテキスト依存振り分け器3000が受信するイベントの数量が平準化されたとしても、コンテキスト依存振り分け器3000の負荷分散が適切になされない場合がある。コンテキスト非依存振り分け器7000は、イベント処理システムにおいて、精度の高い負荷分散を実現することができない。
Even if the number of events received by the context-
本発明は、イベント処理システムにおいて、精度の高い負荷分散を実現することが可能な、負荷分散装置、負荷分散方法および記憶媒体等を提供することを主たる目的とする。 An object of the present invention is to provide a load distribution device, a load distribution method, a storage medium, and the like that can realize highly accurate load distribution in an event processing system.
また、本発明は、精度の高い負荷分散を実現可能なイベント処理システム等を提供することを主たる目的とする。 Another object of the present invention is to provide an event processing system or the like that can realize highly accurate load distribution.
本発明の第1の側面は、イベント送信源から複数のイベントを受信し、前記受信した個々のイベントについて、当該イベントに含まれる情報と振り分けルールとに基づいて、当該イベントを破棄するか、あるいは、当該イベントを1つまたは複数の処理装置に転送する、複数の振り分け装置と、前記複数の振り分け装置のうち、送信先決定ルールに基づいて決定される振り分け装置に、イベントを送信する1つまたは複数のイベント送信源と、を含むシステムと通信可能に接続され、前記振り分け装置が所定期間内に受信するイベントの、数量または情報サイズを表す情報である受信状況、および、前記イベント送信源が所定期間内に送信するイベントの、数量または情報サイズを表す情報である送信状況を取得する取得手段と、前記受信状況および送信状況に基づいて、前記振り分け装置が前記イベント生成源から前記処理装置へとイベントを転送する際に前記振り分け装置にかかる負荷が、前記複数の振り分け装置の間で平準化されるように、前記送信先決定ルールを更新する更新手段と、を備える負荷分散装置である。 The first aspect of the present invention receives a plurality of events from an event transmission source and discards the events for each received event based on information included in the event and a distribution rule. , Transferring the event to one or more processing devices, and transmitting one or more events to a distribution device determined based on a transmission destination determination rule among the plurality of distribution devices or A plurality of event transmission sources that are communicably connected to a system including the reception status that is information indicating a quantity or an information size of an event received by the distribution device within a predetermined period, and the event transmission source is predetermined An acquisition means for acquiring a transmission status which is information indicating a quantity or an information size of an event transmitted within a period; And based on the transmission status, the load applied to the distribution device when the distribution device transfers an event from the event generation source to the processing device is leveled among the plurality of distribution devices. Updating means for updating the transmission destination determination rule.
本発明の第2の側面は、イベント送信源から複数のイベントを受信し、前記受信した個々のイベントについて、当該イベントに含まれる情報と振り分けルールとに基づいて、当該イベントを破棄するか、あるいは、当該イベントを1つまたは複数の処理装置に転送する、複数の振り分け装置と、前記複数の振り分け装置のうち、送信先決定ルールに基づいて決定される振り分け装置に、イベントを送信する1つまたは複数のイベント送信源と、を含むシステムと通信可能に接続されるコンピュータが、前記振り分け装置が所定期間内に受信するイベントの、数量または情報サイズを表す情報である受信状況、および、前記イベント送信源が所定期間内に送信するイベントの、数量または情報サイズを表す情報である送信状況を取得し、前記受信状況および送信状況に基づいて、前記振り分け装置が前記イベント生成源から前記処理装置へとイベントを転送する際に前記振り分け装置にかかる負荷が、前記複数の振り分け装置の間で平準化されるように、前記送信先決定ルールを更新する、負荷分散方法である。 According to a second aspect of the present invention, a plurality of events are received from an event transmission source, and the received event is discarded based on information included in the event and a distribution rule. , Transferring the event to one or more processing devices, and transmitting one or more events to a distribution device determined based on a transmission destination determination rule among the plurality of distribution devices or A reception state which is information indicating a quantity or an information size of an event received by the distribution device within a predetermined period by a computer communicably connected to a system including a plurality of event transmission sources, and the event transmission The transmission status, which is information indicating the quantity or information size of the event transmitted by the source within a predetermined period, is acquired, and the reception is performed. Based on a situation and a transmission situation, when the distribution device transfers an event from the event generation source to the processing device, a load applied to the distribution device is leveled among the plurality of distribution devices A load balancing method for updating the transmission destination determination rule.
本発明の第3の側面は、イベント送信源から複数のイベントを受信し、前記受信した個々のイベントについて、当該イベントに含まれる情報と振り分けルールとに基づいて、当該イベントを破棄するか、あるいは、当該イベントを1つまたは複数の処理装置に転送する、複数の振り分け装置と、前記複数の振り分け装置のうち、送信先決定ルールに基づいて決定される振り分け装置に、イベントを送信する1つまたは複数のイベント送信源と、を含むシステムと通信可能に接続されるコンピュータに、前記振り分け装置が所定期間内に受信するイベントの、数量または情報サイズを表す情報である受信状況、および、前記イベント送信源が所定期間内に送信するイベントの、数量または情報サイズを表す情報である送信状況を取得する処理と、前記受信状況および送信状況に基づいて、前記振り分け装置が前記イベント生成源から前記処理装置へとイベントを転送する際に前記振り分け装置にかかる負荷が、前記複数の振り分け装置の間で平準化されるように、前記送信先決定ルールを更新する処理とを実行させるプログラムを記録したコンピュータ読み取り可能な記憶媒体である。 According to a third aspect of the present invention, a plurality of events are received from an event transmission source, and for each received event, the event is discarded based on information included in the event and a distribution rule, or , Transferring the event to one or more processing devices, and transmitting one or more events to a distribution device determined based on a transmission destination determination rule among the plurality of distribution devices or A reception state that is information representing a quantity or an information size of an event received by the distribution device within a predetermined period to a computer communicably connected to a system including a plurality of event transmission sources, and the event transmission A process of acquiring a transmission status that is information indicating the quantity or information size of an event transmitted by a source within a predetermined period; Based on the reception status and transmission status, a load applied to the distribution device when the distribution device transfers an event from the event generation source to the processing device is leveled among the plurality of distribution devices. As described above, the computer-readable storage medium stores a program for executing processing for updating the transmission destination determination rule.
本発明の第4の側面は、イベント送信源から複数のイベントを受信し、前記受信した個々のイベントについて、当該イベントに含まれる情報と振り分けルールとに基づいて、当該イベントを破棄するか、あるいは、当該イベントを1つまたは複数の処理装置に転送する、複数の振り分け装置と、前記複数の振り分け装置のうち、送信先決定ルールに基づいて決定される振り分け装置に、イベントを送信する1つまたは複数のイベント送信源とを含み、更に、前記振り分け装置が所定期間内に受信するイベントの、数量または情報サイズを表す情報である受信状況、および、前記イベント送信源が所定期間内に送信するイベントの、数量または情報サイズを表す情報である送信状況を取得する取得手段と、前記受信状況および送信状況に基づいて、前記振り分け装置が前記イベント生成源から前記処理装置へとイベントを転送する際に前記振り分け装置にかかる負荷が、前記複数の振り分け装置の間で平準化されるように、前記送信先決定ルールを更新する更新手段と、を備える負荷分散装置を含む、イベント処理システムである。 According to a fourth aspect of the present invention, a plurality of events are received from an event transmission source, and for each received event, the event is discarded based on information included in the event and a distribution rule, or , Transferring the event to one or more processing devices, and transmitting one or more events to a distribution device determined based on a transmission destination determination rule among the plurality of distribution devices or A plurality of event transmission sources, and a reception status that is information indicating a quantity or an information size of an event received by the distribution device within a predetermined period, and an event transmitted by the event transmission source within a predetermined period Acquisition means for acquiring a transmission status which is information representing a quantity or an information size, and based on the reception status and the transmission status The transmission destination determination rule is set so that a load applied to the distribution device when the distribution device transfers an event from the event generation source to the processing device is leveled among the plurality of distribution devices. An event processing system including a load balancer including an updating unit for updating.
また、本発明の目的は、上記のプログラムが格納されたコンピュータ読み取り可能な記憶媒体によっても達成される。 The object of the present invention is also achieved by a computer-readable storage medium storing the above program.
本発明によれば、イベント処理システムにおいて、精度の高い負荷分散を実現することができる。 According to the present invention, highly accurate load distribution can be realized in an event processing system.
<第1の実施形態>
第1の実施形態にかかる負荷分散装置100について、図面を参照して詳細に説明する。<First Embodiment>
The
図1は、負荷分散装置100を含むイベント処理システム1000の構成を示すブロック図である。図1に示すように、イベント処理システム1000は、複数のイベント送信源200と、複数の振り分け装置300と、複数の処理装置400と、複数のアプリケーション(AP)500と、ルール設定装置600と、負荷分散装置100と、を含む。
FIG. 1 is a block diagram illustrating a configuration of an
以下、複数のイベント送信源200を互いに区別する必要がある場合は、イベント送信源200A、イベント送信源200B・・・と記載する。同様に、複数の振り分け装置300を互いに区別する必要がある場合は、振り分け装置300A、振り分け装置300B…と記載する。そして、複数の処理装置400を互いに区別する必要がある場合は、処理装置400A、処理装置400B・・・と記載する。以下、複数のアプリケーション500を互いに区別する必要がある場合は、アプリケーション500A、アプリケーション500B・・・と記載する。
Hereinafter, when it is necessary to distinguish the plurality of
イベント送信源200の数(すなわち数量)、振り分け装置300の数、処理装置400の数およびアプリケーション500の数は、図1に示した数には限定されない。イベント送信源200の数、振り分け装置300の数、処理装置400の数およびアプリケーション500の数の大小関係は、図1に示した関係には限定されない。
The number of event transmission sources 200 (that is, the number), the number of distribution devices 300, the number of processing devices 400, and the number of applications 500 are not limited to the numbers shown in FIG. The magnitude relationship among the number of
イベント送信源200は、イベントを生成する。イベントは、例えば、当該イベントを生成したイベント送信源200の識別子(ID)と、測定値とを含む情報である。イベント送信源200は、生成したイベントを、振り分け装置300に送信する。イベント送信源200がイベントを送信する送信先の振り分け装置300は、送信先決定ルールに基づいて、あらかじめ指定されている。
The
図2は、送信先決定ルールの一例を示す図である。図2には、送信先決定ルール1〜4が示されている。図2に示す送信先決定ルール1は、イベント送信源200Aが、振り分け装置300Aにイベントを送信することを示している。図2に示す送信先決定ルール2は、イベント送信源200Bが、振り分け装置300Aにイベントを送信することを示している。図2に示す送信先決定ルール3は、イベント送信源200Cが、振り分け装置300Aにイベントを送信することを示している。図2に示す送信先決定ルール4は、イベント送信源200Dが、振り分け装置300Bにイベントを送信することを示している。
FIG. 2 is a diagram illustrating an example of a transmission destination determination rule. FIG. 2 shows transmission destination determination rules 1 to 4. The transmission
第1の実施形態における送信先決定ルールは、各イベント送信源200の間で必ずしも共有されている必要はない。各イベント送信源200は、少なくとも自装置に関係する送信先決定ルールを参照できればよい。例えば、イベント送信源200Aは、自装置に関する送信先決定ルール1のみを参照できればよい。イベント送信源200Aは、他のイベント送信源200に関する送信先決定ルール2〜4を参照可能である必要はない。
The transmission destination determination rule in the first embodiment is not necessarily shared between the event transmission sources 200. Each
振り分け装置300は、1つまたは複数のイベント送信源200からイベントを受信する。図1に示す例では、例えば振り分け装置300Aは、イベント送信源200A、200Bおよび200Cからそれぞれイベントを受信する。振り分け装置300は、イベント送信源200から受信したイベントを処理装置400に送信する。以下、この処理を「イベントの転送」と記載する。
The distribution device 300 receives events from one or more event transmission sources 200. In the example illustrated in FIG. 1, for example, the
振り分け装置300には、ルール設定装置600により、あらかじめ振り分けルールが設定されている。振り分け装置300は、イベントを受信すると、振り分けルールを参照する。振り分け装置300は、イベントの内容と振り分けルールとに基づいて、イベントを処理装置400に送信するか否かを決定する。また、振り分け装置300は、複数の処理装置400のうちいずれの処理装置400にイベントを送信するかを決定する。また、振り分け装置300は、負荷分散装置100に、転送状況を送信する。転送状況の詳細は後述する。
A sorting rule is set in advance in the sorting device 300 by the
処理装置400は、振り分け装置300からイベントを受信する。処理装置400には、ルール設定装置600により、あらかじめ処理ルールが設定されている。処理装置400は、イベントを受信すると、処理ルールを参照してイベントを処理する。処理装置400は、イベント処理結果をアプリケーション500に送信する。
The processing device 400 receives an event from the distribution device 300. Processing rules are set in advance in the processing device 400 by the
アプリケーション500は、処理装置400からイベント処理結果を受信する。アプリケーション500は、受信したイベント処理結果に基づいて、アプリケーションの利用者にサービスを提供する。アプリケーション500は、所望のイベント処理結果が生成されるような処理ルールを作成する。アプリケーション500は、処理ルールを、ルール設定装置600に送信する。
The application 500 receives the event processing result from the processing device 400. The application 500 provides a service to the user of the application based on the received event processing result. The application 500 creates a processing rule that generates a desired event processing result. The application 500 transmits the processing rule to the
ルール設定装置600は、アプリケーション500から処理ルールを受信する。ルール設定装置600は、複数の処理装置400の間の負荷が均等あるいは略均等になるように、かつ、同じイベント送信源200が生成したイベントが同じ処理装置400で処理されるように、処理ルールを処理装置400に設定する。ルール設定装置600は、処理ルールを実行するために必要なイベントが、当該処理を実行する処理装置400に適切に分配されるように、振り分けルールを振り分け装置300に設定する。ルール設定装置600は、例えば特許文献1が開示する方法によって、処理ルールを設定するとともに振り分けルールを設定する。
The
負荷分散装置100は、振り分け装置300から、転送状況を受信する。転送状況の詳細は後述する。負荷分散装置100は、受信した転送状況に基づいて、送信先決定ルールを更新する。すなわち、負荷分散装置100は、転送状況に基づいて、どのイベント送信源200が、どの振り分け装置300にイベントを送信するかを決定する。負荷分散装置100は、イベント送信源200に、更新された送信先決定ルールを通知する。
The
図3は、図1に示すイベント送信源200の構成を示すブロック図である。図3に示すように、イベント送信源200は、センサー210と、送信先決定ルール記憶部220と、送信部230とを有する。
FIG. 3 is a block diagram showing a configuration of the
センサー210は、イベントを生成する。センサー210が生成するイベントには、例えば、電力消費量の値、交通情報、気温の値、株価の変動または位置情報などが含まれる。 The sensor 210 generates an event. Events generated by the sensor 210 include, for example, power consumption values, traffic information, temperature values, stock price fluctuations, or location information.
送信先決定ルール記憶部220は、自装置に関係のある送信先決定ルールを記憶している。送信先決定ルール記憶部220は、送信先決定ルールとして、送信先決定ルールに基づいて決定される送信先である振り分け装置300のアドレスを記憶していてもよい。例えば、イベント送信源200Aが有する送信先決定ルール記憶部220Aは、図2に示す送信先決定ルール1を記憶している。送信先決定ルール記憶部220Aは、送信先決定ルール1として、振り分け装置300Aのアドレスを記憶していてもよい。
The transmission destination determination rule storage unit 220 stores transmission destination determination rules related to the device itself. The transmission destination determination rule storage unit 220 may store an address of the sorting apparatus 300 that is a transmission destination determined based on the transmission destination determination rule as a transmission destination determination rule. For example, the transmission destination determination rule storage unit 220A included in the
送信部230は、送信先決定ルール記憶部220が記憶している送信先決定ルールに基づいて、振り分け装置300にセンサー210が生成したイベントを送信する。 The transmission unit 230 transmits the event generated by the sensor 210 to the distribution device 300 based on the transmission destination determination rule stored in the transmission destination determination rule storage unit 220.
図4は、図1に示す振り分け装置300の構成を示すブロック図である。図4に示すように、振り分け装置300は、受信部310と、振り分けルール検索部320と、送信部330と、振り分けルール記憶部340と、フロー計測部350と、処理量計測部360と、処理量ウェイト計算部370と、を有する。
FIG. 4 is a block diagram showing the configuration of the sorting apparatus 300 shown in FIG. As shown in FIG. 4, the distribution device 300 includes a reception unit 310, a distribution
受信部310は、イベント送信源200からイベントを受信する。
The receiving unit 310 receives an event from the
振り分けルール検索部320は、受信部310が受信したイベントと、振り分けルール記憶部340が記憶している振り分けルールとのマッチング処理を行う。振り分けルール検索部320は、マッチングの結果に基づいて、受信したイベントを破棄するか、あるいは、受信したイベントを処理装置400に送信するかを判断する。振り分けルール検索部320は更に、マッチングの結果に基づいて、複数の処理装置400のうち、いずれの処理装置400にイベントを送信するかを判断する。
The distribution
送信部330は、振り分けルール検索部320の判断に基づいて、受信部310が受信したイベントを処理装置400に送信する。
The transmission unit 330 transmits the event received by the reception unit 310 to the processing device 400 based on the determination of the distribution
振り分けルール記憶部340は、振り分けルールを記憶する。振り分けルール記憶部340に振り分けルールが記憶されることを、以下、「振り分けルールが設定される」と記載する。振り分けルールは、ルール設定装置600により設定される。
The distribution
図5は、振り分けルール記憶部340が記憶している振り分けルールの一例を示す図である。図5に示す例では、振り分けルール記憶部340は、振り分けルール1〜4を記憶している。
FIG. 5 is a diagram illustrating an example of a distribution rule stored in the distribution
図5に示す振り分けルール1〜4によれば、振り分け装置300が受信したイベントは、当該イベントに含まれる緯度と経度の値に応じて、処理装置400A〜Dのいずれかに転送される。
According to the
振り分けルール検索部320は、イベントにマッチングする振り分けルールを検索できなかった場合、当該イベントを破棄する。
The distribution
例えば受信部310が、(緯度35.600,経度140.000)という値を含むイベントを受信した場合を想定する。振り分けルール検索部320は、受信したイベントと、振り分けルール記憶部340が記憶している振り分けルールとのマッチング処理を行う。しかし、緯度と経度の値が(緯度35.600,経度140.000)であるイベントにマッチングする振り分けルールは、図4に示す振り分けルール記憶部340には記憶されていない。このような場合、振り分けルール検索部320は、当該イベントを破棄する。
For example, it is assumed that the receiving unit 310 receives an event including a value of (latitude 35.600, longitude 140.000). The distribution
図4を参照する説明に戻る。フロー計測部350は、転送状況を計測し、計測した転送状況を負荷分散装置100に送信する。転送状況は、振り分け装置300がイベントを転送する際に振り分け装置300にかかる負荷を算出するために必要な情報である。転送状況は、受信状況および送信状況を含む情報である。受信状況は、振り分け装置300が、特定のイベント送信源200から受信したイベントの、数量または情報の量(データサイズ等)に関する情報である。送信状況は、振り分け装置300が、特定のイベント送信源200から受信し、処理装置400に送信したイベントの、数量または情報の量に関する情報である。
Returning to the description with reference to FIG. The
なお、上記受信したイベント、または、送信したイベントに関する情報の量は、当該イベントのデータの量(データサイズ)を表す。本願においては、係る情報の量を単に「情報サイズ」と称する場合がある。 The amount of information related to the received event or the transmitted event represents the data amount (data size) of the event. In the present application, the amount of information may be simply referred to as “information size”.
フロー計測部350は、自装置(振り分け装置300)が受信するイベントの送信元である、1つまたは複数のイベント送信源200のそれぞれについて、転送状況を計測する。
The
振り分け装置300Aが有するフロー計測部350Aが計測する転送状況を例に、転送状況をより詳細に説明する。図1に示すように、振り分け装置300Aは、イベント送信源200A、200Bおよび200Cからそれぞれイベントを受信する。振り分け装置300Aが有するフロー計測部350Aは、イベント送信源200Aから受信するイベントについて、転送状況を計測する。また、フロー計測部350Aは、同様に、イベント送信源200Bから受信するイベントおよびイベント送信源200Cから受信するイベントのそれぞれについて、転送状況を計測する。
The transfer status will be described in more detail using the transfer status measured by the flow measurement unit 350A included in the
図6は、振り分け装置300Aが有するフロー計測部350Aが計測する転送状況の一例を示す図である。図6に示すように、転送状況は、振り分け装置300を識別する情報(振り分け装置ID)と、イベントの送信元であるイベント送信源200を識別する情報(イベント送信源ID)と、受信状況を示す情報と、送信状況を示す情報とが関連づけされた情報である。
FIG. 6 is a diagram illustrating an example of a transfer state measured by the flow measurement unit 350A included in the
受信状況は、振り分け装置300が所定の期間内にイベントを受信した回数に関する値を含む。受信状況は、さらに、振り分け装置300が所定の期間内に受信したイベントの情報サイズに関する値を含んでいてもよい。送信状況は、振り分け装置300が所定の期間内にイベントを送信した回数に関する値を含む。送信状況は、さらに、振り分け装置300が所定の期間内に送信したイベントの情報サイズに関する値を含んでいてもよい。 The reception status includes a value related to the number of times the distribution device 300 has received an event within a predetermined period. The reception status may further include a value related to the information size of the event received by the distribution apparatus 300 within a predetermined period. The transmission status includes a value related to the number of times the distribution device 300 has transmitted an event within a predetermined period. The transmission status may further include a value related to the information size of the event transmitted by the distribution device 300 within a predetermined period.
転送状況はマッチング率を含んでいてもよい(例えば、図6に例示する「マッチ率」)。マッチング率は、振り分け装置300がイベント送信源200から受信したイベントの数量に対する、処理装置400に送信したイベントの数量の割合である。
The transfer status may include a matching rate (for example, “match rate” illustrated in FIG. 6). The matching rate is the ratio of the number of events transmitted to the processing device 400 to the number of events received by the distribution device 300 from the
図6に示す転送状況は、振り分け装置300Aが、所定の期間内にイベント送信源200Aから200回イベントを受信し、所定の期間内にイベント送信源200Aから受信したイベントの情報サイズの総量は50MB(メガバイト)であり、所定の期間内にイベント送信源200Aから受信したイベントを100回、処理装置400に送信したことを示す。イベント送信源200Aから受信したイベントのマッチング率は、100×(100(送信回数)/200(受信回数))=50%である。ここで記号"×"は乗算を表す記号である。ここで記号"/"は除算を表す記号である。
In the transfer status shown in FIG. 6, the
図6に示す転送状況は、振り分け装置300Aが、所定の期間内にイベント送信源200Bから100回イベントを受信し、所定の期間内にイベント送信源200Bから受信したイベントの情報サイズの総量は30MBであり、所定の期間内にイベント送信源200Bから受信したイベントを100回、処理装置400に送信したことを示す。イベント送信源200Bから受信したイベントのマッチング率は、100×(100(送信回数)/100(受信回数))=100%である。
In the transfer status shown in FIG. 6, the
図6に示す転送状況は、振り分け装置300Aが、所定の期間内にイベント送信源200Cから50回イベントを受信し、所定の期間内にイベント送信源200Cから受信したイベントの情報サイズの総量15MBであり、所定の期間内にイベント送信源200Cから受信したイベントを0回、処理装置400に送信したことを示す。イベント送信源200Cから受信したイベントのマッチング率は、100×(0(送信回数)/50(受信回数))=0%である。
In the transfer status shown in FIG. 6, the
図4を参照する説明に戻る。処理量計測部360は、受信部310がイベントを受信する際にかかる1イベントあたりの処理量を計測する。処理量計測部360は、受信部310がイベントを受信する際にかかる単位情報サイズあたりの処理量を計測してもよい。
Returning to the description with reference to FIG. The processing
処理量計測部360はさらに、振り分けルール検索部320が、イベントと振り分けルールとのマッチングによりイベントの送信先を決定する処理を行う際にかかる、1イベントあたりの処理量を計測する。
The processing
処理量計測部360は、さらに、送信部330がイベントを送信する際にかかる1イベント当たりの処理量を計測する。処理量計測部360は、送信部330がイベントを送信する際にかかる単位情報サイズあたりの処理量を計測してもよい。
The processing
処理量計測部360は、例えばSocket API(Application Programming Interface)を呼び出し前後の時刻を比較するなどの方法により、上記処理量を計測することができる。
The processing
処理量ウェイト計算部370は、処理量計測部360が計測した1イベントあたり、または単位情報サイズあたりの処理量を、負荷分散装置100に送信する。
The processing amount weight calculation unit 370 transmits the processing amount per event or unit information size measured by the processing
図7は、図1に示す処理装置400の構成を示すブロック図である。図7に示すように、処理装置400は、処理部410と、処理ルール記憶部420とを含む。処理部410は、振り分け装置300からイベントを受信する。処理部410は、イベントを受信すると、処理ルール記憶部420が記憶している処理ルールを参照し、受信したイベントを処理ルールに基づいて処理する。処理部410は、イベント処理結果をアプリケーション500に送信する。
FIG. 7 is a block diagram showing the configuration of the processing apparatus 400 shown in FIG. As illustrated in FIG. 7, the processing device 400 includes a processing unit 410 and a processing
処理ルール記憶部420は、処理ルールを記憶する。処理ルール記憶部420に処理ルールが記憶されることを、以下、「処理ルールが設定される」と記載する。処理ルールは、ルール設定装置600により設定される。
The processing
処理装置400に設定される処理ルールは、例えば、”処理ルール1:「受信したイベントに含まれる温度の値が30℃(セ氏、以下同様)を超えていたら、冷房(アプリケーション500)に対して起動命令を出す」”というような単純なルールである。処理ルールは、処理装置400に複合イベント処理(CEP: Complex Event Processing)の実行を要求するものであってもよい。複合イベント処理とは、複数のイベントのパターンを検出し、それら複数のイベントの情報に基づいて行う処理である。発明の理解を容易にするため、このような処理ルールの具体例を下記に2つ示す。なお、処理ルール2と処理ルール3において、DevIDは、イベント送信源200の識別子を示す。
The processing rule set in the processing device 400 is, for example, “processing rule 1:“ if the temperature value included in the received event exceeds 30 ° C. (Celsius, the same applies hereinafter), the cooling (application 500) The start rule is a simple rule such as “”. The processing rule may request the processing device 400 to execute complex event processing (CEP). What is complex event processing? In order to facilitate the understanding of the invention, two specific examples of such processing rules are shown below, in which a plurality of event patterns are detected and performed based on information on the plurality of events. In the
・処理ルール2:「IF (DevID=11) and (DevID=12) THEN 温度の平均値を算出」、処理ルール2によれば、処理装置400は、DevID=11のイベントとDevID=12のイベントとを受信したら、それらのイベントに含まれる温度の平均値を算出する。
Processing rule 2: “IF (DevID = 11) and (DevID = 12) THEN Calculate the average value of THEN temperature”, according to
・処理ルール3:「IF (DevID=11) → (DevID=12) within 10s THEN 電流値の平均値を算出」、
処理ルール3によれば、処理装置400は、DevID=11のイベントとDevID=12のイベントとをこの順番で10秒以内に受信したら、それらのイベントに含まれる電流値の平均値を算出する。・ Processing rule 3: “IF (DevID = 11) → (DevID = 12) within 10s THEN Calculate the average value of current values”,
According to the
処理装置400は、このような複雑な処理ルールに基づいた処理を実行するために、処理ルールとイベントとのマッチングの中間状態(ステート)を管理する機能を具備していてもよい。中間状態(ステート)とは、例えば処理ルール2または処理ルール3における、DevID=11のイベントを検出したあと、DevID=12のイベントの検出を待っているような状態である。
The processing device 400 may have a function of managing an intermediate state (state) of matching between a processing rule and an event in order to execute processing based on such a complicated processing rule. The intermediate state (state) is a state in which, for example, after detecting an event with DevID = 11 in
図8は、図1に示す負荷分散装置100の構成を示すブロック図である。図8に示すように、負荷分散装置100は、取得部110と、フローテーブル記憶部120と、算出部130と、更新部140とを備える。
FIG. 8 is a block diagram showing a configuration of the
取得部110は、振り分け装置300から転送状況を取得する。 The acquisition unit 110 acquires the transfer status from the distribution device 300.
フローテーブル記憶部120は、取得部110が取得した転送状況を記憶する。 The flow table storage unit 120 stores the transfer status acquired by the acquisition unit 110.
算出部130は、フローテーブル記憶部120を参照し、振り分け装置300がイベントを転送する際に、振り分け装置300に発生する負荷を算出する。振り分け装置300の負荷を示す情報を、以降負荷情報と記載する。算出部130の動作の詳細は後述する。算出部130が算出する負荷は、例えば、振り分け装置300のCPU(Central Processing Unit)負荷、メモリの負荷またはネットワーク負荷などである。 The calculation unit 130 refers to the flow table storage unit 120 and calculates a load generated in the distribution device 300 when the distribution device 300 transfers an event. Information indicating the load of the distribution device 300 is hereinafter referred to as load information. Details of the operation of the calculation unit 130 will be described later. The load calculated by the calculation unit 130 is, for example, a CPU (Central Processing Unit) load, a memory load, or a network load of the distribution device 300.
更新部140は、算出部130が算出した負荷に基づいて、送信先決定ルールを更新する。更新部140は、更新された送信先決定ルールを、イベント送信源200が有する送信先決定ルール記憶部220に上書き(更新)する。
The update unit 140 updates the transmission destination determination rule based on the load calculated by the calculation unit 130. The update unit 140 overwrites (updates) the updated transmission destination determination rule in the transmission destination determination rule storage unit 220 included in the
図9は、フローテーブル記憶部120が記憶しているフローテーブルの一例を示す図である。図9に示すように、係るフローテーブルには、それぞれの振り分け装置300(図9に示す例では、振り分け装置300Aと300B)から受信した転送状況が記憶される。
FIG. 9 is a diagram illustrating an example of a flow table stored in the flow table storage unit 120. As shown in FIG. 9, the flow table stores the transfer status received from each distribution device 300 (in the example shown in FIG. 9,
図10は、算出部130が算出する負荷の一例を示す図である。 FIG. 10 is a diagram illustrating an example of a load calculated by the calculation unit 130.
算出部130は、受信状況と送信状況との両方を用いて、振り分け装置300の負荷を算出する。 The calculation unit 130 calculates the load of the distribution device 300 using both the reception status and the transmission status.
振り分け装置300がイベント送信源200から処理装置400へとイベントを転送する際に、振り分け装置300に発生する負荷は、下記の3つに分けて考えられる。
When the distribution device 300 transfers an event from the
1)イベントを受信する際にかかる負荷、
2)イベントと振り分けルールとをマッチングする際にかかる負荷、
3)イベントを送信する際にかかる負荷。1) Load on receiving events,
2) The load applied when matching an event with a distribution rule,
3) Load applied when sending an event.
算出部130は、振り分け装置300の負荷を、例えば以下のように算出する。 The calculation unit 130 calculates the load on the distribution device 300 as follows, for example.
(振り分け装置300が特定のイベント送信源200から受信したイベントを転送する際に、振り分け装置300にかかる負荷)=受信イベント数×(イベント単位受信負荷+イベント単位検索負荷)+送信イベント数×(イベント単位送信負荷)
イベント単位受信負荷は、例えば、一つのイベントを受信する処理に関する処理負荷である。また、イベント単位検索負荷は、例えば、一つのイベントに対する検索処理に関する処理負荷である。また、イベント単位送信負荷は、例えば、一つのイベントに対する送信処理に関する処理負荷である。
具体例を用いて説明する。イベント単位受信負荷=10、イベント単位検索負荷=10、イベント単位送信負荷=10とする。図6または図9に示した転送状況に基づいて、算出部130が振り分け装置300Aの負荷を算出すると、下記のようになる。(Load applied to distribution device 300 when distribution device 300 transfers an event received from a specific event transmission source 200) = number of received events × (event unit reception load + event unit search load) + number of transmission events × ( Event unit transmission load)
The event unit reception load is, for example, a processing load related to a process of receiving one event. Further, the event unit search load is, for example, a processing load related to search processing for one event. The event unit transmission load is, for example, a processing load related to transmission processing for one event.
This will be described using a specific example. Event unit reception load = 10, event unit search load = 10, and event unit transmission load = 10. When the calculation unit 130 calculates the load of the
振り分け装置300Aが、イベント送信源200Aから受信したイベントを処理装置400に転送する負荷(負荷A):負荷A=200×(10+10)+100×(10)=5000。
The load (load A) for the
振り分け装置300Aが、イベント送信源200Bから受信したイベントを処理装置400に転送する負荷(負荷B):負荷B=100×(10+10)+100×(10)=3000。
The load (load B) for the
振り分け装置300Aが、イベント送信源200Cから受信したイベントを処理装置400に転送する負荷(負荷C):負荷C=50×(10+10)+0×(10)=1000。
The load (load C) at which the
なお、算出部130は、転送状況に含まれる受信状況または送信状況と、マッチング率とに基づいて、振り分け装置300の負荷を算出してもよい。
算出部130は例えば、振り分け装置300の負荷を、以下のように算出してもよい。Note that the calculation unit 130 may calculate the load of the distribution device 300 based on the reception status or transmission status included in the transfer status and the matching rate.
For example, the calculation unit 130 may calculate the load of the distribution device 300 as follows.
(振り分け装置300が特定のイベント送信源200から受信したイベントを転送する際に、振り分け装置300にかかる負荷)=(ルールマッチ時の処理負荷×ルールマッチ率+ルールアンマッチ時の処理負荷×(1−ルールマッチ率))×イベント量。 (Load applied to the distribution device 300 when the distribution device 300 transfers an event received from the specific event transmission source 200) = (processing load at the time of rule matching × rule matching rate + processing load at the time of rule unmatching × (1 -Rule match rate)) x event amount.
図10に示すように、振り分け装置300Aには、イベント送信源200Aから受信したイベントを転送するために、負荷の値として5000なる負荷がかかっていることが算出される。振り分け装置300Aには、イベント送信源200Bから受信したイベントを転送するために、負荷の値として3000なる負荷がかかっていることが算出される。振り分け装置300Aには、イベント送信源200Cから受信したイベントを転送するために、負荷の値として1000なる負荷がかかっていることが算出される。振り分け装置300Bには、イベント送信源200Dから受信したイベントを転送するために、負荷の値として1400なる負荷がかかっていることが算出される。
As shown in FIG. 10, it is calculated that a load of 5000 is applied to the
振り分け装置300Aにかかる負荷の値の合計は、イベント送信源200Aによる負荷の値と、イベント送信源200Bによる負荷の値と、イベント送信源200Cによる負荷の値との和に基づいて算出される。すなわち、振り分け装置300Aにかかる負荷の値の合計は、5000+3000+1000=9000と算出される。同様に、振り分け装置300Bにかかる負荷の値の合計は、イベント送信源200Dによる負荷の値に基づいて、1400と算出される。
The total load value applied to
負荷分散装置100が行う負荷分散を説明する。図11は、更新後の送信先決定ルールの一例を示す図である。図2と図11とを比較するとわかるように、送信先決定ルール2が更新されている。すなわち、イベント送信源200Bから発生したイベントの送信先が、振り分け装置300Aから振り分け装置300Bに更新されている。
Load distribution performed by the
図12は、負荷分散装置100が送信先決定ルールを更新した後の、負荷の状況を説明するための図である。図10と図12とを比較するとわかるように、イベント送信源200Bから発生したイベントの送信先が、振り分け装置300Aから振り分け装置300Bに更新されている。これにより、振り分け装置300Aにかかる負荷の合計は、イベント送信源200Aによる負荷と、イベント送信源200Cによる負荷との合計、すなわち5000+1000=6000と算出される。振り分け装置300Bにかかる負荷の合計は、イベント送信源200Bによる負荷と、イベント送信源200Dによる負荷との合計、すなわち、3000+1400=4400と算出される。
FIG. 12 is a diagram for explaining a load situation after the
図10に示す負荷調整前の状況と比較して、図12に示す負荷調整後の状況においては、振り分け装置300Aと振り分け装置300Bとの負荷が平準化されている。
Compared with the situation before the load adjustment shown in FIG. 10, in the situation after the load adjustment shown in FIG. 12, the loads on the
図13は、負荷分散装置100のハードウェア構成の一例を示す図である。
FIG. 13 is a diagram illustrating an example of a hardware configuration of the
図13に示した負荷分散装置(コンピュータ)100のハードウェアは、CPU1、メモリ2、記憶装置3、通信インタフェース(I/F)4を備える。負荷分散装置100は、入力装置5または出力装置6を備えていてもよい。負荷分散装置100の機能は、例えばCPU1が、メモリ2に読み出されたコンピュータプログラム(ソフトウェアプログラム、以下単に「プログラム」と記載する)を実行することにより実現される。実行に際して、CPU1は、通信インタフェース4、入力装置5および出力装置6を適宜制御する。
The hardware of the load balancer (computer) 100 shown in FIG. 13 includes a
尚、本実施形態および後述する各実施形態を例として説明される本発明は、係るプログラムが格納されたコンパクトディスク等の不揮発性の記憶媒体8によっても構成される。記憶媒体8が格納するプログラムは、例えばドライブ装置7により読み出される。 Note that the present invention, which will be described by taking this embodiment and each embodiment described later as an example, is also configured by a nonvolatile storage medium 8 such as a compact disk in which such a program is stored. The program stored in the storage medium 8 is read by the drive device 7, for example.
負荷分散装置100が実行する通信は、例えばOS(Operating System)が提供する機能を使ってアプリケーションプログラムが通信インタフェース4を制御することによって実現される。入力装置5は、例えばキーボード、マウスまたはタッチパネルである。出力装置6は、例えばディスプレイである。負荷分散装置100は、2つ以上の物理的に分離した装置が有線または無線で接続されることによって構成されていてもよい。
The communication executed by the
図13に示すハードウェア構成例は、後述する各実施形態にも適用可能である。なお、負荷分散装置100は専用の装置であってもよい。
The hardware configuration example shown in FIG. 13 is also applicable to each embodiment described later. The
次に、第1の実施形態にかかる負荷分散装置100の動作を、図面を用いて説明する。
Next, the operation of the
図14は、第1の実施形態にかかる負荷分散装置100の動作の一例を示すフローチャートである。取得部110は、個々の振り分け装置(300A、300B…)から転送状況を取得する(S101)。取得部110は、取得した転送状況を、フローテーブル記憶部120に記憶する(S102)。算出部130は、フローテーブル記憶部120を参照し、イベントを転送する際に振り分け装置300に発生する負荷を算出する(S103)。更新部140は、算出部が算出した負荷に基づいて、送信先決定ルールを更新する(S104)。更新部140は、更新された送信先決定ルールをイベント送信源200に上書きする(S105)。
FIG. 14 is a flowchart illustrating an example of the operation of the
図14を用いて説明した負荷分散装置100の動作は、あくまで一例に過ぎない。例えば、図14に示すフローチャートにより表される処理の一部について、実行される順序の一部を、可能な範囲で入れ替えてもよい。
The operation of the
図15は、図8に示す算出部130の動作の一例を示すフローチャートである。算出部130は、定期的に、あるいは、更新部140からの要求を受け付けて、負荷の算出を開始する(S201)。算出部130は、負荷算出の対象となる振り分け装置300iに着目する(S202)。算出部130は、振り分け装置300iが受信するイベントの送信元であるイベント送信源200jに着目する(S203)。算出部130は、フローテーブル記憶部120を参照し、振り分け装置300iがイベント送信源200jから受信したイベントに関する行を読み出す。算出部130は、読み出した行に基づいて、振り分け装置300iがイベント送信源200jから受信したイベントを転送する際にかかる負荷を算出する(S204)。算出部130は、振り分け装置300iが受信したイベントの送信源である全てのイベント送信源200について、負荷を算出する(S205)。算出部130は、フローテーブル記憶部120が記憶している全ての振り分け装置300に対して負荷を算出する(S206)。
FIG. 15 is a flowchart illustrating an example of the operation of the calculation unit 130 illustrated in FIG. The calculation unit 130 starts load calculation periodically or in response to a request from the update unit 140 (S201). The calculation unit 130 pays attention to the distribution device 300i that is the target of load calculation (S202). The calculation unit 130 focuses on the event transmission source 200j that is the transmission source of the event received by the distribution device 300i (S203). The calculation unit 130 refers to the flow table storage unit 120, and reads out a row related to the event received by the distribution device 300i from the event transmission source 200j. The calculation unit 130 calculates a load applied when the distribution device 300i transfers an event received from the event transmission source 200j based on the read row (S204). The calculation unit 130 calculates loads for all
図15を用いて説明した算出部130の動作は、あくまで一例に過ぎない。例えば、どの振り分け装置300の負荷が重いか予めわかっている場合には、算出部130は、最も負荷が重い振り分け装置300の負荷のみ算出する、としてもよい。 The operation of the calculation unit 130 described with reference to FIG. 15 is merely an example. For example, when it is known in advance which distribution device 300 has a heavy load, the calculation unit 130 may calculate only the load of the distribution device 300 having the heaviest load.
図16は、図8に示す更新部140の動作の一例を説明するフローチャートである。 FIG. 16 is a flowchart illustrating an example of the operation of the updating unit 140 illustrated in FIG.
更新部140は、定期的に、または負荷調整の要求を受けて、負荷調整の動作を開始する(S301)。更新部140は、現状、振り分け装置300の負荷が十分に分散されているかどうかを判断する(S302)。S302のステップにおける判断基準は、たとえば、最も負荷が重い振り分け装置300の負荷が、所定の閾値を超えているか否かとしてもよい。また、S302のステップにおける判断基準は、たとえば、最も負荷が重い振り分け装置300の負荷と、最も負荷が軽い振り分け装置300の負荷との差分が、所定の閾値を超えているか否かとしてもよい。上記2つの条件が共に満たされていることを、S302のステップにおける判断基準としてもよい。 更新部140が、現状、負荷が十分に分散されていないと判断した場合(S302においてNO)、更新部140は、負荷調整の際の基準値を算出する(S303)。負荷調整の際の基準値は例えば、以下のように算出される。 The update unit 140 starts a load adjustment operation periodically or upon receiving a load adjustment request (S301). The update unit 140 determines whether the load on the distribution device 300 is sufficiently distributed at present (S302). The determination criterion in step S302 may be, for example, whether or not the load of the distribution device 300 with the heaviest load exceeds a predetermined threshold. In addition, the determination criterion in step S302 may be, for example, whether or not the difference between the load of the distribution device 300 having the heaviest load and the load of the distribution device 300 having the lightest load exceeds a predetermined threshold. The fact that both of the above two conditions are satisfied may be used as a determination criterion in step S302. If the update unit 140 determines that the load is not sufficiently distributed at present (NO in S302), the update unit 140 calculates a reference value for load adjustment (S303). The reference value at the time of load adjustment is calculated as follows, for example.
(基準値)=(最も負荷が重い振り分け装置の負荷+最も負荷が軽い振り分け装置の負荷)/2。 (Reference value) = (load of the sorting device with the heaviest load + load of the sorting device with the lightest load) / 2.
更新部140は、最も負荷が重い振り分け装置300について、当該振り分け装置300が受信するイベントの送信元であるイベント送信源200のそれぞれに対して、当該イベント送信源200から受信するイベントを処理装置400に転送する負荷を算出する(S304)。S304のステップにおいて、更新部140は、算出部130により既に算出された値を取得してもよいし、算出部130に算出要求を出してもよい。
For the distribution device 300 with the heaviest load, the update unit 140 sends an event received from the
更新部140は、最も負荷が重い振り分け装置300において、最も重い負荷を発生させるイベント送信源の負荷の値が、S303で算出した基準値の値を超えているか否かを判定する(S305)。S305においてNOである場合、更新部140は、当該最も重い負荷を発生させるイベント送信源のイベント送信先が、最も負荷が重い振り分け装置300から、最も負荷が軽い振り分け装置300へと変更されるよう、送信先決定ルールを更新する(S306)。 The update unit 140 determines whether or not the load value of the event transmission source that generates the heaviest load exceeds the reference value calculated in S303 in the distribution device 300 having the heaviest load (S305). If NO in S305, the updating unit 140 changes the event transmission destination of the event transmission source that generates the heaviest load from the distribution device 300 having the heaviest load to the distribution device 300 having the lightest load. The transmission destination determination rule is updated (S306).
なお、S302においてYESである場合、更新部140は一定時間待機する(S307)。また、S305においてYESである場合、更新部140は負荷調整の動作を終了する。 If YES in S302, the updating unit 140 waits for a certain time (S307). If YES in S305, the updating unit 140 ends the load adjustment operation.
図16を用いて説明した更新部140の動作は、あくまで更新部140の動作の一例に過ぎない。 The operation of the update unit 140 described with reference to FIG. 16 is merely an example of the operation of the update unit 140.
第1の実施形態にかかる負荷分散装置100が奏する効果を説明する。
The effect which the
第1の実施形態にかかる負荷分散装置100は、取得部110と更新部140とを備える。取得部110は、イベント送信源200から振り分け装置300が所定期間内に受信するイベントの、数量または情報サイズを表す情報である受信状況、および、イベント送信源200から振り分け装置300が所定期間内に受信して処理装置400に送信するイベントの、数量または情報サイズを表す情報である送信状況を取得する。更新部140は、受信状況および送信状況に基づいて、振り分け装置300がイベント送信源200から処理装置400へイベントを転送する際に振り分け装置300にかかる負荷が、複数の振り分け装置300の間で平準化されるように、送信先決定ルールを更新する。
The
かかる構成により、第1の実施形態にかかる負荷分散装置100は、精度の高い負荷分散を実現することができる。
With this configuration, the
その理由は、算出部130が、振り分け装置300の負荷を、受信状況と送信状況との両方に基づいて算出するからである。 The reason is that the calculation unit 130 calculates the load on the distribution device 300 based on both the reception status and the transmission status.
振り分け装置300は、イベント送信源200から受信したイベントのうち、振り分けルールにマッチングしたイベントは処理装置400に送信し、振り分けルールにマッチングしないイベントは破棄する。これにより、振り分け装置300が受信するイベントが同一であっても、振り分け装置300が当該イベントを破棄する場合と、振り分け装置300が当該イベントを転送する場合とでは、振り分け装置300にかかる負荷は異なる。
Of the events received from the
なぜならば、振り分け装置300がイベントを転送する場合、振り分け装置300には、イベント受信処理にかかる負荷、ルールマッチング処理にかかる負荷、および、イベント送信処理にかかる負荷の3つの負荷がかかる。それに対し、振り分け装置300がイベントを破棄する場合、振り分け装置300には、イベントを受信する負荷と、ルールマッチング処理にかかる負荷の2つの負荷しかかからないためである。 This is because when the distribution device 300 transfers an event, the distribution device 300 is subjected to three loads: a load for event reception processing, a load for rule matching processing, and a load for event transmission processing. On the other hand, when the distribution device 300 discards the event, the distribution device 300 only takes two loads, a load for receiving the event and a load for the rule matching process.
このように、第1の実施形態にかかる負荷分散装置100は、算出部130が、受信状況と送信状況との両方を考慮して振り分け装置300の負荷を算出するので、より精度の高い負荷分散を実現することができる。言い換えると、第1の実施形態にかかる負荷分散装置100は、イベントのマッチング率を考慮して振り分け装置300の負荷を算出するので、より精度の高い負荷分散を実現することができる。
As described above, in the
[変形例その1]
振り分け装置300が有する振り分けルール記憶部340は、例えば以下のような振り分けルールを記憶していてもよい。[Modification 1]
The distribution
振り分けルール:振り分け装置300が受信したイベントに含まれる緯度と経度の値が、所定の範囲内にある場合、振り分け装置300は、当該イベントを処理装置400Cおよび処理装置400Dに送信する。
Distribution rule: When the latitude and longitude values included in the event received by the distribution device 300 are within a predetermined range, the distribution device 300 transmits the event to the
このような振り分けルールによって、振り分け装置300は、イベント送信源200から受信した一つのイベントを、複数の処理装置400に送信する。このような振り分けルールが設定されている場合、振り分け装置300が、受信した1つのイベントをいくつの処理装置400に転送するかに応じて、振り分け装置300にかかる負荷は異なる。
According to such a distribution rule, the distribution device 300 transmits one event received from the
このような振り分けルールが振り分け装置300に設定されていても、算出部130は、振り分け装置300の負荷を高い精度で算出することができる。その理由は、算出部130は、振り分け装置300の受信状況と送信状況との両方を考慮して振り分け装置300の負荷を算出するからである。 Even if such a distribution rule is set in the distribution apparatus 300, the calculation unit 130 can calculate the load of the distribution apparatus 300 with high accuracy. The reason is that the calculation unit 130 calculates the load of the distribution device 300 in consideration of both the reception status and the transmission status of the distribution device 300.
[変形例その2]
算出部130は、振り分け装置300から、単位情報サイズあたり受信する際にかかる負荷(以下、情報サイズ単位受信負荷と記載)と、単位情報サイズあたり送信する際にかかる負荷(以下、情報サイズ単位送信負荷と記載)を取得してもよい。[Variation 2]
The calculation unit 130 receives a load per unit information size received from the distribution device 300 (hereinafter referred to as an information size unit reception load) and a load required per unit information size (hereinafter referred to as information size unit transmission). May be acquired).
算出部130は、例えば下記に示すような方法で、振り分け装置300の負荷を算出してもよい。 For example, the calculation unit 130 may calculate the load of the distribution device 300 by a method as described below.
(振り分け装置の負荷)=(受信したイベントの情報サイズ×情報サイズ単位受信負荷)+(受信したイベント数×イベント単位検索負荷)+(送信したイベントの情報サイズ×情報サイズ単位送信負荷)。 (Load of distribution device) = (information size of received event × reception load in information size) + (number of received events × event load in search) + (information size of transmitted event × information size transmission load)
振り分け装置300の受信処理および送信処理にかかる負荷は、イベント数よりもむしろイベントの情報サイズに依存する場合が多い。算出部130がこのように振り分け装置300の負荷を算出することで、第1の実施形態にかかる負荷分散装置100は、さらに精度の高い負荷分散を実現できる。
In many cases, the load applied to the reception processing and transmission processing of the distribution device 300 depends on the information size of the event rather than the number of events. When the calculation unit 130 calculates the load of the distribution device 300 in this way, the
<第2の実施形態>
次に、上述した第1の実施形態に係る負荷分散装置100およびイベント処理システム1000を基本とする第2の実施形態について説明する。<Second Embodiment>
Next, a second embodiment based on the
図17は、第2の実施形態にかかる負荷分散装置101を含むイベント処理システム1001の構成を示すブロック図である。図1に示した構成と実質的に同一の構成には同一の符号が付されているので説明は省略する。図17に示すように、第2の実施形態にかかるイベント処理システム1001は、負荷分散装置100に代えて負荷分散装置101を含む。また、第2の実施形態にかかるイベント処理システム1001は、送信先管理装置700を更に含み、イベント送信源200に代えてイベント送信源201を含む。
FIG. 17 is a block diagram illustrating a configuration of an event processing system 1001 including the
送信先管理装置700は、図2に示すような送信先決定ルールを記憶する。送信先管理装置700は、イベント処理システム1001が含むイベント送信源201全てに関する送信先決定ルールを記憶していることが好ましい。例えば、送信先管理装置700は、図2に示す送信先決定ルール1〜4を記憶している。
The transmission
送信先管理装置700は、イベント送信源201からの要求に応じて、当該イベント送信源201がイベントを送信する振り分け装置300のアドレスを返答する。
In response to a request from the event transmission source 201, the transmission
図18は、図17に示す負荷分散装置101の構成を示すブロック図である。
FIG. 18 is a block diagram illustrating a configuration of the
負荷分散装置101は、更新部140に代えて更新部141を備える。更新部141は、図16に示すような方法で送信先決定ルールを更新する。更新部141は、例えば、送信先決定ルールを、図2に示した例から図11に示した例へと更新する。更新部141は、更新した決定先送信ルールを、送信先管理装置700に上書きする。
The
図19は、図17に示すイベント送信源201の構成を示すブロック図である。図19に示すように、イベント送信源201は、送信先決定ルール記憶部220に代えて、送信先取得部240を有する。送信先取得部240は、送信先管理装置700のアドレスを記憶している。送信先取得部240は、イベントの送信先を、送信先管理装置700に問い合わせる。送信先取得部240は、送信先管理装置700から取得したアドレスに、生成したイベントを送信する。
FIG. 19 is a block diagram showing the configuration of the event transmission source 201 shown in FIG. As illustrated in FIG. 19, the event transmission source 201 includes a transmission
第2の実施形態にかかる負荷分散装置101が奏する効果を説明する。
The effect which the
第2の実施形態にかかる負荷分散装置101は、イベント送信源201が記憶する情報を直接書き換えることなく、振り分け装置300の負荷分散を実現することができる。
The
第2の実施形態にかかる負荷分散装置101は、送信先管理装置700が記憶している情報を更新するだけで、すべてのイベント送信源201のイベントの送信先を一括で更新できる。よって、第2の実施形態にかかる負荷分散装置101は、イベント処理システム1001に含まれるイベント送信源201の数量が多い場合には特に、イベント送信源201のイベント送信先を更新する手間を省くことができる。
The
<第3の実施形態>
次に、上述した第1の実施形態を基本とする第3の実施形態について説明する。第3の実施形態は、第2の実施形態に対しても適用可能である。<Third Embodiment>
Next, a third embodiment based on the above-described first embodiment will be described. The third embodiment can also be applied to the second embodiment.
図20は、第3の実施形態にかかる負荷分散装置102を含むイベント処理システム1002の構成を示すブロック図である。図1に示した構成と実質的に同一の構成には同一の符号が付されているので説明は省略する。図20に示すように、第3の実施形態にかかるイベント処理システム1002は、負荷分散装置100に代えて負荷分散装置102を含む。また、第3の実施形態にかかるイベント処理システム1002は、イベント送信源200に代えてイベント送信源202を含む。また、第3の実施形態にかかるイベント処理システム1002は、振り分け装置300に代えて振り分け装置302を含む。イベント処理システム1002は、更に、複数のセンサー800を含んでいてもよい。
FIG. 20 is a block diagram illustrating a configuration of an event processing system 1002 including the
図21は、図20に示すイベント送信源202の構成を示すブロック図である。図21に示すように、イベント送信源202は、受信部250を更に有する。また、イベント送信源202は、送信先決定ルール記憶部220に代えて送信先決定ルール記憶部222を有し、送信部230に代えて送信部232を有する。第3の実施形態にかかるイベント送信源202は、第1の実施形態にかかるイベント送信源200とは異なり、必ずしもセンサー210を有している必要はない。イベント送信源202は、受信部250を有さずに、センサー210を有していてもよい。
FIG. 21 is a block diagram showing a configuration of
受信部250は、1つまたは複数のセンサー800から複数のイベントを受信する。 The receiving unit 250 receives a plurality of events from one or a plurality of sensors 800.
イベント送信源202は、自装置が有するセンサーにより、自らイベントを生成してもよい。
The
送信先決定ルール記憶部222は、送信先決定ルールを記憶する。 The transmission destination determination rule storage unit 222 stores transmission destination determination rules.
送信部232は、イベントの内容と送信先決定ルールとに基づいて、当該イベントを振り分け装置302に送信する。 The transmission unit 232 transmits the event to the distribution device 302 based on the event content and the transmission destination determination rule.
第3の実施形態にかかる送信先決定ルール記憶部222が記憶する送信先決定ルールの一例を、図22に示す。 An example of the transmission destination determination rule stored in the transmission destination determination rule storage unit 222 according to the third embodiment is shown in FIG.
図22に示すように、送信先決定ルール記憶部222は、送信先決定ルール5〜8を記憶している。図22に示すように、第3の実施形態にかかる送信先決定ルールは、送信するイベントの内容(属性値)と送信先の振り分け装置とを関連付けたルールである。 As illustrated in FIG. 22, the transmission destination determination rule storage unit 222 stores transmission destination determination rules 5 to 8. As illustrated in FIG. 22, the transmission destination determination rule according to the third embodiment is a rule that associates the content (attribute value) of the event to be transmitted with the distribution device of the transmission destination.
発明の理解を容易にするため、第3の実施形態にかかるイベントは、位置情報と、当該位置情報が表す位置における気温と、を含む情報とした場合について、以下、具体的に説明する。 In order to facilitate understanding of the invention, the case where the event according to the third embodiment is information including position information and the temperature at the position represented by the position information will be specifically described below.
図22に示す送信先決定ルールは、イベントに含まれる第1の属性値(気温の値)と、第2の属性値(緯度の値および経度の値)とに基づいて、送信先の振り分け装置302を決定するルールである。図22に示す記号"*"は、ワイルドカードを示す。例えば図22に示す送信先決定ルール5は、イベントに含まれる緯度の値と経度の値とに関わらず、イベントに含まれる気温の値が10℃(摂氏)〜15℃であるイベントは、振り分け装置302Aに送信されることを表している。
The transmission destination determination rule shown in FIG. 22 is based on the first attribute value (temperature value) and the second attribute value (latitude value and longitude value) included in the event. This is a rule for determining 302. The symbol “*” shown in FIG. 22 indicates a wild card. For example, according to the transmission destination determination rule 5 shown in FIG. 22, an event whose temperature value is 10 ° C. (degrees Celsius) to 15 ° C. is distributed regardless of the latitude value and longitude value included in the event. It is transmitted to the
図23は、図20に示す振り分け装置302の構成を示すブロック図である。図4に示した構成と実質的に同一の構成には同一の符号が付されているので説明は省略する。図23に示すように、振り分け装置302は、フロー計測部350に代えて、フロー計測部352を有する。
FIG. 23 is a block diagram showing a configuration of the sorting apparatus 302 shown in FIG. Components that are substantially the same as those shown in FIG. As illustrated in FIG. 23, the distribution device 302 includes a
フロー計測部352は、自装置(振り分け装置302)が所定時間内に受信する、特定の内容のイベントの、転送状況を計測する。ここで、「特定の内容」とは、イベントに含まれる属性値が特定の条件を満たしていることをいう。「特定の内容」とは、例えば、イベントに含まれる属性値が、送信先決定ルールが規定する所定の範囲に含まれていることをいう。「特定の内容」とは、例えば、イベントに含まれる属性値が、送信先決定ルールが規定する所定の値と一致していることをいう。「特定の内容」とは、例えば、イベントに含まれる属性値が、送信先決定ルールが規定する所定の値と所定の関係(例えば大小関係など)を有していることをいう。振り分け装置302Aが有するフロー計測部352Aが計測する転送状況を例に、転送状況をより詳細に説明する。
The
図24は、振り分け装置302Aが有するフロー計測部352Aが計測する転送状況の一例を示す図である。図24に示すように、第3の実施形態にかかる転送状況は、振り分け装置302を識別する情報と、受信したイベントの特定の内容(属性値)を表す情報と、受信状況を示す情報と、送信状況を示す情報とが関連づけされた情報である。
FIG. 24 is a diagram illustrating an example of a transfer state measured by the flow measurement unit 352A included in the
図24に示す転送状況は、振り分け装置302Aが、所定の期間内に、10℃〜15℃の範囲に属する値を含むイベントを200回受信し、当該受信したイベントの情報サイズの総量は50MBであることを示す。また、図24に示す転送状況は、振り分け装置302Aが、所定の期間内に、10℃〜15℃の範囲に属する値を含むイベントを処理装置400に100回送信したことを示す。10℃〜15℃の範囲に属する値を含むイベントのマッチング率は、100×(100(送信回数)/200(受信回数))=50%である。
In the transfer status shown in FIG. 24, the
図24に示す転送状況は、フロー計測部352が、送信先決定ルール5〜8と同じ温度幅(10℃から30℃まで5℃単位)で計測した場合の転送状況である。フロー計測部352は、任意の属性値幅で転送状況を計測してもよい。例えばフロー計測部352は、2℃単位で、転送状況を測定してもよい。
The transfer status illustrated in FIG. 24 is a transfer status when the
図25は、図20に示す負荷分散装置102の構成を示すブロック図である。図8に示した構成と実質的に同一の構成には同一の符号が付されているので説明は省略する。図25に示すように、負荷分散装置102は、算出部130に代えて算出部132を、更新部140に代えて更新部142を備える。
25 is a block diagram showing a configuration of the
図26は、第3の実施形態におけるフローテーブル記憶部120が記憶する情報の一例を示す図である。図26に示すように、フローテーブルは、それぞれの振り分け装置302(図26に示す例では、振り分け装置302Aと302B)から受信した転送状況を記憶している。
FIG. 26 is a diagram illustrating an example of information stored in the flow table storage unit 120 according to the third embodiment. As shown in FIG. 26, the flow table stores the transfer status received from each sorting apparatus 302 (the sorting
算出部132は、フローテーブル記憶部120を参照し、振り分け装置302がイベントを転送する際に、振り分け装置302に発生する負荷を算出する。第3の実施形態にかかる算出部132を、第1の実施形態にかかる算出部130と比較して説明する。 The calculation unit 132 refers to the flow table storage unit 120 and calculates a load generated in the distribution device 302 when the distribution device 302 transfers an event. The calculation unit 132 according to the third embodiment will be described in comparison with the calculation unit 130 according to the first embodiment.
第1の実施形態にかかる算出部130は、振り分け装置302が、特定のイベント送信源(例えばイベント送信源200A)から所定期間内に受信するイベントを処理装置400に転送する際に、当該振り分け装置に発生する負荷を算出する。
The calculation unit 130 according to the first embodiment, when the distribution device 302 transfers an event received from a specific event transmission source (for example, the
これに対し第3の実施形態にかかる算出部132は、振り分け装置302が所定期間内に受信した特定の内容のイベント(例えば温度の値が10℃〜15℃であるイベント)を、イベント送信源202から処理装置400に転送する際に、当該振り分け装置に発生する負荷を算出する。 On the other hand, the calculation unit 132 according to the third embodiment converts an event having a specific content (for example, an event whose temperature value is 10 ° C. to 15 ° C.) received by the distribution device 302 within a predetermined period into an event transmission source. When transferring from 202 to the processing device 400, the load generated in the sorting device is calculated.
図27は、算出部132の動作を説明するためのフローチャートである。算出部132は、定期的に、あるいは、更新部142からの要求を受け付けて、負荷の算出を開始する(S401)。算出部132は、負荷算出の対象となる振り分け装置302iに着目する(S402)。算出部132は、振り分け装置302iが受信する、特定の内容jを含むイベントに注目する(S403)。算出部132は、フローテーブル120を参照し、振り分け装置302iが受信した特定の内容jを含むイベントに関する行を読み出す。算出部132は、読み出した行に基づいて、振り分け装置302iが、特定の内容jを含むイベントを転送する際にかかる負荷を算出する(S404)。S404における算出部132の動作は、第1の実施形態で説明した算出部130の動作と同様である。算出部132は、振り分け装置302iに対して、フローテーブル120が記憶している全ての「特定の内容」の行について負荷を算出する(S405)。算出部132は、フローテーブル記憶部120が記憶している全ての振り分け装置302に対して負荷を算出する(S406)。 FIG. 27 is a flowchart for explaining the operation of the calculation unit 132. The calculation unit 132 starts calculating the load periodically or in response to a request from the update unit 142 (S401). The calculation unit 132 pays attention to the distribution device 302i that is the target of load calculation (S402). The calculation unit 132 pays attention to the event including the specific content j received by the distribution device 302i (S403). The calculating unit 132 refers to the flow table 120 and reads a line relating to an event including the specific content j received by the distribution device 302i. Based on the read row, the calculation unit 132 calculates a load applied when the sorting device 302i transfers an event including the specific content j (S404). The operation of the calculation unit 132 in S404 is the same as the operation of the calculation unit 130 described in the first embodiment. The calculation unit 132 calculates loads for all “specific contents” rows stored in the flow table 120 with respect to the sorting apparatus 302i (S405). The calculation unit 132 calculates loads for all the sorting devices 302 stored in the flow table storage unit 120 (S406).
図27を用いて説明した算出部132の動作は、あくまで一例に過ぎない。例えば、どの振り分け装置302の負荷が重いか予め分かっている場合には、算出部132は、最も負荷が重い振り分け装置302の負荷のみ算出する、としてもよい。 The operation of the calculation unit 132 described with reference to FIG. 27 is merely an example. For example, when it is known in advance which distribution device 302 has a heavy load, the calculation unit 132 may calculate only the load of the distribution device 302 having the heaviest load.
図28は、算出部132が、図26に示す情報に基づいて算出した負荷の一例である。 FIG. 28 shows an example of the load calculated by the calculation unit 132 based on the information shown in FIG.
図29は、更新部142の動作を説明するためのフローチャートである。第1の実施形態と実質的に同一のステップには同一の符号を付して、説明を省略する。更新部142は、最も負荷が重い振り分け装置302について、当該振り分け装置302が受信する特定の内容(特定の範囲の属性値)のイベントのそれぞれに対して、当該イベント送信源202から受信するイベントを処理装置400に転送する負荷を算出する(S504)。更新部142は、最も負荷が重い振り分け装置302において、最も重い負荷を発生させる特定の内容(特定の範囲の属性値)のイベントの負荷の値が、S303で算出した基準値の値を超えているか否かを判定する(S505)。S505においてNOである場合、更新部142は、当該最も重い負荷を発生させる特定の内容(特定の範囲の属性値)のイベントの送信先が、最も負荷が重い振り分け装置302から、最も負荷が軽い振り分け装置302へと変更されるよう、送信先決定ルールを更新する(S506)。
FIG. 29 is a flowchart for explaining the operation of the update unit 142. Steps substantially the same as those in the first embodiment are denoted by the same reference numerals, and description thereof is omitted. For the distribution device 302 with the heaviest load, the update unit 142 receives an event received from the
図30は、負荷分散装置102が更新した、送信先決定ルールの一例を示す図である。図22と図30とを比較するとわかるように、送信先決定ルール6が更新されている。すなわち、15℃〜20℃の範囲の温度の値を有するイベントの送信先が、振り分け装置302Aから振り分け装置302Bに更新されている。
FIG. 30 is a diagram illustrating an example of a transmission destination determination rule updated by the
図31は、負荷分散装置102が負荷調整を行った後の、負荷の状況を説明するための図である。図26と図31とを比較するとわかるように、図26に示す負荷調整前の状況と比較して、図31に示す負荷調整後の状況は、振り分け装置302Aと振り分け装置302Bとの負荷が平準化されている。
FIG. 31 is a diagram for explaining a load state after the
第3の実施形態にかかる負荷分散装置100が奏する効果を説明する。
The effect which the
第3の実施形態にかかる負荷分散装置102は、第1の実施形態にかかる負荷分散装置100と同様、精度の高い負荷分散を実現することができる。
The
<第4の実施形態>
次に、上述した第1の実施形態を基本とする第4の実施形態について説明する。第4の実施形態は、第1ないし第3の実施形態に対しても適用可能である。<Fourth Embodiment>
Next, a fourth embodiment based on the first embodiment described above will be described. The fourth embodiment can also be applied to the first to third embodiments.
図32は、第4の実施形態にかかる負荷分散装置103を含むイベント処理システム1003の構成を示すブロック図である。図32に示すように、イベント処理システム1003は、1つまたは複数のイベント送信源203と、複数の振り分け装置303と、負荷分散装置103とを含む。
FIG. 32 is a block diagram illustrating a configuration of an event processing system 1003 including the
振り分け装置303は、イベント送信源203から複数のイベントを受信し、前記受信した個々のイベントについて、当該イベントに含まれる情報と振り分けルールとに基づいて、当該イベントを破棄するか、あるいは、当該イベントを1つまたは複数の処理装置400に転送する。
The
イベント送信源203は、複数の振り分け装置303のうち、送信先決定ルールに基づいて決定される振り分け装置303に、イベントを送信する。
The event transmission source 203 transmits an event to the
負荷分散装置103は、取得部113と、更新部143とを備える。
The
取得部113は、振り分け装置303が所定期間内に受信するイベントの、数量または情報サイズを表す情報である受信状況を取得する。取得部113は、また、前記イベント送信源が所定期間内に送信するイベントの、数量または情報サイズを表す情報である送信状況を取得する。
The
更新部143は、受信状況および送信状況に基づいて、振り分け装置303がイベント生成源203から処理装置400へとイベントを転送する際に当該振り分け装置303にかかる負荷が、複数の振り分け装置303の間で平準化されるように、送信先決定ルールを更新する。
Based on the reception status and transmission status, the update unit 143 determines that the load applied to the
第4の実施形態にかかる負荷分散装置103によれば、イベント処理システム1003において、精度の高い負荷分散を実現することができる。
According to the
[各実施形態の変形例]
アプリケーション500は、イベントの処理結果を受けて物理的な動作を行うアクチュエーター(Actuator)であっても構わない。アプリケーション500は、コンピュータにインストールされたソフトウェアであってもよい。[Modification of each embodiment]
The application 500 may be an actuator that performs a physical operation in response to an event processing result. The application 500 may be software installed on a computer.
イベント送信源200、振り分け装置300、処理装置400、アプリケーション500、ルール設定装置600、送信先管理装置700、負荷分散装置100は、それぞれ専用の装置であってもよいし、ソフトウェアによって実現される機能であってもよい。
The
振り分けルール記憶部340は、必ずしも振り分け装置300の内部に実装される必要はない。振り分け装置300と振り分けルール記憶部340とが互いに対応していれば、振り分けルール記憶部340は振り分け装置300とネットワークを介して接続された装置に実装されていてもよい。
The distribution
処理ルール記憶部420は、必ずしも処理装置400の内部に実装される必要はない。処理装置400と処理ルール記憶部420とが互いに対応していれば、処理ルール記憶部420は処理装置400とネットワークを介して接続された装置に実装されていてもよい。
The processing
フローテーブル記憶部120は、必ずしも負荷分散装置100の内部に実装される必要はない。フローテーブル記憶部120は、負荷分散装置100とネットワークを介して接続された装置に実装されていてもよい。
The flow table storage unit 120 is not necessarily installed in the
取得部110は、必ずしも振り分け装置300から転送状況を直接取得する必要はない。例えば、振り分け装置300のオペレータが、それぞれの振り分け装置300から、転送状況を手動で、例えばUSB(Universal Serial Bus)メモリ等に収集したとする。取得部110は、当該USBメモリから転送状況を読み込んでもよい。取得部110は、負荷分散装置100が備える図示しない記憶装置から転送状況を読み込んでもよい。取得部110は、振り分け装置300から転送状況を受動的に受信してもよいし、定期的に振り分け装置300から転送状況をプルしてもよい。
The acquisition unit 110 is not necessarily required to directly acquire the transfer status from the distribution device 300. For example, it is assumed that the operator of the sorting device 300 manually collects the transfer status from each sorting device 300, for example, in a USB (Universal Serial Bus) memory. The acquisition unit 110 may read the transfer status from the USB memory. The acquisition unit 110 may read the transfer status from a storage device (not shown) included in the
上述の変形例は、他の実施形態にも適用可能である。 The above-described modified examples can be applied to other embodiments.
各ブロック図に示したブロック分けは、説明の便宜上から表された構成である。各実施形態を例に説明された本発明は、その実装に際して、各ブロック図に示した構成には限定されない。 The block division shown in each block diagram is a configuration shown for convenience of explanation. The present invention described by taking each embodiment as an example is not limited to the configuration shown in each block diagram in the implementation.
以上、本発明を実施するための形態について説明したが、上記実施の形態は本発明の理解を容易にするためのものであり、本発明を限定して解釈するためのものではない。本発明はその趣旨を逸脱することなく変更、改良され得ると共に、本発明にはその等価物も含まれる。 As mentioned above, although the form for implementing this invention was demonstrated, the said embodiment is for making an understanding of this invention easy, and is not for limiting and interpreting this invention. The present invention can be changed and improved without departing from the gist thereof, and the present invention includes equivalents thereof.
この出願は、2013年6月13日に出願された日本出願特願2013−124812を基礎とする優先権を主張し、その開示の全てをここに取り込む。 This application claims the priority on the basis of Japanese application Japanese Patent Application No. 2013-124812 for which it applied on June 13, 2013, and takes in those the indications of all here.
本発明は、イベント処理システムの負荷分散に用いることができる。 The present invention can be used for load balancing of an event processing system.
1 CPU
2 メモリ
3 記憶部
4 通信インタフェース
5 入力装置
6 出力装置
7 ドライブ装置
8 記憶媒体
100 負荷分散装置
101 負荷分散装置
102 負荷分散装置
103 負荷分散装置
110 取得部
113 取得部
120 フローテーブル記憶部
130 算出部
132 算出部
140 更新部
141 更新部
142 更新部
143 更新部
200 イベント送信源
201 イベント送信源
202 イベント送信源
203 イベント送信源
210 センサー
220 送信先決定ルール記憶部
222 送信先決定ルール記憶部
230 送信部
232 送信部
240 送信先取得部
250 受信部
300 振り分け装置
302 振り分け装置
303 振り分け装置
310 受信部
320 振り分けルール検索部
330 送信部
340 振り分けルール記憶部
350 フロー計測部
352 フロー計測部
360 処理量計測部
370 処理量ウェイト計算部
400 処理装置
410 処理部
420 処理ルール記憶部
500 アプリケーション
600 ルール設定装置
700 送信先管理装置
800 センサー
1000 イベント処理システム
1001 イベント処理システム
1002 イベント処理システム
1003 イベント処理システム
2000 デバイス
3000 コンテキスト依存振り分け器
4000 処理サーバ
5000 アプリケーション
6000 イベント処理分散制御装置
7000 コンテキスト非依存振り分け器1 CPU
2
Claims (10)
前記複数の振り分け装置のうち、送信先決定ルールに基づいて決定される振り分け装置に、イベントを送信する1つまたは複数のイベント送信源と、
を含むシステムと通信可能に接続され、
前記振り分け装置が所定期間内に受信するイベントの、数量または情報サイズを表す情報である受信状況、および、前記イベント送信源が所定期間内に送信するイベントの、数量または情報サイズを表す情報である送信状況を取得する取得手段と、
前記受信状況および送信状況に基づいて、前記振り分け装置が前記イベント生成源から前記処理装置へとイベントを転送する際に前記振り分け装置にかかる負荷が、前記複数の振り分け装置の間で平準化されるように、前記送信先決定ルールを更新する更新手段と、
を備える負荷分散装置。Receiving a plurality of events from an event transmission source, and discarding the event for each received event based on information included in the event and a distribution rule; A plurality of sorting devices to be transferred to the processing device;
Among the plurality of distribution devices, one or a plurality of event transmission sources for transmitting an event to a distribution device determined based on a transmission destination determination rule;
Communicatively connected to a system including
A reception status that is information indicating the quantity or information size of an event received by the distribution device within a predetermined period, and an information that indicates the quantity or information size of an event transmitted by the event transmission source within a predetermined period. An acquisition means for acquiring the transmission status;
Based on the reception status and transmission status, a load applied to the distribution device when the distribution device transfers an event from the event generation source to the processing device is leveled among the plurality of distribution devices. Updating means for updating the transmission destination determination rule,
A load balancer comprising:
前記受信状況および前記送信状況に基づいて前記負荷を算出する算出手段を更に備え、
前記更新手段は、前記負荷に基づいて前記送信先決定ルールを更新する
請求項1に記載の負荷分散装置。The load balancer is:
A calculation means for calculating the load based on the reception status and the transmission status;
The load distribution apparatus according to claim 1, wherein the update unit updates the transmission destination determination rule based on the load.
前記送信状況は、前記振り分け装置が所定期間内に送信するイベントの、情報サイズを表す情報を含み、
前記算出手段は、
前記受信したイベントの情報サイズに、情報を受信する際に前記振り分け装置にかかる単位情報サイズあたりの負荷を乗じた値と、
前記受信したイベントの数量に、前記イベントと前記振り分けルールとのマッチングの際に前記振り分け装置にかかるイベント1つ当たりの負荷を乗じた値と、
前記送信したイベントの情報サイズに、情報を送信する際に前記振り分け装置にかかる単位情報サイズあたりの負荷を乗じた値と、
の和に基づいて、前記振り分け装置がイベントを転送する際に前記振り分け装置にかかる負荷を算出する、
請求項2に記載の負荷分散装置。The reception status includes information representing a quantity and information representing an information size of an event received by the distribution device within a predetermined period,
The transmission status includes information indicating an information size of an event transmitted by the distribution device within a predetermined period,
The calculating means includes
A value obtained by multiplying the information size of the received event by the load per unit information size applied to the distribution device when information is received;
A value obtained by multiplying the quantity of the received event by a load per event applied to the distribution device when matching the event and the distribution rule;
A value obtained by multiplying the information size of the transmitted event by the load per unit information size applied to the distribution device when transmitting information;
Based on the sum of the above, the load applied to the distribution device when the distribution device transfers the event,
The load distribution apparatus according to claim 2.
前記システムに含まれるイベント送信源は、イベントを生成し、前記生成したイベントを振り分け装置に送信し、
前記送信先決定ルールは、前記イベント送信源ごとにあらかじめ送信先の振り分け装置が関連づけされたルールであり、
前記システムに含まれる振り分け装置は、一つまたは複数の前記イベント送信源からイベントを受信し、
前記受信状況は、前記複数のイベント送信源のうち特定のイベント送信源から前記振り分け装置が所定期間内に受信するイベントの受信状況であり、
前記送信状況は、前記複数のイベント送信源のうち特定のイベント送信源から前記振り分け装置が所定期間内に受信し前記処理装置に送信したイベントの送信状況である、請求項1に記載の負荷分散装置。The event processing system includes a plurality of the event transmission sources,
An event transmission source included in the system generates an event, transmits the generated event to a distribution device,
The transmission destination determination rule is a rule in which a transmission destination distribution device is associated in advance for each event transmission source,
The distribution device included in the system receives an event from one or a plurality of the event transmission sources,
The reception status is a reception status of an event received by the distribution device within a predetermined period from a specific event transmission source among the plurality of event transmission sources,
The load distribution according to claim 1, wherein the transmission status is a transmission status of an event received by the distribution device from a specific event transmission source among the plurality of event transmission sources within a predetermined period and transmitted to the processing device. apparatus.
前記受信状況および前記送信状況に基づいて、前記特定のイベント送信源から所定期間内に受信するイベントを前記処理装置に転送する際に、前記の振り分け装置に発生する負荷を算出する算出手段を更に備え、
前記更新手段は、前記負荷に基づいて前記送信先決定ルールを更新する
請求項4に記載の負荷分散装置。The load balancer is
Calculation means for calculating a load generated in the distribution device when transferring an event received from the specific event transmission source within a predetermined period to the processing device based on the reception status and the transmission status. Prepared,
The load distribution apparatus according to claim 4, wherein the update unit updates the transmission destination determination rule based on the load.
前記受信状況は、前記振り分け装置が所定期間内に受信した、特定の内容のイベントの受信状況であり、
前記送信状況は、前記振り分け装置が所定期間内に送信した、前記特定の内容のイベントの送信状況である、
請求項1に記載の負荷分散装置。The transmission destination determination rule is a rule in which the content of an event to be transmitted is associated with a transmission destination distribution device,
The reception status is a reception status of an event having a specific content received by the distribution device within a predetermined period,
The transmission status is a transmission status of the event with the specific content transmitted by the distribution device within a predetermined period.
The load distribution apparatus according to claim 1.
前記受信状況および前記送信状況に基づいて、前記イベント送信源から所定期間内に受信する特定の内容のイベントを前記処理装置に転送する際に、前記振り分け装置に発生する負荷を算出し、
前記更新手段は、前記負荷に基づいて前記送信先決定ルールを更新する
請求項6に記載の負荷分散装置。The load balancer is:
Based on the reception status and the transmission status, when an event having a specific content received from the event transmission source within a predetermined period is transferred to the processing device, a load generated in the distribution device is calculated,
The load distribution apparatus according to claim 6, wherein the update unit updates the transmission destination determination rule based on the load.
前記複数の振り分け装置のうち、送信先決定ルールに基づいて決定される振り分け装置に、イベントを送信する1つまたは複数のイベント送信源と、
を含むシステムと通信可能に接続されるコンピュータが、
前記振り分け装置が所定期間内に受信するイベントの、数量または情報サイズを表す情報である受信状況、および、前記イベント送信源が所定期間内に送信するイベントの、数量または情報サイズを表す情報である送信状況を取得し、
前記受信状況および送信状況に基づいて、前記振り分け装置が前記イベント生成源から前記処理装置へとイベントを転送する際に前記振り分け装置にかかる負荷が、前記複数の振り分け装置の間で平準化されるように、前記送信先決定ルールを更新する、
負荷分散方法。Receiving a plurality of events from an event transmission source, and discarding the event for each received event based on information included in the event and a distribution rule; A plurality of sorting devices to be transferred to the processing device;
Among the plurality of distribution devices, one or a plurality of event transmission sources for transmitting an event to a distribution device determined based on a transmission destination determination rule;
A computer that is communicatively connected to a system including:
A reception status that is information indicating the quantity or information size of an event received by the distribution device within a predetermined period, and an information that indicates the quantity or information size of an event transmitted by the event transmission source within a predetermined period. Get the transmission status,
Based on the reception status and transmission status, a load applied to the distribution device when the distribution device transfers an event from the event generation source to the processing device is leveled among the plurality of distribution devices. Updating the destination determination rule,
Load balancing method.
前記複数の振り分け装置のうち、送信先決定ルールに基づいて決定される振り分け装置に、イベントを送信する1つまたは複数のイベント送信源と、
を含むシステムと通信可能に接続されるコンピュータに、
前記振り分け装置が所定期間内に受信するイベントの、数量または情報サイズを表す情報である受信状況、および、前記イベント送信源が所定期間内に送信するイベントの、数量または情報サイズを表す情報である送信状況を取得する処理と、
前記受信状況および送信状況に基づいて、前記振り分け装置が前記イベント生成源から前記処理装置へとイベントを転送する際に前記振り分け装置にかかる負荷が、前記複数の振り分け装置の間で平準化されるように、前記送信先決定ルールを更新する処理と
を実行させるプログラムを記録したコンピュータ読み取り可能な記憶媒体。Receiving a plurality of events from an event transmission source, and discarding the event for each received event based on information included in the event and a distribution rule; A plurality of sorting devices to be transferred to the processing device;
Among the plurality of distribution devices, one or a plurality of event transmission sources for transmitting an event to a distribution device determined based on a transmission destination determination rule;
To a computer communicatively connected to a system including
A reception status that is information indicating the quantity or information size of an event received by the distribution device within a predetermined period, and an information that indicates the quantity or information size of an event transmitted by the event transmission source within a predetermined period. Processing to obtain the transmission status;
Based on the reception status and transmission status, a load applied to the distribution device when the distribution device transfers an event from the event generation source to the processing device is leveled among the plurality of distribution devices. As described above, a computer-readable storage medium storing a program for executing a process for updating the transmission destination determination rule.
前記複数の振り分け装置のうち、送信先決定ルールに基づいて決定される振り分け装置に、イベントを送信する1つまたは複数のイベント送信源とを含み、更に、
前記振り分け装置が所定期間内に受信するイベントの、数量または情報サイズを表す情報である受信状況、および、前記イベント送信源が所定期間内に送信するイベントの、数量または情報サイズを表す情報である送信状況を取得する取得手段と、
前記受信状況および送信状況に基づいて、前記振り分け装置が前記イベント生成源から前記処理装置へとイベントを転送する際に前記振り分け装置にかかる負荷が、前記複数の振り分け装置の間で平準化されるように、前記送信先決定ルールを更新する更新手段と、
を備える負荷分散装置を含む、
イベント処理システム。Receiving a plurality of events from an event transmission source, and discarding the event for each received event based on information included in the event and a distribution rule; A plurality of sorting devices to be transferred to the processing device;
Among the plurality of distribution devices, including one or more event transmission sources for transmitting events to a distribution device determined based on a transmission destination determination rule,
A reception status that is information indicating the quantity or information size of an event received by the distribution device within a predetermined period, and an information that indicates the quantity or information size of an event transmitted by the event transmission source within a predetermined period. An acquisition means for acquiring the transmission status;
Based on the reception status and transmission status, a load applied to the distribution device when the distribution device transfers an event from the event generation source to the processing device is leveled among the plurality of distribution devices. Updating means for updating the transmission destination determination rule,
Including a load balancer comprising:
Event processing system.
Applications Claiming Priority (3)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2013124812 | 2013-06-13 | ||
JP2013124812 | 2013-06-13 | ||
PCT/JP2014/003016 WO2014199606A1 (en) | 2013-06-13 | 2014-06-06 | Load balancer, load-balancing method, storage medium, and event-processing system |
Publications (1)
Publication Number | Publication Date |
---|---|
JPWO2014199606A1 true JPWO2014199606A1 (en) | 2017-02-23 |
Family
ID=52021922
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2015522528A Pending JPWO2014199606A1 (en) | 2013-06-13 | 2014-06-06 | Load distribution apparatus, load distribution method and program, and event processing system |
Country Status (2)
Country | Link |
---|---|
JP (1) | JPWO2014199606A1 (en) |
WO (1) | WO2014199606A1 (en) |
Families Citing this family (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP7059806B2 (en) * | 2018-05-29 | 2022-04-26 | 株式会社オートネットワーク技術研究所 | In-vehicle communication system, in-vehicle relay device, communication program and communication method |
Family Cites Families (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2003281007A (en) * | 2002-03-20 | 2003-10-03 | Fujitsu Ltd | Dynamic configuration controller and dynamic configuration control method |
JP4161998B2 (en) * | 2005-03-28 | 2008-10-08 | 日本電気株式会社 | LOAD DISTRIBUTION DISTRIBUTION SYSTEM, EVENT PROCESSING DISTRIBUTION CONTROL DEVICE, AND EVENT PROCESSING DISTRIBUTION CONTROL PROGRAM |
-
2014
- 2014-06-06 JP JP2015522528A patent/JPWO2014199606A1/en active Pending
- 2014-06-06 WO PCT/JP2014/003016 patent/WO2014199606A1/en active Application Filing
Also Published As
Publication number | Publication date |
---|---|
WO2014199606A1 (en) | 2014-12-18 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP5664098B2 (en) | Composite event distribution apparatus, composite event distribution method, and composite event distribution program | |
KR101948961B1 (en) | Aircraft information management system | |
US9736226B2 (en) | Rule distribution server, event processing system and method, and program | |
US20120124594A1 (en) | Event processing system, distribution controller, event processing method, distribution control method, and program storage medium | |
JPWO2014034060A1 (en) | Event processing control device, node device, event processing system, and event processing control method | |
JP2013101530A (en) | Service cooperation device, service cooperation method, and service cooperation program | |
US11212174B2 (en) | Network management device and network management method | |
JP6809011B2 (en) | Devices and systems for remote monitoring of control systems | |
JP2011150472A (en) | Web service system, server selection reference determination device, server selection reference determination method and program | |
WO2014199606A1 (en) | Load balancer, load-balancing method, storage medium, and event-processing system | |
JP2013236264A (en) | Monitoring device, load levelling method, program, and monitoring system equipped with them | |
JP6963465B2 (en) | Computer system and data processing control method | |
JP5664383B2 (en) | Event processing method, event processing apparatus, and event processing program | |
US11720397B2 (en) | Information processing method and apparatus to migrate tasks between resources | |
WO2014199607A1 (en) | Load balancer, load-balancing method, storage medium, and event-processing system | |
JP6155861B2 (en) | Data management method, data management program, data management system, and data management apparatus | |
US10860614B2 (en) | Partitioning data in a clustered database environment | |
JP2020091670A (en) | Cooperation system and cooperation method | |
JP6805791B2 (en) | Information processing equipment, information processing methods and information processing systems | |
JPWO2010001481A1 (en) | Information collecting apparatus, information collecting program and method | |
JP6709689B2 (en) | Computer system and computer system control method | |
JP7196764B2 (en) | Information processing system | |
JP2021197570A (en) | Computing service management device, method, and program | |
KR20230073094A (en) | Information processing system and information processing method | |
JP4999880B2 (en) | Controller and network system provided with the same |