Deprecated: The each() function is deprecated. This message will be suppressed on further calls in /home/zhenxiangba/zhenxiangba.com/public_html/phproxy-improved-master/index.php on line 456
JP4811364B2 - Terminal device, system, terminal control method, and terminal program - Google Patents
[go: Go Back, main page]

JP4811364B2 - Terminal device, system, terminal control method, and terminal program - Google Patents

Terminal device, system, terminal control method, and terminal program Download PDF

Info

Publication number
JP4811364B2
JP4811364B2 JP2007174043A JP2007174043A JP4811364B2 JP 4811364 B2 JP4811364 B2 JP 4811364B2 JP 2007174043 A JP2007174043 A JP 2007174043A JP 2007174043 A JP2007174043 A JP 2007174043A JP 4811364 B2 JP4811364 B2 JP 4811364B2
Authority
JP
Japan
Prior art keywords
server
information
connection destination
servers
destination list
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.)
Expired - Fee Related
Application number
JP2007174043A
Other languages
Japanese (ja)
Other versions
JP2009015424A (en
Inventor
寛明 佐藤
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
NEC Corp
Original Assignee
NEC Corp
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 NEC Corp filed Critical NEC Corp
Priority to JP2007174043A priority Critical patent/JP4811364B2/en
Publication of JP2009015424A publication Critical patent/JP2009015424A/en
Application granted granted Critical
Publication of JP4811364B2 publication Critical patent/JP4811364B2/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Information Transfer Between Computers (AREA)
  • Computer And Data Communications (AREA)

Description

本発明は、端末装置、システム、端末制御方法および端末プログラムに関する。   The present invention relates to a terminal device, a system, a terminal control method, and a terminal program.

特許文献1には、複数あるサーバの一と通信するクライアントが、あるサーバが選択したサーバと通信するシステムが開示されている。この技術はクライアントが主体となって、通信先サーバを決定するものではない。   Patent Document 1 discloses a system in which a client that communicates with one of a plurality of servers communicates with a server selected by a certain server. In this technology, the client is the main body and does not determine the destination server.

特許文献2には、サーバ(受信先)が中継コンピュータを通じてサーバ(送信元)の通知コードを受信するシステムが開示されている。この技術はサーバ(受信先)が主体となって、通信先中継コンピュータを選択するものではない。   Patent Document 2 discloses a system in which a server (reception destination) receives a notification code of a server (transmission source) through a relay computer. This technology is mainly based on a server (reception destination) and does not select a communication destination relay computer.

特開平9−106381号公報Japanese Patent Laid-Open No. 9-106381 特開平8−16502号公報JP-A-8-16502

特許文献1および2の技術は、各々単独またはその組み合わせのいずれにおいても、端末の通信先サーバは端末以外のものが主体となって選択しなければならないという課題があった。本発明はこの課題を解決するための端末装置、システム、端末制御方法および端末プログラムを提供することにある。   The techniques of Patent Documents 1 and 2 have a problem that a communication destination server of a terminal must be selected mainly by a server other than the terminal, either individually or in combination. An object of the present invention is to provide a terminal device, a system, a terminal control method, and a terminal program for solving this problem.

本発明の一例の端末装置は、記憶域に格納された接続先リストと、端末APと、接続された複数の第1サーバの各々から取得した第1情報に基づいて前記複数の第1サーバの各々の状態情報を前記接続先リストに記憶し、前記複数の第1サーバの状態情報に基づいて前記複数の第1サーバからひとつを選択して当該選択した第1サーバと前記端末APとの間の通信接続を行う端末プログラムを備える。   The terminal device according to an example of the present invention includes a plurality of first servers based on first information acquired from a connection destination list stored in a storage area, a terminal AP, and a plurality of connected first servers. Each state information is memorize | stored in the said connecting point list, based on the state information of said several 1st server, one is selected from these several 1st servers, Between the said selected 1st server and said terminal AP The terminal program which performs communication connection of is provided.

本発明の一例の端末制御方法は、コンピュータが、前記コンピュータに接続された複数の第1サーバの各々から第1情報を取得する取得行程と、前記第1情報に基づいて前記複数の第1サーバの各々の状態情報を記憶域に格納された接続先リストに記憶する記憶行程と、前記複数の第1サーバの状態情報に基づいて前記複数の第1サーバからひとつを選択して当該選択した第1サーバと前記コンピュータに搭載された端末APとの間の通信接続を行う接続行程を有する。   The terminal control method according to an example of the present invention includes an acquisition process in which a computer acquires first information from each of a plurality of first servers connected to the computer, and the plurality of first servers based on the first information. And selecting the one of the plurality of first servers based on the storage process of storing the state information of each in the connection destination list stored in the storage area and the state information of the plurality of first servers. 1 has a connection process for performing communication connection between the server and the terminal AP mounted on the computer.

本発明の一例の端末プログラムは、コンピュータに、前記コンピュータに接続された複数の第1サーバの各々から第1情報を取得する取得処理と、前記第1情報に基づいて前記複数の第1サーバの各々の状態情報を記憶域に格納された接続先リストに記憶する記憶処理と、前記複数の第1サーバの状態情報に基づいて前記複数の第1サーバからひとつを選択して当該選択した第1サーバと前記コンピュータに搭載された端末APとの間の通信接続を行う接続処理を実行させる。   The terminal program of an example of the present invention includes: an acquisition process for acquiring first information from each of a plurality of first servers connected to the computer; and a plurality of first servers based on the first information. A storage process for storing each state information in a connection destination list stored in a storage area, and a first one selected from the plurality of first servers based on the state information of the plurality of first servers. Connection processing for performing communication connection between the server and the terminal AP installed in the computer is executed.

本発明によれば、端末が主体となって通信先サーバを選択することができる。   According to the present invention, a communication destination server can be selected mainly by a terminal.

本発明の第1の実施例(実施例1)は以下の通りである。本実施例は、図1および図2が示すように以下の3層の構造から構成されている店舗システム10である。
1)クライアントAP12を備え、オペレータが操作するクライアントPC1n。
2)サーバAP22を備えるAPサーバ2m。
3)業務用のデータベースを制御するDBMS32を備えるDBサーバ3p。
The first embodiment (embodiment 1) of the present invention is as follows. A present Example is the store system 10 comprised from the following three-layer structure, as FIG. 1 and FIG. 2 shows.
1) A client PC 1n having a client AP 12 and operated by an operator.
2) AP server 2m including server AP22.
3) A DB server 3p having a DBMS 32 for controlling a business database.

ここで、APは、アプリケーションプログラムを意味する。クライアントPC1nは端末装置とも呼ばれるコンピュータである。APサーバ2mは第2サーバとも呼ばれる。DBMS32はデータベース管理システムを意味する。また、DBサーバ3pは第2サーバとも呼ばれる。   Here, AP means an application program. The client PC 1n is a computer also called a terminal device. The AP server 2m is also called a second server. DBMS 32 means a database management system. The DB server 3p is also called a second server.

店舗システム10は、店舗にクライアントPC1nを備え、センタにAPサーバ2m、DBサーバ3pを備える。
店舗には業務処理用のサーバコンピュータを備えていない。店舗システム10は、クライアントPC1n、APサーバ2m、DBサーバ3pの各々を一台備えていても複数台備えていてもよい。各々の台数は一致している必要はない。サーバAP22は業務処理用のロジックを含んでいる。本実施例では、クライアントAP12は操作性の観点からNET Frameworkアプリケーションであると仮定する。サーバAP22は、再利用性、信頼性などの観点からのEnterprise JavaBean(登録商標)(EJB)アプリケーションとしている。通信はCORBA(Common Object Request Broker Architecture)やSOAP(Simple Object Access Protocol)の規約に準拠して行う。
The store system 10 includes a client PC 1n in a store and an AP server 2m and a DB server 3p in a center.
The store does not have a server computer for business processing. The store system 10 may include one or more client PCs 1n, AP servers 2m, and DB servers 3p. The numbers of each need not match. The server AP 22 includes business processing logic. In this embodiment, it is assumed that the client AP 12 is a NET Framework application from the viewpoint of operability. The server AP 22 is an Enterprise JavaBean (registered trademark) (EJB) application from the viewpoints of reusability and reliability. Communication is performed in accordance with CORBA (Common Object Request Broker Architecture) and SOAP (Simple Object Access Protocol) standards.

店舗システム10において、接続タイムアウト設定値は、クライアントPC1nがタイムアウトによる接続エラーを検出したさいに、APサーバ2m内で生き残るプロセスが無いように設定される。すなわち、クライアントPC1nがAPサーバ2mの応答監視に使用する接続タイムアウト設定値は、APサーバ2mがDBサーバ3pの応答監視に使用する接続タイムアウト設定値より長い。このため、DBサーバ3pで異常が発生した時は、クライアントPC1nがタイムアウトを検出する前に、APサーバ2mが異常を検出しAPサーバ2m内の関連プロセスは異常終了することとなる。   In the store system 10, the connection timeout setting value is set so that no process survives in the AP server 2m when the client PC 1n detects a connection error due to timeout. That is, the connection timeout setting value used by the client PC 1n for monitoring the response of the AP server 2m is longer than the connection timeout setting value used by the AP server 2m for monitoring the response of the DB server 3p. For this reason, when an abnormality occurs in the DB server 3p, before the client PC 1n detects a timeout, the AP server 2m detects the abnormality and the related process in the AP server 2m ends abnormally.

なお、本発明の実施例は店舗システムに限定されない。本発明は、倉庫システムや放送システムなど他のシステムにも適用可能である。   In addition, the Example of this invention is not limited to a store system. The present invention can also be applied to other systems such as a warehouse system and a broadcasting system.

図2は本実施例の詳細な構成を示す。クライアントPC1nの構成は下記通りである。   FIG. 2 shows the detailed configuration of this embodiment. The configuration of the client PC 1n is as follows.

1)クライアントAP12
これは、店舗システム10の業務処理を行うアプリケーションプログラム(AP)の一部である。これは、APサーバ2m側のAPであるサーバAP22と共同して業務処理を実行する。
1) Client AP12
This is a part of an application program (AP) that performs business processing of the store system 10. This executes business processing in cooperation with the server AP22 which is an AP on the AP server 2m side.

2)接続先判定部品CA
この部品は、接続するAPサーバ2mの識別子をCL接続先情報保持部品CBから取得する。この部品は、CL接続先情報保持部品CBからすべてのAPサーバ2mへの接続が出来ない旨の応答を受け取った場合は、APサーバ2mへの接続を止めてクライアントPC1n単独でのローカルな処理を行うように決定する。
2) Connection destination determination component CA
This component acquires the identifier of the AP server 2m to be connected from the CL connection destination information holding component CB. If this component receives a response from the CL connection destination information holding component CB that all the AP servers 2m cannot be connected, it stops the connection to the AP server 2m and performs local processing on the client PC 1n alone. Decide to do.

3)CL接続先情報保持部品CB
この部品は、CL接続先リスト14に格納されている各APサーバ2mの情報を管理する。
3) CL connection destination information holding component CB
This component manages information of each AP server 2m stored in the CL connection destination list 14.

4)接続先切り替え部品CC
この部品は、APサーバ2mとの間の通信結果報告を通信部品CEから受け取ってチェックし、接続エラーやタイムアウトの発生を検出する。この部品は、接続エラー時には再試行を行う。また、この部品は、通信結果報告に従って、CL接続先情報保持部品CB経由でCL接続先リスト14の情報を更新する。
4) Connection destination switching component CC
This component receives a communication result report with the AP server 2m from the communication component CE and checks it to detect the occurrence of a connection error or timeout. This part will retry when there is a connection error. In addition, this component updates the information in the CL connection destination list 14 via the CL connection destination information holding component CB in accordance with the communication result report.

さらにこの部品は、接続先生死検知部品CDから特定のAPサーバ2mに接続されるDBサーバ3pがすべて障害という情報を受け取った場合、そのAPサーバ2mに関するCL接続先リスト14の情報をCL接続先情報保持部品CB経由で更新する。この部品は、接続先生死検知部品CDから障害中であったAPサーバ2mの復帰が通知された場合にも、そのAPサーバ2mに関するCL接続先リスト14の情報をCL接続先情報保持部品CB経由で更新する。   In addition, when all the DB servers 3p connected to the specific AP server 2m receive the failure information from the connection teacher death detection component CD, this component uses the CL connection destination information on the AP server 2m as the CL connection destination. Update via the information holding component CB. Even when the connection teacher death detection component CD notifies that the AP server 2m that has been in trouble is returned, this component uses the CL connection destination information holding component CB to send the information in the CL connection destination list 14 related to the AP server 2m. Update with.

5)接続先生死検知部品CD
この部品は、設定により定められたルールに基づき、CL接続先リスト14に登録されているAPサーバ2mへのポーリングを通信部品CE経由で行う。ポーリングは、APサーバ2mが備えるAPステータス返却部品AFに対して行い、クライアントPC1nとAPサーバ2m間の接続確認およびレスポンスタイム確認を行う。ポーリングは、APサーバ2mの持つDBサーバ3pの状態も確認する。本部品は、ポーリングによりAPサーバ2mの復帰を確認したら接続先切り替え部品CCへ通知する。APサーバ2mの復帰は、APサーバ2mへの通信が成功して当該APサーバ2mに接続されているDBサーバ3pのステータスが正常であることにより検出される。
5) Connection teacher death detection component CD
This component polls the AP server 2m registered in the CL connection destination list 14 via the communication component CE based on the rules determined by the settings. Polling is performed on the AP status return component AF provided in the AP server 2m, and the connection confirmation and response time confirmation between the client PC 1n and the AP server 2m are performed. Polling also confirms the state of the DB server 3p of the AP server 2m. This component notifies the connection destination switching component CC when the return of the AP server 2m is confirmed by polling. The return of the AP server 2m is detected when the communication with the AP server 2m is successful and the status of the DB server 3p connected to the AP server 2m is normal.

6)通信部品CE
本部品はAPサーバ2mと通信をしてその状態情報(第1情報)をデータ受信や通信時間監視により取得する。ここでAPサーバ2mから取得される状態情報は、APサーバ2mから受信して得られる情報と、APサーバ2mへの通信がタイムオーバーすることで間接的に得られる情報の両者を含む。CL接続先リスト14のAPステータス18mは、ここで取得した状態情報基づいて設定される。
6) Communication parts CE
This part communicates with the AP server 2m and acquires its status information (first information) by data reception or communication time monitoring. Here, the status information acquired from the AP server 2m includes both information obtained by receiving from the AP server 2m and information obtained indirectly when communication with the AP server 2m is over. The AP status 18m of the CL connection destination list 14 is set based on the status information acquired here.

7)CL接続先リスト14
本データは、クライアントPC1nごとに負荷分散と障害時切替先平滑化の為に設けられた、当該クライアントPC1nから接続可能なAPサーバ2mの一覧表である。本データは、クライアントPC1nの記憶域に格納されている。クライアントPC1nは、業務処理の通信開始時に、このCL接続先リスト14に基づいて接続するAPサーバ2mを選択して接続する。図3によれば、CL接続先リスト14は、接続先の候補となるAPサーバ2mの識別子AP_ID16m、当該APサーバ2mのAP通信アドレス17mおよび当該APサーバ2mの運転状態を示すAPステータス18mを包含する。ここで、APステータス18mは、正常状態(Active)、高負荷状態(Busy)もしくは障害状態(Dead)のいずれかの値をとる。APステータス18mは、第1サーバの状態情報とも呼ばれる。
7) CL connection destination list 14
This data is a list of AP servers 2m that can be connected from the client PC 1n, provided for load distribution and smoothing of the switching destination at the time of failure for each client PC 1n. This data is stored in the storage area of the client PC 1n. The client PC 1n selects and connects the AP server 2m to be connected based on the CL connection destination list 14 at the start of business process communication. According to FIG. 3, the CL connection destination list 14 includes an identifier AP_ID 16m of the AP server 2m that is a connection destination candidate, an AP communication address 17m of the AP server 2m, and an AP status 18m indicating the operation state of the AP server 2m. To do. Here, the AP status 18m takes one of a normal state (Active), a high load state (Busy), and a failure state (Dead). The AP status 18m is also called state information of the first server.

8)ローカルDB15
これは、クライアントPC1n単独でローカルな処理を行うときに使用するデータベースである。
8) Local DB15
This is a database used when local processing is performed by the client PC 1n alone.

なお、接続先判定部品CA、CL接続先情報保持部品CB、接続先切り替え部品CC、接続先生死検知部品CDおよび、通信部品CEは、クライアントミドルウェア13を構成する。クライアントミドルウェア13は、上記各部品の機能を包含していれば良く、機能分割は上記部品通りの分割に限られない。なお、クライアントミドルウェア13は端末プログラムとも呼ばれる。また、ローカルDB15が無い場合もある。図9は、こうした条件を加味したクライアントPC1nの構成を示す。   The connection destination determination component CA, the CL connection destination information holding component CB, the connection destination switching component CC, the connection teacher death detection component CD, and the communication component CE constitute the client middleware 13. The client middleware 13 only needs to include the functions of the above components, and the functional division is not limited to the division according to the components. The client middleware 13 is also called a terminal program. Further, there may be no local DB 15. FIG. 9 shows the configuration of the client PC 1n taking these conditions into consideration.

図2によれば、APサーバ2mの構成は下記通りである。   According to FIG. 2, the configuration of the AP server 2m is as follows.

1)サーバAP22
これは、店舗システム10の業務処理を行うアプリケーションプログラム(AP)の一部である。これは、クライアントPC1n側のAPであるクライアントAP12と共同して業務処理を実行する。
1) Server AP22
This is a part of an application program (AP) that performs business processing of the store system 10. This executes business processing in cooperation with the client AP 12 which is the AP on the client PC 1n side.

2)コネクション部品AA
本部品は、DBサーバ3pへの接続方法をサーバAP22へ提供する。この部品は、ステータス取得部品ABへ振分キーを渡して、振分キーに基づいて選択されたDBサーバ3pとの接続を確立する。
2) Connection parts AA
This component provides the server AP 22 with a connection method to the DB server 3p. This component passes a distribution key to the status acquisition component AB, and establishes a connection with the DB server 3p selected based on the distribution key.

3)ステータス取得部品AB
本部品は、振分キーに基づく接続先優先順位を決定し、接続するDBサーバ3pの識別子(DB_ID26p)をAP接続先情報保持部品ACから取得し、コネクション部品AAに返却する。
3) Status acquisition part AB
This component determines the connection destination priority based on the distribution key, acquires the identifier (DB_ID 26p) of the DB server 3p to be connected from the AP connection destination information holding component AC, and returns it to the connection component AA.

4)AP接続先情報保持部品AC
本部品は、AP接続先リスト24に格納されている各DBサーバ3pの情報を管理する。
4) AP connection destination information holding component AC
This component manages information of each DB server 3p stored in the AP connection destination list 24.

5)ポーリング部品AE
本部品は、AP接続先リスト24に登録されているDBサーバ3pを対象にポーリングを行う。このポーリングはDBサーバ3pと通信をしてその状態情報(第2情報)を受信や通信時間監視により取得する。ここでDBサーバ3pから取得される状態情報は、DBサーバ3pから受信して得られる情報と、DBサーバ3pへの通信がタイムオーバーすることで間接的に得られる情報の両者を含む。AP接続先リスト24のDBステータス28pは、ここで取得した状態情報に基づいて設定される。
5) Polling parts AE
This component polls the DB server 3p registered in the AP connection destination list 24. This polling communicates with the DB server 3p and acquires the status information (second information) by receiving or monitoring the communication time. Here, the status information acquired from the DB server 3p includes both information obtained by receiving from the DB server 3p and information obtained indirectly by communication over time to the DB server 3p. The DB status 28p of the AP connection destination list 24 is set based on the status information acquired here.

ポーリングで行われる通信はノンブロッキングモードで行う。ポーリングの通信が、DBMS32に対する通信を遅延させないためである。さらに、DBMS32との通信や他のAPサーバ2mによるポーリングに於いてストールが発生した場合でも、本部品が不要な待ち合わせを行わない為でもある。   Communication performed by polling is performed in a non-blocking mode. This is because polling communication does not delay communication with the DBMS 32. Furthermore, even when a stall occurs during communication with the DBMS 32 or polling by another AP server 2m, this part does not perform unnecessary waiting.

6)APステータス返却部品AF
本部品は、クライアントPC1nのポーリングを受けて、AP接続先情報保持部品AC経由でAP接続先リスト24よりDBステータス28pを取得して、クライアントPC1nに送信する。
6) AP status return part AF
This component receives polling of the client PC 1n, acquires the DB status 28p from the AP connection destination list 24 via the AP connection destination information holding component AC, and transmits it to the client PC 1n.

7)AP接続先リスト24
これは、APサーバ2mごとに負荷分散と障害時切替先平滑化の為に設けられた、当該APサーバ2mから接続可能なDBサーバ3pの一覧表である。本データは、APサーバ2mの記憶域に格納されている。APサーバ2mは、業務処理の通信開始時に、このAP接続先リスト24に基づいて接続するDBサーバ3pを選択して接続する。図4によれば、AP接続先リスト24は、接続先の候補となるDBサーバ3pの識別子DB_ID26p、当該DBサーバ3pのDB通信アドレス27pおよび当該DBサーバ3pの運転状態を示すDBステータス28pを包含する。ここで、DBステータス28pは、正常状態(Active)、高負荷状態(Busy)もしくは障害状態(Dead)のいずれかの値をとる。DBステータス28pは、第2サーバの状態情報とも呼ばれる。
7) AP connection destination list 24
This is a list of DB servers 3p that can be connected to the AP server 2m, provided for load distribution and smoothing of the switching destination at the time of failure for each AP server 2m. This data is stored in the storage area of the AP server 2m. The AP server 2m selects and connects the DB server 3p to be connected based on the AP connection destination list 24 at the start of business process communication. According to FIG. 4, the AP connection destination list 24 includes the identifier DB_ID 26p of the DB server 3p that is a candidate for the connection destination, the DB communication address 27p of the DB server 3p, and the DB status 28p indicating the operation state of the DB server 3p. To do. Here, the DB status 28p takes one of a normal state (Active), a high load state (Busy), and a failure state (Dead). The DB status 28p is also called status information of the second server.

なお、コネクション部品AA、ステータス取得部品AB、AP接続先情報保持部品AC、ポーリング部品AEおよび、APステータス返却部品AFは、APサーバミドルウェア23を構成する。APサーバミドルウェア23は、上記各部品の機能を包含していれば良く、機能分割は上記部品通りの分割に限られない。なお、APサーバミドルウェア23はサーバプログラムとも呼ばれる。   The connection component AA, the status acquisition component AB, the AP connection destination information holding component AC, the polling component AE, and the AP status return component AF constitute the AP server middleware 23. The AP server middleware 23 only needs to include the functions of the respective components, and the function division is not limited to the division according to the components. The AP server middleware 23 is also called a server program.

図2によれば、DBサーバ3pの構成は以下の通りである。   According to FIG. 2, the configuration of the DB server 3p is as follows.

1)DBMS32
これは、サーバAP22の要求を受けてデータベースの参照更新などの管理を行う。
1) DBMS32
In response to a request from the server AP 22, management such as database reference update is performed.

2)DBステータス監視部品DA
本部品はDBMS32の状態を監視し、動作不能(Dead)、過負荷によるレスポンスタイム遅延(Busy)の発生や障害からの復旧(Alive)時にその状態をステータス管理部品DDに通知する。監視は所定のSQL(Structured Query Language)文を発行してその戻り値およびレスポンスタイムを確認することで行う。本実行例は、『SELECT 1 FROM DUAL』文を使用している。
2) DB status monitoring component DA
This component monitors the state of the DBMS 32 and notifies the status management component DD of the status when the operation is disabled (Dead), response time delay (Busy) occurs due to overload, or recovery from a failure (Alive). Monitoring is performed by issuing a predetermined SQL (Structured Query Language) statement and checking its return value and response time. This execution example uses the “SELECT 1 FROM DUAL” statement.

3)ステータス管理部品DD
本部品は、DBステータス監視部品DAが通知してきたDBMS32の状態情報(データベースの状態情報)を保持・管理する。
3) Status management component DD
This component holds and manages the status information (database status information) of the DBMS 32 notified by the DB status monitoring component DA.

4)通信待ち受け部品DC
本部品は、APサーバ2mからの通信をノンブロッキングモードで受け付ける。本部品は、APサーバ2mから通信があった際にステータス管理部品DDからデータベースの状態情報を取得しAPサーバ2mへ返却する。
4) Communication standby part DC
This component accepts communication from the AP server 2m in the non-blocking mode. When there is communication from the AP server 2m, this component acquires the database status information from the status management component DD and returns it to the AP server 2m.

なお、DBステータス監視部品DA、ステータス管理部品DDおよび、通信待ち受け部品DCは、DBサーバミドルウェア33の一部を構成する。DBサーバミドルウェア33は、上記各部品の機能を包含していれば良く、機能分割は上記部品通りの分割に限られない。なお、DBサーバミドルウェア33はいわゆるOSの一部として実装されてもよい。   The DB status monitoring part DA, the status management part DD, and the communication standby part DC constitute part of the DB server middleware 33. The DB server middleware 33 only needs to include the functions of the above components, and the function division is not limited to the division according to the components. The DB server middleware 33 may be implemented as a part of a so-called OS.

次に、本実施例の動作について図面を参照して説明する。
ここでは、当初はすべてのAPサーバ2mおよびDBサーバ3pは正常で、CL接続リスト14内のAPステータス18mおよびAP接続リスト24内のDBステータス28pはAliveであるとする。下記文中の (3-1) のような表記は、「図3に示したステップ3-1」を示す。
Next, the operation of the present embodiment will be described with reference to the drawings.
Here, it is assumed that all the AP servers 2m and DB servers 3p are normal at the beginning, and the AP status 18m in the CL connection list 14 and the DB status 28p in the AP connection list 24 are Alive. The notation such as (3-1) in the following sentence indicates “Step 3-1 shown in FIG. 3”.

図2、図5および図6は、クライアントPC1nに於けるAPサーバ2mの振分・切り替え機能を示す。   2, 5 and 6 show the distribution / switching function of the AP server 2m in the client PC 1n.

1.正常時の処理
クライアントAP12は、APサーバ2mとの通信開始に当たり、接続先判定部品CAを呼び出す(5-1)。接続先判定部品CAはCL接続先情報保持部品CBを呼び出す(5-1)。CL接続先情報保持部品CBは、CL接続先リスト14に格納されているAPサーバ2mのAP通信アドレス17mからひとつを所定の優先順位に従って選択して取得する(5-2)。
1. Normal Processing When the client AP 12 starts communication with the AP server 2m, it calls the connection destination determination component CA (5-1). The connection destination determination component CA calls the CL connection destination information holding component CB (5-1). The CL connection destination information holding component CB selects and acquires one of the AP communication addresses 17m of the AP server 2m stored in the CL connection destination list 14 according to a predetermined priority (5-2).

取得が成功する(5-3で取得可となる)のは当該APサーバ2mのAPステータス18mがAliveまたはBusyとなっている場合である。AliveのAPサーバ2mがある時には、BusyのAPサーバ2mのAP通信アドレス17mは選択されない。通信部品CEが、取得されたAP通信アドレス17mで指定されるAPサーバ2mと通信する(5-4)。   Acquisition is successful (acquisition is possible at 5-3) when the AP status 18m of the AP server 2m is Alive or Busy. When there is an Alive AP server 2m, the AP communication address 17m of the Busy AP server 2m is not selected. The communication component CE communicates with the AP server 2m designated by the acquired AP communication address 17m (5-4).

接続先切り替え部品CCはこの通信結果を受け取って通信が正常である(5-6,5-8がともに正常となる)ことを確認する。その後、クライアントAP12は当該APサーバ2mと通信接続され、当該APサーバ2m上のサーバAP22と連携して業務処理を実行する(5-10)。業務処理でエラーが発生しなければ(5-12で正常となる)クライアントAP12は処理を終了する。   The connection destination switching component CC receives this communication result and confirms that the communication is normal (both 5-6 and 5-8 are normal). Thereafter, the client AP 12 is communicatively connected to the AP server 2m, and executes business processing in cooperation with the server AP 22 on the AP server 2m (5-10). If no error occurs in the business process (normal in 5-12), the client AP 12 ends the process.

なお、APサーバ2mへは正常に通信できても、APサーバ2mがDBサーバ3pとの通信に失敗することがある。これは、DBサーバ3pがすべて障害の場合に発生する。この場合、クライアントAP12はサーバAP22からその旨の通知を受けることになる(5-12でエラーとなる)。この通知を受けてCL接続先情報保持部品CBは、CL接続先リスト14のすべてのAPステータス18mをDeadに更新する(5-13)。そして、クライアントAP12は接続先生死検知部品CDを起動してポーリングを行い(5-13)、障害の復旧を待ち合わせることになる。   Even if the communication with the AP server 2m can be performed normally, the AP server 2m may fail to communicate with the DB server 3p. This occurs when all the DB servers 3p have a failure. In this case, the client AP 12 receives a notification to that effect from the server AP 22 (an error occurs in 5-12). Upon receiving this notification, the CL connection destination information holding component CB updates all AP statuses 18m in the CL connection destination list 14 to Dead (5-13). Then, the client AP 12 activates the connection teacher death detection component CD, performs polling (5-13), and waits for recovery from the failure.

2.現在の接続先APサーバ2mが過負荷な場合の処理
接続先切り替え部品CCが、通信部品CEの通信(5-4)でレスポンスタイムが所定の許容時間1を超えた(5-6でタイムオーバーとなる)ことを検出する。これを受けて、CL接続先情報保持部品CBは、CL接続先リスト14内のAPステータス18mをBusyに更新する(5-7)。
2. Processing when the current connection destination AP server 2m is overloaded The connection destination switching component CC has a response time exceeding the predetermined allowable time 1 in communication (5-4) of the communication component CE. Is detected). In response, the CL connection destination information holding component CB updates the AP status 18m in the CL connection destination list 14 to Busy (5-7).

その後、クライアントAP12は通信が終了するのを待ち合わせて、正常終了(5-8で正常)時には、そのまま業務処理を実行する(5-10)。この正常終了時には、クライアントAP12は接続先生死検知部品CDを起動してポーリングを行い、その後、再度接続先判定部品CAを起動して、別のAPサーバ2mのAP通信アドレス17mを取得する(5-2)ようにしてもよい。   Thereafter, the client AP 12 waits for the communication to end, and when it ends normally (normally 5-8), executes the business process as it is (5-10). At this normal end, the client AP 12 activates the connection teacher death detection component CD and performs polling, and then activates the connection destination determination component CA again to acquire the AP communication address 17m of another AP server 2m (5). -2) You may do it.

3.現在の接続先APサーバ2mが障害の場合の処理
接続先切り替え部品CCが、通信部品CEの通信(5-4)で接続エラーが発生した(5-8でエラーとなる)ことを検出する。この接続エラーは、通信が所定の許容時間2(許容時間1より長い)を超えたことで検出される。これを受けて、CL接続先情報保持部品CBは、CL接続先リスト14内のAPステータス18mをDeadに更新する(5-9)。クライアントAP12は接続先生死検知部品CDを起動してポーリングを開始し(5-9)、その後、再度接続先判定部品CAを起動して、所定の優先順位の下位にある別のAPサーバ2mのAP通信アドレス17mを取得する(5-2)。
3. Processing when current connection destination AP server 2m has a failure The connection destination switching component CC detects that a connection error has occurred in communication (5-4) of the communication component CE (an error occurs in 5-8). This connection error is detected when communication exceeds a predetermined allowable time 2 (longer than allowable time 1). Upon receiving this, the CL connection destination information holding component CB updates the AP status 18m in the CL connection destination list 14 to Dead (5-9). The client AP 12 activates the connection teacher death detection component CD and starts polling (5-9), and then activates the connection destination determination component CA again, so that another AP server 2m that is lower in the predetermined priority order AP communication address 17m is acquired (5-2).

4.すべてのAPサーバ2mが障害の場合の処理
CL接続先リスト14に登録されているAPサーバ2mのAPステータス18mがすべてDeadであるとき、接続先判定部品CAはAP通信アドレス17mを取得(5-2)に失敗する。この(5-3で取得不可となる)場合、クライアントAP12は通信部品CEを用いた通信はおこなわず、単独にローカル処理できる範囲の業務処理を行う(5-6、5-11)。このとき、クライアントAP12は、必要に応じてローカルDB15を使用する。
4). Processing when all AP servers 2m fail
When the AP statuses 18m of the AP server 2m registered in the CL connection destination list 14 are all Dead, the connection destination determination component CA fails to acquire (5-2) the AP communication address 17m. In this case (cannot be acquired in 5-3), the client AP 12 does not perform communication using the communication component CE, and performs business processing within a range that can be independently processed locally (5-6, 5-11). At this time, the client AP 12 uses the local DB 15 as necessary.

5.APサーバ2mの復旧時の処理
APサーバ2mの復旧は図6に示すクライアントPC1nのポーリングにより監視する。このポーリングは、接続先生死検知部品CDがCL接続先リスト14に登録されているすべてのAPサーバ2mを対象に行う。
5. Processing when AP server 2m is restored
Recovery of the AP server 2m is monitored by polling of the client PC 1n shown in FIG. This polling is performed for all AP servers 2m in which the connection teacher death detection component CD is registered in the CL connection destination list 14.

同部品は、ポーリングを開始するとCL接続先リスト14からAP通信アドレス17mを取得し、通信部品CEを用いてAPサーバ2m上のAPステータス返却部品AFと通信する(6-2)。この通信が正常(6-3で正常)な場合、接続先生死検知部品CDはAPステータス返却部品AFからAP接続先リスト24内のすべてのDBステータス28pを受信する。   When the polling starts, the component acquires the AP communication address 17m from the CL connection destination list 14, and communicates with the AP status return component AF on the AP server 2m using the communication component CE (6-2). When this communication is normal (normal in 6-3), the connection teacher death detection component CD receives all the DB statuses 28p in the AP connection destination list 24 from the AP status return component AF.

接続先生死検知部品CDはDBステータス28pのチェックを行う(6-4)。同部品は、正常(AliveまたはBusy)なDBサーバ3pが存在する(6-5で有となる)と、CL接続先情報保持部品CBを経由して、CL接続先リスト14のAPサーバ2mのAPステータス18mを更新する(6-7)。   The connection teacher death detection component CD checks the DB status 28p (6-4). When there is a normal (Alive or Busy) DB server 3p (becomes 6-5), this component passes through the CL connection destination information holding component CB, and the AP server 2m in the CL connection destination list 14 The AP status 18m is updated (6-7).

この処理は次の通りである。接続先生死検知部品CDは、あるAPサーバ2mからAliveを示すDBステータス28pを受信すれば当該APサーバ2mのAPステータス18mはAliveとする。AliveなDBステータス28pは受信しないがBusyを示すものを受信した場合に同部品は、当該APサーバ2mのAPステータス18mをBusyに設定する。なお、あるAPサーバ2mから受信したすべてのDBステータス28pがDeadであれば、当該APサーバ2mのAPステータス18mはDeadが設定される。   This process is as follows. If the connection teacher death detection component CD receives the DB status 28p indicating Alive from a certain AP server 2m, the AP status 18m of the AP server 2m is set to Alive. When the Alive DB status 28p is not received but the one indicating Busy is received, the same component sets the AP status 18m of the AP server 2m to Busy. If all the DB statuses 28p received from an AP server 2m are Dead, the AP status 18m of the AP server 2m is set to Dead.

ポーリングしたすべてのAPサーバ2mについて、通信異常(6-3で異常)または全DBステータス28pが異常(Dead)である(6-5で無となる)場合は、一定時間後に再度ポーリングを行う(6-6)。   For all AP servers 2m that have polled, if communication abnormality (abnormality in 6-3) or all DB statuses 28p are abnormal (Dead) (nothing in 6-5), poll again after a certain time ( 6-6).

なお、以上の行程(処理)は、接続行程(5−1、5−2、5−3、5−4)、取得行程(5−6、5−8、6−2、6−3、6−4、6−5)および記憶行程(5−7、5−9、5−13、6−7)に大別される。これらの行程が、クライアントミドルウェア13により実行される。図9は、この様子を示す。   In addition, the above process (process) is a connection process (5-1, 5-2, 5-3, 5-4), an acquisition process (5-6, 5-8, 6-2, 6-3, 6). -4, 6-5) and memory steps (5-7, 5-9, 5-13, 6-7). These processes are executed by the client middleware 13. FIG. 9 shows this state.

ポーリングは、システムの初期設定時およびその後の一定時間ごとにも実施される。   Polling is performed at the time of initial setting of the system and at regular intervals thereafter.

図2、図7および図8は、APサーバ2mに於けるDBサーバ3pの振替・切り替え機能を示す。   2, 7 and 8 show the transfer / switching function of the DB server 3p in the AP server 2m.

1.正常動作
サーバAP22は、DBサーバ3pとの通信開始に当たり、コネクション部品AAを呼び出す(7-1)。コネクション部品AAは、ステータス取得部品ABを呼び出して特定の振分キー(たとえば店舗コード)に対応して、接続すべき優先順にDBサーバ3pの識別子(DB_ID26p)のリストを取得する(7-2)。コネクション部品AAは、当該リストから優先度の最も高いDBサーバ3pのDB_ID26pを選択する。そして、同部品は、当該DBサーバ3pのDB通信アドレス27pをAP接続先保持部品AC経由でAP接続先リスト24から取得する(7-3)。取得が成功する(7-4で取得可となる)のはDBステータス28pがAliveまたはBusyとなっているDBサーバ3pがある場合である。AliveのDBサーバ3pがある時には、BusyのDBサーバ3pのDB通信アドレス27pは選択されない。
1. Normal operation The server AP 22 calls the connection component AA when starting communication with the DB server 3p (7-1). The connection component AA calls the status acquisition component AB to acquire a list of identifiers (DB_ID 26p) of the DB server 3p in the priority order to be connected in correspondence with a specific distribution key (for example, store code) (7-2). . The connection component AA selects the DB_ID 26p of the DB server 3p having the highest priority from the list. Then, the component acquires the DB communication address 27p of the DB server 3p from the AP connection destination list 24 via the AP connection destination holding component AC (7-3). Acquisition succeeds (acquisition is possible in 7-4) is when there is a DB server 3p whose DB status 28p is Alive or Busy. When there is an Alive DB server 3p, the DB communication address 27p of the Busy DB server 3p is not selected.

コネクション部品AAは選択されたDBサーバ3pと通信を行う。通信が正常(7-6で正常)であれば、サーバAP22は当該DBサーバ3pと通信接続され、当該DBサーバ3p上のデータベースにアクセスを行って業務処理を実行する(7-8)。業務処理でエラーが発生しなければ(7-9で正常となる)サーバAP22は処理を終了する。   The connection component AA communicates with the selected DB server 3p. If the communication is normal (normal in 7-6), the server AP 22 is communicatively connected to the DB server 3p, and accesses the database on the DB server 3p to execute the business process (7-8). If no error occurs in the business process (normal in 7-9), the server AP 22 ends the process.

コネクション部品AAは選択されたDBサーバ3pとの通信が異常(7-6でエラー)であれば、前述のリストにおいて順位の低いDBサーバ3pのDB通信アドレス27pを取得して接続しようとする(7-7)。   If the communication with the selected DB server 3p is abnormal (error in 7-6), the connection component AA acquires the DB communication address 27p of the DB server 3p with the lower rank in the above list and tries to connect ( 7-7).

2.現在の接続先DBサーバ3pが障害時の処理
サーバAP22がデータベース(DBサーバ3p)にアクセス中に障害となった(7-9でエラー)ときはサーバAP22にアクセスエラーが返却される(7-10)。この場合は、データベース内のデータが不完全な状態になっている可能性もあるため、このエラーは接続エラーとは別の形でサーバAP22に報告される。このエラーはサーバAP22からクライアントPC1nにも通知される(5-12)。
2. Processing when the current connection destination DB server 3p fails When the server AP 22 fails while accessing the database (DB server 3p) (error 7-9), an access error is returned to the server AP 22 (7- Ten). In this case, since the data in the database may be in an incomplete state, this error is reported to the server AP 22 in a form different from the connection error. This error is also notified from the server AP 22 to the client PC 1n (5-12).

また、DBサーバ3pでは、DBステータス監視部品DAが障害(Dead状態)やレスポンス遅延(Busy状態)等の異常を検出して、ステータス管理部品DDが保持するデータベースの状態情報を更新する。この情報は、図6のポーリングを通じてAP接続先リスト24のDBステータス28pに反映される。   In the DB server 3p, the DB status monitoring part DA detects an abnormality such as a failure (Dead state) or a response delay (Busy state), and updates the state information of the database held by the status management part DD. This information is reflected in the DB status 28p of the AP connection destination list 24 through polling in FIG.

3.すべてのDBサーバ3pが障害の場合の処理
ステータス取得部品ABは、すべてのDBサーバ3pが障害であることを検出した(7-4で取得不可となる)場合は、サーバAP22にDB接続エラーを通知する(7-5)。このエラーはサーバAP22からクライアントPC1nにも通知される(5-12)。クライアントPC1nでは、CL接続リストのAPステータス18mをDeadへと更新する(5-13)。
3. Processing when all DB servers 3p are faulty Status acquisition component AB detects that all DB servers 3p are faulty (cannot be acquired in 7-4), and issues a DB connection error to server AP22. Notify (7-5). This error is also notified from the server AP 22 to the client PC 1n (5-12). The client PC 1n updates the AP status 18m in the CL connection list to Dead (5-13).

4.DBサーバ3p復旧時の処理
DBステータス監視部品DAは、DBMS32の状態を監視してその状態が正常であると判断すると、ステータス管理部品DDでその状態を保持する。このデータベースの状態情報は図6のAPサーバ2mのポーリングにより、AP接続先リスト24のDBステータス28pに反映される。
4). Processing when DB server 3p is restored
When the DB status monitoring component DA monitors the status of the DBMS 32 and determines that the status is normal, the status management component DD holds the status. The status information of this database is reflected in the DB status 28p of the AP connection destination list 24 by polling of the AP server 2m in FIG.

APサーバ2mにおいては、定期的にAP接続先リスト24に基づいてすべてのDBサーバ3pの状態を定期的にポーリングしている。このポーリングにおいては、先ずポーリング部品AEがDBサーバ3p上で待ち受けている通信待ち受け部品DCと通信を行う(8-1)。   The AP server 2m periodically polls the status of all DB servers 3p based on the AP connection destination list 24. In this polling, the polling component AE first communicates with the communication standby component DC waiting on the DB server 3p (8-1).

この通信が正常(8-2で正常)な場合、ポーリング部品AEは、データベースの状態情報を受信して、その状態情報をチェックする(8-3)。データベースの状態情報は、DBサーバ3pにおいて、DBステータス監視部品DAがDBMS32の状態を監視することで生成している。データベースの状態情報は、ステータス管理部品DDで保持され、通信待ち受け部品DCにより、ポーリング部品AEに通知される。   If this communication is normal (normal in 8-2), the polling component AE receives the status information of the database and checks the status information (8-3). The database status information is generated by the DB status monitoring component DA monitoring the status of the DBMS 32 in the DB server 3p. The status information of the database is held by the status management component DD, and is notified to the polling component AE by the communication standby component DC.

ポーリング部品AEは、データベースの状態情報の内容に基づきAP接続先情報保持部品ACを経由してAP接続先リスト24のDBステータス28pを更新する。ポーリング部品AEは、データベースの状態情報が正常(8-4で正常)ならばAliveを設定し(8-5)、異常(8-4で異常)ならば、BusyまたはDeadを設定する(8-6)。なお、同部品は、DBサーバ3pとの通信でエラーが発生した(8-2でエラーとなる)場合はDeadを設定する(8-6)。   The polling component AE updates the DB status 28p of the AP connection destination list 24 via the AP connection destination information holding component AC based on the contents of the state information in the database. The polling component AE sets Alive if the database status information is normal (normal in 8-4) (8-5), and if abnormal (abnormal in 8-4), sets Busy or Dead (8- 6). If an error occurs in communication with the DB server 3p (the error occurs in 8-2), the part sets Dead (8-6).

本実施例の効果は、負荷分散のためのハードウェアのコストを削減できることにある。さらに、第2の効果は、負荷分散に関わるシングルポイント・オブ・フェイリアを除去できることにある。   The effect of the present embodiment is that the cost of hardware for load distribution can be reduced. Furthermore, the second effect is that a single point of failure related to load distribution can be removed.

その理由は、クライアントミドルウェア13がCL接続先リスト14を参照してAPサーバ2mの振替・切り替え機能を実現できるために、負荷分散装置を置く必要がないためである。   The reason is that the client middleware 13 can realize the transfer / switching function of the AP server 2m by referring to the CL connection destination list 14, and therefore it is not necessary to place a load distribution device.

第3の効果は、DBサーバ3p障害時の切り替えに遅延が発生しないことである。その理由は、APサーバ2mが行うDBサーバ3pのポーリングに於いて、APサーバミドルウェア23およびDBサーバミドルウェア33においてノンブロッキング通信によりにて情報をやり取りするからである。   The third effect is that there is no delay in switching when the DB server 3p fails. The reason is that, in the polling of the DB server 3p performed by the AP server 2m, the AP server middleware 23 and the DB server middleware 33 exchange information by non-blocking communication.

第4の効果は、クライアントAP12が、DBサーバ3pの全障害が発生したこと、および復旧したことを、DBサーバ3pと通信することなく検出して対応できることである。その理由は、DBサーバ3pの状態情報がAPサーバ2mを経由して、クライアントPC1nにまで到達する方式をとっているからである。   The fourth effect is that the client AP 12 can detect and cope with the occurrence of the failure of the DB server 3p and the recovery without communicating with the DB server 3p. The reason is that the state information of the DB server 3p is used to reach the client PC 1n via the AP server 2m.

クライアントミドルウェア13、APサーバミドルウェア23およびDBサーバミドルウェア33は、いずれも専用ハードウェアとして実現してもよい。または、プログラムがメモリに格納され、プロセッサーがプログラムを実行することにより、これらの機能を実現してもよい。   The client middleware 13, the AP server middleware 23, and the DB server middleware 33 may all be realized as dedicated hardware. Alternatively, these functions may be realized by a program being stored in a memory and a processor executing the program.

本発明の第2の実施例は以下の通りである。実施例1の店舗システム10は、すべてのAPサーバ2mが障害の場合に限り、クライアントAP12が単独でローカルな処理を行う(図5における5-3、5-5、5-11)。第2の実施例は、基本的にクライアントAP12が単独でローカルな処理を行い、ローカルな処理で問題が発生したときにAPサーバ2mに接続するようにする。これにより、ローカル処理が主体のアプリケーションに本発明を適用できるようになる。   The second embodiment of the present invention is as follows. In the store system 10 of the first embodiment, only when all the AP servers 2m have a failure, the client AP 12 performs local processing independently (5-3, 5-5, 5-11 in FIG. 5). In the second embodiment, the client AP 12 basically performs local processing independently, and connects to the AP server 2m when a problem occurs in the local processing. As a result, the present invention can be applied to an application mainly based on local processing.

本発明の第3の実施例は以下の通りである。実施例1の店舗システム10は、接続先APサーバ2mが障害の場合、ポーリングを起動している(図5における5-9)。第3の実施例では、これを全APサーバ2mが障害の場合にだけポーリングを起動する。APサーバ2mの復旧検知遅れが許容される場合に、ポーリングの発生頻度を下げることができる。   The third embodiment of the present invention is as follows. The store system 10 of the first embodiment activates polling when the connected AP server 2m has a failure (5-9 in FIG. 5). In the third embodiment, polling is activated only when all the AP servers 2m have a failure. When the recovery detection delay of the AP server 2m is allowed, the occurrence frequency of polling can be lowered.

本発明の第4の実施例は以下の通りである。実施例1の店舗システム10は、接続先APサーバ2mが障害の場合ポーリングを起動する(図5における5-9)。その後、実施例1の店舗システム10は、再度接続先判定部品CAを起動して、所定の優先順位の下位にある別のAPサーバ2mのAP通信アドレス17mを取得(5-2)し、当該別のAPサーバ2mと接続する(5-4)ことになる。第4の実施例の店舗システム10は、その接続後、ポーリングで当該別のAPサーバ2mより所定の優先順位で上位のAPサーバ2mが正常であることが検出されたときに、当該上位のAPサーバ2mに接続し直す。これは、接続先生死検知部品CDが自動的に行ってもよい。または同部品はクライアントAP12に通知するだけとし、クライアントAP12が適切なタイミングで接続し直してもよい。これによりAPサーバ2mに処理能力の差異がある場合に、適切な負荷分散をはかることができる。   The fourth embodiment of the present invention is as follows. The store system 10 of the first embodiment activates polling when the connection destination AP server 2m has a failure (5-9 in FIG. 5). Thereafter, the store system 10 of the first embodiment activates the connection destination determination component CA again, acquires (5-2) the AP communication address 17m of another AP server 2m that is lower in the predetermined priority order, and Connect to another AP server 2m (5-4). After the connection, the store system 10 of the fourth embodiment, when connected, detects that the upper AP server 2m is normal with a predetermined priority from the other AP server 2m by polling. Reconnect to server 2m. This may be done automatically by the connection teacher death detection component CD. Alternatively, the component may only notify the client AP 12 and the client AP 12 may reconnect at an appropriate timing. Thereby, when there is a difference in processing capability between the AP servers 2m, appropriate load distribution can be achieved.

本発明の第5の実施例は以下の通りである。実施例1の店舗システム10は、すべてのAPサーバ2mが障害の場合に、クライアントAP12が単独でローカルな処理を行う(図5における5-3、5-5、5-11)。第5の実施例の店舗システム10は、その後のポーリングで正常なAPサーバ2mがあることが検出されたときに、ローカル処理をやめて当該APサーバ2mに接続する。これは、接続先生死検知部品CDが自動的に行ってもよい。または同部品はクライアントAP12に通知するだけとし、クライアントAP12が適切なタイミングで接続してもよい。これにより、APサーバ2mの復旧に迅速に対応することができる。   The fifth embodiment of the present invention is as follows. In the store system 10 of the first embodiment, when all the AP servers 2m have a failure, the client AP 12 performs local processing independently (5-3, 5-5, 5-11 in FIG. 5). When the store system 10 of the fifth embodiment detects that there is a normal AP server 2m by subsequent polling, it stops local processing and connects to the AP server 2m. This may be done automatically by the connection teacher death detection component CD. Alternatively, the component may only notify the client AP 12, and the client AP 12 may connect at an appropriate timing. Thereby, it is possible to quickly cope with the recovery of the AP server 2m.

本発明の第6の実施例は以下の通りである。上述の実施例では、APサーバ2mとDBサーバ3pは別のサーバである。しかし、第6の実施例では、APサーバ2mとDBサーバ3pを併せて一台のサーバコンピュータとして実装してもよい。本実施例では、同一のサーバ内のDBMS32の障害や性能劣化をDBサーバ3pの障害や性能劣化として監視する。本実施例によれば、安価に本発明を利用したシステムを実現できる。   The sixth embodiment of the present invention is as follows. In the above-described embodiment, the AP server 2m and the DB server 3p are different servers. However, in the sixth embodiment, the AP server 2m and the DB server 3p may be combined and implemented as a single server computer. In this embodiment, a failure or performance degradation of the DBMS 32 in the same server is monitored as a failure or performance degradation of the DB server 3p. According to the present embodiment, a system using the present invention can be realized at low cost.

店舗システムの全体構成を示す図である。It is a figure which shows the whole structure of a store system. クライアントおよびサーバの内部構成を示す図である。It is a figure which shows the internal structure of a client and a server. CL接続先リストの構成を示す図である。It is a figure which shows the structure of CL connection destination list. AP接続先リストの構成を示す図である。It is a figure which shows the structure of AP connection destination list. クライアントAPの接続処理のフローチャートである。It is a flowchart of a connection process of a client AP. クライアントPCが行うポーリング処理のフローチャートである。It is a flowchart of the polling process which a client PC performs. サーバAPの接続処理のフローチャートである。It is a flowchart of the connection process of server AP. サーバAPが行うポーリング処理のフローチャートである。It is a flowchart of the polling process which server AP performs. クライアントPCの構成を示す図である。It is a figure which shows the structure of a client PC.

符号の説明Explanation of symbols

10 店舗システム
1n クライアントPC
12 クライアントAP
13 クライアントミドルウェア
14 CL接続先リスト
16m AP_ID
17m AP通信アドレス
18m APステータス
15 ローカルDB
CA 接続先判定部品
CB CL接続先情報保持部品
CC 接続先切り替え部品
CD 接続先生死検知部品
CE 通信部品
2m APサーバ
22 サーバAP
23 APサーバミドルウェア
24 AP接続先リスト
26p DB_ID
27p DB通信アドレス
28p DBステータス
AA コネクション部品
AB ステータス取得部品
AC AP接続先情報保持部品
AE ポーリング部品
AF APステータス返却部品
3p DBサーバ
32 DBMS
33 DBサーバミドルウェア
DA DBステータス監視部品
DD ステータス管理部品
DC 通信待ち受け部品
10 Store system 1n Client PC
12 Client AP
13 Client middleware 14 CL connection list 16m AP_ID
17m AP communication address 18m AP status 15 Local DB
CA connection destination determination component CB CL connection destination information holding component CC connection destination switching component CD connection teacher death detection component CE communication component 2m AP server 22 server AP
23 AP server middleware 24 AP connection list 26p DB_ID
27p DB communication address 28p DB status AA connection part AB status acquisition part AC AP connection destination information holding part AE polling part AF AP status return part 3p DB server 32 DBMS
33 DB server middleware DA DB status monitoring component DD status management component DC communication standby component

Claims (14)

記憶域に格納された接続先リストと、
端末APと、
接続された複数の第1サーバの各々から取得した第1情報に基づいて前記複数の第1サーバの各々の状態情報を前記接続先リストに記憶し、前記複数の第1サーバの状態情報に基づいて前記複数の第1サーバからひとつを選択して当該選択した第1サーバと前記端末APとの間の通信接続を行う端末プログラムと、を備え
前記複数の第1サーバの各々が、各々に接続されている全ての第2サーバから取得した第2情報に基づいて生成した前記第2サーバの状態情報を含む前記第1情報を受信することで取得し、
前記第1情報に含まれる前記第2サーバの状態情報に基づいて前記接続先リストに記憶されている前記第1サーバの状態情報を更新する、端末装置。
A destination list stored in storage, and
A terminal AP;
Based on the first information acquired from each of the plurality of connected first servers, the state information of each of the plurality of first servers is stored in the connection destination list, and based on the state information of the plurality of first servers. A terminal program that selects one of the plurality of first servers and performs communication connection between the selected first server and the terminal AP ,
Each of the plurality of first servers receives the first information including the state information of the second server generated based on the second information acquired from all the second servers connected to each of the first servers. Acquired,
A terminal device that updates the state information of the first server stored in the connection destination list based on the state information of the second server included in the first information .
取得された前記第1情報に含まれる前記第2サーバの状態情報に正常であることを示す情報が含まれていない場合に、前記複数の第1サーバに前記第1情報の送信を要求する、請求項1に記載の端末装置。 Requesting the transmission of the first information to the plurality of first servers when information indicating normality is not included in the status information of the second server included in the acquired first information; The terminal device according to claim 1. 取得された前記第1情報に含まれる前記第2サーバの状態情報に正常であることを示す情報が少なくとも一つ含まれている場合に、前記第1情報に含まれる前記第2サーバの状態情報に基づいて前記接続先リストに記憶されている前記第1サーバの状態情報を更新する、請求項1または2のいずれか1項に記載の端末装置。 State information of the second server included in the first information when the state information of the second server included in the acquired first information includes at least one piece of information indicating normality The terminal device according to claim 1, wherein state information of the first server stored in the connection destination list is updated based on the connection destination list . 前記第1サーバと前記第2サーバとの間の通信においてエラーが発生した際に当該第1サーバが送信する、エラーを示す情報を受け取ると、前記接続先リストに記憶されている第1サーバの状態情報の全てを、障害があることを示す情報に更新する、請求項1ないし3のいずれか1項に記載の端末装置。 When information indicating an error transmitted by the first server when an error occurs in communication between the first server and the second server is received, the first server stored in the connection destination list The terminal device according to any one of claims 1 to 3, wherein all of the state information is updated to information indicating that there is a failure . 前記接続先リストに記憶されている前記第1サーバの状態情報の全てが障害であることを示す情報である場合に、前記端末プログラムが、前記複数の第1サーバに前記第1情報の送信を要求する、請求項1ないし4のいずれか1項に記載の端末装置。 When all the status information of the first server stored in the connection destination list is information indicating a failure, the terminal program transmits the first information to the plurality of first servers. The terminal device according to claim 1 , wherein the terminal device is requested . 前記第1情報の送信の要求に基づいて送信される前記第1情報に基づいて、前記第1サーバの状態情報の少なくとも一つが正常であることを示す情報に更新された場合に、当該第1サーバに接続する、請求項5に記載の端末装置。 The first information is updated when at least one of the state information of the first server is updated based on the first information transmitted based on the request for transmitting the first information. The terminal device according to claim 5, connected to a server . 前記複数の第1サーバと、前記第2サーバと、請求項1ないし6のいずれか1項に記載の端末装置とを備えるシステム。 System comprising the plurality of first servers, and the second server, and a terminal device according to any one of claims 1 to 6. コンピュータが、
前記コンピュータに接続された複数の第1サーバの各々から第1情報を取得
前記第1情報に基づいて前記複数の第1サーバの各々の状態情報を記憶域に格納された接続先リストに記憶
前記複数の第1サーバの状態情報に基づいて前記複数の第1サーバからひとつを選択して当該選択した第1サーバと前記コンピュータに搭載された端末APとの間の通信接続を行
前記複数の第1サーバの各々が各々に接続されている全ての第2サーバから取得した第2情報に基づいて生成した前記第2サーバの状態情報を含む前記第1情報を受信することで取得し、
前記第1情報に含まれる前記第2サーバの状態情報に基づいて前記接続先リストに記憶されている前記第1サーバの状態情報を更新する、端末制御方法
Computer
It acquires first information from each of a plurality of first server connected to said computer,
The status information of each of the plurality of first servers is stored in the stored connection destination list to the storage based on the first information,
There line communications connection between the plurality of terminals AP mounted on the first server and the computer that the selected by selecting one from the plurality of first server based on a first server state information,
Acquired by receiving the first information including the state information of the second server generated based on the second information acquired from all the second servers connected to each of the plurality of first servers. And
A terminal control method for updating state information of the first server stored in the connection destination list based on state information of the second server included in the first information .
取得された前記第1情報に含まれる前記第2サーバの状態情報に正常であることを示す情報が少なくとも一つ含まれている場合に、前記第1情報に含まれる前記第2サーバの状態情報に基づいて前記接続先リストに記憶されている前記第1サーバの状態情報を更新する、請求項8に記載の端末制御方法。 State information of the second server included in the first information when the state information of the second server included in the acquired first information includes at least one piece of information indicating normality The terminal control method according to claim 8 , wherein state information of the first server stored in the connection destination list is updated based on the connection destination list . 前記コンピュータは、前記第1サーバと前記第2サーバとの間の通信においてエラーが発生した際に当該第1サーバが送信する、エラーを示す情報を受け取ると、前記接続先リストに記憶されている第1サーバの状態情報の全てを、障害があることを示す情報に更新する、請求項8または9に記載の端末制御方法。When the computer receives information indicating an error transmitted by the first server when an error occurs in communication between the first server and the second server, the computer stores the information indicating the error in the connection destination list. The terminal control method according to claim 8 or 9, wherein all of the state information of the first server is updated to information indicating that there is a failure. コンピュータに、
前記コンピュータに接続された複数の第1サーバの各々から第1情報を取得する処理と
前記第1情報に基づいて前記複数の第1サーバの各々の状態情報を記憶域に格納された接続先リストに記憶する処理と
前記複数の第1サーバの状態情報に基づいて前記複数の第1サーバからひとつを選択して当該選択した第1サーバと前記コンピュータに搭載された端末APとの間の通信接続を行う処理と、
前記複数の第1サーバの各々が各々に接続されている全ての第2サーバから取得した第2情報に基づいて生成した前記第2サーバの状態情報を含む前記第1情報を受信することで取得する処理と、
前記第1情報に含まれる前記第2サーバの状態情報に基づいて前記接続先リストに記憶されている前記第1サーバの状態情報を更新する処理と、を実行させる端末プログラム。
On the computer,
A processing you get the first information from each of a plurality of first server connected to said computer,
A processing you store status information of each of the plurality of first server to the destination list stored in the storage based on the first information,
And row intends process communication connection between the terminal AP, which is mounted on the first server and the computer that the selected by selecting one from the plurality of first server based on said plurality of first server state information ,
Acquired by receiving the first information including the state information of the second server generated based on the second information acquired from all the second servers connected to each of the plurality of first servers. Processing to
The terminal program which performs the process which updates the status information of the said 1st server memorize | stored in the said connection destination list based on the status information of the said 2nd server contained in the said 1st information .
取得された前記第1情報に含まれる前記第2サーバの状態情報に正常であることを示す情報が含まれていない場合に、前記複数の第1サーバに前記第1情報の送信を要求する処理を前記コンピュータに実行させる、請求項11に記載の端末プログラム。 Processing for requesting transmission of the first information to the plurality of first servers when the status information of the second server included in the acquired first information does not include information indicating normality The terminal program according to claim 11, wherein the computer is executed . 取得された前記第1情報に含まれる前記第2サーバの状態情報に正常であることを示す情報が少なくとも一つ含まれている場合に、前記第1情報に含まれる前記第2サーバの状態情報に基づいて前記接続先リストに記憶されている前記第1サーバの状態情報を更新する処理を前記コンピュータに実行させる、請求項11または12に記載の端末プログラム。 State information of the second server included in the first information when the state information of the second server included in the acquired first information includes at least one piece of information indicating normality The terminal program according to claim 11 or 12, which causes the computer to execute a process of updating the state information of the first server stored in the connection destination list based on the information . 前記第1サーバと前記第2サーバとの間の通信においてエラーが発生した際に当該第1サーバが送信する、エラーを示す情報を受け取ると、前記接続先リストに記憶されている第1サーバの状態情報の全てを、障害があることを示す情報に更新する処理を前記コンピュータに実行させる、請求項11ないし13のいずれか1項に記載の端末プログラム。 When information indicating an error transmitted by the first server when an error occurs in communication between the first server and the second server is received, the first server stored in the connection destination list The terminal program according to any one of claims 11 to 13, which causes the computer to execute a process of updating all of the state information to information indicating that there is a failure .
JP2007174043A 2007-07-02 2007-07-02 Terminal device, system, terminal control method, and terminal program Expired - Fee Related JP4811364B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2007174043A JP4811364B2 (en) 2007-07-02 2007-07-02 Terminal device, system, terminal control method, and terminal program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2007174043A JP4811364B2 (en) 2007-07-02 2007-07-02 Terminal device, system, terminal control method, and terminal program

Publications (2)

Publication Number Publication Date
JP2009015424A JP2009015424A (en) 2009-01-22
JP4811364B2 true JP4811364B2 (en) 2011-11-09

Family

ID=40356284

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2007174043A Expired - Fee Related JP4811364B2 (en) 2007-07-02 2007-07-02 Terminal device, system, terminal control method, and terminal program

Country Status (1)

Country Link
JP (1) JP4811364B2 (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2021070315A1 (en) * 2019-10-10 2021-04-15 東芝三菱電機産業システム株式会社 Scada web hmi system

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2576802B2 (en) * 1994-09-28 1997-01-29 日本電気株式会社 Remote program address management method
JP2000076198A (en) * 1998-08-28 2000-03-14 Nec Corp On-line processing fault information notifying method and system therefor

Also Published As

Publication number Publication date
JP2009015424A (en) 2009-01-22

Similar Documents

Publication Publication Date Title
KR100812374B1 (en) System and method for managing protocol network failures in a cluster system
CN103560922A (en) Disaster recovery method and system
WO2016184175A1 (en) Database processing method and apparatus
JP5366177B2 (en) Slot interface access device, method and program thereof, and redundant configuration and alternative method of main device
CN114840495B (en) A method, storage medium and device for preventing brain split in database cluster
US8285905B2 (en) Redundancy configuration and replacement method in a system including a master main unit and slave main units
US20150256622A1 (en) Connection management device, communication system, connection management method, and computer program product
JP7064132B2 (en) Fault monitoring system and fault monitoring method
JP2005301436A (en) Cluster system and failure recovery method in cluster system
CN106470429A (en) A kind of method for processing business being suitable to wireless dilatation and device
CN115426250B (en) Dual-machine hot standby switching method and device for target range command
JP4811364B2 (en) Terminal device, system, terminal control method, and terminal program
CN111586110B (en) Optimization processing method for raft in point-to-point fault
US7222174B2 (en) Monitoring control network system
JP2001022709A (en) Computer-readable storage medium storing a cluster system and a program
CN113515375A (en) Calling method and device for multiple CICS (common information carrier) nodes
CN117560268B (en) Cluster management method and related device
JP5691248B2 (en) Task takeover program, processing device, and computer system
CN112787868A (en) Information synchronization method and device
JPH10116257A (en) Decentralized media processing server, and communication network using the same
CN100456771C (en) Communication device and interaction method among modules therein
CN111064608A (en) Master-slave switching method and device of message system, electronic equipment and storage medium
JP2016152461A (en) Cloud system, router, management server, and program
WO2024166421A1 (en) Management system, adapter device, management method, and program
CN118509477A (en) Distributed cluster operation method, device, equipment, medium and program product

Legal Events

Date Code Title Description
RD01 Notification of change of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7421

Effective date: 20090512

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20110302

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20110315

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20110511

RD01 Notification of change of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7421

Effective date: 20110705

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20110726

A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20110808

R150 Certificate of patent or registration of utility model

Ref document number: 4811364

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

Free format text: JAPANESE INTERMEDIATE CODE: R150

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20140902

Year of fee payment: 3

LAPS Cancellation because of no payment of annual fees