JP2011070636A - Data synchronization system, data synchronization method, information processor, information processing method and program - Google Patents
Data synchronization system, data synchronization method, information processor, information processing method and program Download PDFInfo
- Publication number
- JP2011070636A JP2011070636A JP2010097249A JP2010097249A JP2011070636A JP 2011070636 A JP2011070636 A JP 2011070636A JP 2010097249 A JP2010097249 A JP 2010097249A JP 2010097249 A JP2010097249 A JP 2010097249A JP 2011070636 A JP2011070636 A JP 2011070636A
- Authority
- JP
- Japan
- Prior art keywords
- synchronization
- data
- processing unit
- information
- processing
- 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.)
- Granted
Links
Images
Landscapes
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
Abstract
Description
本発明は、データ同期技術に関し、特に通信ネットワークを介して接続された情報処理装置間で、データ通信を行うことにより両装置の記憶データを同期する技術に関する。 The present invention relates to a data synchronization technique, and more particularly to a technique for synchronizing data stored in both apparatuses by performing data communication between information processing apparatuses connected via a communication network.
近年、IP技術を使って既存の通信/放送サービスを統合し、安価かつ柔軟にこれらのサービスを提供しようとする試みが広がっている。また、ネットワーク・サービスの拡充に伴い、サービスの可用性を高めることが重要になってきており、災害時でもシステムを停止させないディザスタリカバリ(DR:Disaster Recovery)技術の重要性が高まってきている。
IP技術を用いて遠隔地間でデータ通信を行う場合、一般には、パケットの送信から受信までにかかる転送時間が大きい、転送経路の変更などにより送信順序と受信順序が異なることがある、という条件を考慮する必要がある。
In recent years, attempts have been made to integrate existing communication / broadcasting services using IP technology and provide these services flexibly and inexpensively. In addition, with the expansion of network services, it has become important to increase the availability of services, and the importance of disaster recovery (DR) technology that does not stop the system even in the event of a disaster has increased.
When data communication is performed between remote locations using IP technology, generally, the transfer time required from transmission to reception of a packet is long, and the transmission order and the reception order may be different due to a change in the transfer route, etc. Need to be considered.
従来、このようなデータ同期技術として、ディザスタリカバリ機構を、通信品質が保証されないインターネットを利用して構築する場合、データ複製に遅延が生じ、処理性能が大きく低下することを回避する技術が提案されている(例えば、非特許文献1など参照)。この技術では、プライマリサイトのアプリケーションサーバにおいて、データベース接続ライブラリを多重化し、その1つのデータベース接続をプライマリデータベースのアクセスに使い、別のデータベース接続で、バックアップデータベース用のデータベースドライバを通してバックアップデータベースと接続し、プライマリデータベースとバックアップデータベースに同一のアクセス要求を行うことで、複数のデータベースを論理的に同じ状態に保つようにしている。 Conventionally, as such a data synchronization technique, when a disaster recovery mechanism is constructed using the Internet where communication quality is not guaranteed, a technique for avoiding a delay in data replication and a significant decrease in processing performance has been proposed. (See, for example, Non-Patent Document 1). In this technology, in the application server at the primary site, the database connection library is multiplexed, one database connection is used for accessing the primary database, and another database connection is connected to the backup database through the database driver for the backup database. By making the same access request to the primary database and the backup database, a plurality of databases are logically kept in the same state.
しかしながら、このような従来技術では、拠点内など通信時間が短い環境を想定して、アプリケーションへのアクセスデータをそのまま複製して他拠点へ転送することにより、データ同期を行っているため、拠点間の通信に時間を要する場合には高速な応答を得ることができず、また、一方の拠点のデータベースが停止してサービス提供できない場合、他方の拠点のデータベースでもサービス提供できなくなるという問題があった。このため、要求に対して素早い応答が求められるオンライン系のアプリケーションでは、遠隔地間でデータ同期を行いながら、必要に応じて柔軟に片系だけでサービス提供を行うよう切り替えることが難しかった。 However, in such a conventional technology, assuming the environment where the communication time is short such as in a base, data is synchronized by copying the access data to the application as it is and transferring it to another base. When it takes time to communicate, it is not possible to obtain a high-speed response, and if the database at one base stops and cannot provide services, the database at the other base cannot be provided. . For this reason, it has been difficult for online applications that require a quick response to a request to switch between providing services with one system flexibly as needed while synchronizing data between remote locations.
本発明はこのような課題を解決するためのものであり、アプリケーションに対する高速応答性と、他方の拠点でのサービス停止に対する柔軟性を得ることができるデータ同期技術を提供することを目的としている。 An object of the present invention is to solve such a problem, and an object of the present invention is to provide a data synchronization technique capable of obtaining high-speed response to an application and flexibility for stopping a service at the other site.
このような目的を達成するために、本発明にかかるデータ同期システムは、通信ネットワークを介して接続された第1および第2の情報処理装置を含み、これら情報処理装置間で通信ネットワークを介してデータ通信を行うことにより、第1の情報処理装置に設けられた第1の記憶部で記憶する第1の記憶データと、第2の情報処理装置に設けられた第2の記憶部で記憶する第2の記憶データとを同期させるデータ同期システムであって、第1の情報処理装置に、第1の記憶部で記憶する第1の記憶データを更新するアプリケーションを実行するアプリケーション処理部と、更新の前後における第1の記憶データの差分に相当する差分情報を含む、アプリケーションからの同期要求を、順次保存するメッセージキュー処理部と、データ同期送信処理として、メッセージキュー処理部から同期要求をそれぞれが保存された順序で順に取得し、通信ネットワークを介して第2の情報処理装置へ送信する、処理を実行するデータ同期送信処理部とを備え、第2の情報処理装置に、データ同期受信処理として、通信ネットワークを介して第1の情報処理装置からの同期要求を受信し、当該同期要求に含まれる差分情報に基づいて、第2の記憶部で記憶する第2の記憶データを更新することにより、第1および第2の記憶データを同期させる、処理を実行するデータ同期受信処理部とを備えている。 In order to achieve such an object, a data synchronization system according to the present invention includes first and second information processing apparatuses connected via a communication network, and these information processing apparatuses are connected via a communication network. By performing data communication, the first storage data stored in the first storage unit provided in the first information processing apparatus and the second storage unit provided in the second information processing apparatus are stored. A data synchronization system that synchronizes with second storage data, an application processing unit that executes an application for updating first storage data stored in the first storage unit in the first information processing apparatus, and an update A message queue processing unit for sequentially storing synchronization requests from the application including difference information corresponding to the difference between the first storage data before and after the data, and synchronous data transmission As processing, a synchronization request is sequentially obtained from the message queue processing unit in the order in which they are stored, and transmitted to the second information processing apparatus via the communication network, and a data synchronous transmission processing unit that executes processing, As a data synchronization reception process, the second information processing apparatus receives a synchronization request from the first information processing apparatus via the communication network, and based on the difference information included in the synchronization request, the second storage unit And a data synchronization reception processing unit for executing processing for synchronizing the first and second storage data by updating the second storage data stored in step (b).
この際、メッセージキュー処理部で、同期要求の保存に応じて、当該同期要求に対する同期要求受領結果を直ちにアプリケーション処理部へ返送するようにしてもよい。 At this time, the message queue processing unit may immediately return the synchronization request receipt result for the synchronization request to the application processing unit according to the storage of the synchronization request.
また、データ同期送信処理部で、同期要求を送信する際、データ同期受信処理部との間で、同期要求間の送信順序が受信側で保証されるデータ送信プロトコルを用いるようにしてもよい。 Further, when the data synchronization transmission processing unit transmits the synchronization request, a data transmission protocol in which the transmission order between the synchronization requests is guaranteed on the reception side may be used with the data synchronization reception processing unit.
また、メッセージキュー処理部で、アプリケーション処理部から並列的に出力された同期メッセージを順次保存し、データ同期送信処理部で、複数のデータ同期送信処理を並列的に実行し、データ同期受信処理部で、並列的に実行する複数の処理を排他的に制御する排他制御機能を含み、この排他制御機能を用いて、データ同期送信処理部から受信した同期要求の処理順序を確保しつつ、複数の同期受信処理を並列的に実行するようにしてもよい。 In addition, the message queue processing unit sequentially stores the synchronous messages output in parallel from the application processing unit, and the data synchronous transmission processing unit executes a plurality of data synchronous transmission processes in parallel, and the data synchronous reception processing unit And including an exclusive control function that exclusively controls a plurality of processes executed in parallel, and using this exclusive control function, while ensuring the processing order of the synchronization requests received from the data synchronization transmission processing unit, The synchronous reception process may be executed in parallel.
また、データ同期送信処理部で、メッセージキュー処理部から取得した複数の同期要求に含まれる差分情報を1つの新たな差分情報に一括し、当該新たな差分情報を含む新たな同期要求を、通信ネットワークを介して第2の情報処理装置へ送信するようにしてもよい。 Also, the data synchronization transmission processing unit collects the difference information included in the plurality of synchronization requests acquired from the message queue processing unit into one new difference information, and communicates the new synchronization request including the new difference information. You may make it transmit to a 2nd information processing apparatus via a network.
また、第1の情報処理装置に、同期要求ごとに、当該同期要求と対応する排他情報を記憶する同期排他処理部をさらに設け、アプリケーション処理部で、同期要求をメッセージキュー処理部へ保存する際、当該同期要求と対応する排他情報として当該同期要求の処理種別を示す処理種別情報を含む排他情報を、同期排他処理部へ登録し、データ同期送信処理部で、メッセージキュー処理部から同期要求を取得して第2の情報処理装置へ送信する際、同期排他処理部により、当該同期要求の処理種別に該当する排他情報のうち、データ同期処理が未完了で当該同期要求より先にデータ同期処理すべき同期要求に関する排他情報がないことを確認した後、当該同期要求を第2の情報処理装置へ送信するようにしてもよい。 In addition, the first information processing apparatus further includes a synchronization exclusion processing unit that stores exclusive information corresponding to the synchronization request for each synchronization request, and the application processing unit stores the synchronization request in the message queue processing unit. The exclusive information including the processing type information indicating the processing type of the synchronous request as the exclusive information corresponding to the synchronous request is registered in the synchronous exclusive processing unit, and the synchronous request is received from the message queue processing unit by the data synchronous transmission processing unit. When acquiring and transmitting to the second information processing apparatus, the synchronization exclusive processing unit, among the exclusive information corresponding to the processing type of the synchronization request, data synchronization processing is incomplete and data synchronization processing is performed before the synchronization request. After confirming that there is no exclusive information regarding the synchronization request to be performed, the synchronization request may be transmitted to the second information processing apparatus.
また、第2の情報処理装置に、第1の情報処理装置から受信した同期要求を順次保存する同期要求記憶部をさらに設け、データ同期受信処理部で、第2の記憶部のデータ同期処理を行う際、同期要求記憶部で保存している同期要求のうちから、第1の記憶部に対して実行したデータ更新処理と一致した順序にしたがって、第2の記憶部に対して最も先にデータ同期処理すべき同期要求を取得し、当該同期要求に含まれる差分情報に基づいて第2の記憶部のデータ同期処理を行うようにしてもよい。 In addition, the second information processing apparatus further includes a synchronization request storage unit that sequentially stores the synchronization requests received from the first information processing apparatus, and the data synchronization reception processing unit performs data synchronization processing of the second storage unit. When performing, the data stored in the second storage unit first among the synchronization requests stored in the synchronization request storage unit according to the order consistent with the data update processing executed for the first storage unit. A synchronization request to be synchronized may be acquired, and data synchronization processing of the second storage unit may be performed based on difference information included in the synchronization request.
また、データ同期受信処理部で、通信ネットワークにおける同期要求の最大遅延時間より長い待機時間だけ同期要求記憶部で待機させた同期要求のうちから、第1の記憶部に対して実行したデータ更新処理と一致した順序にしたがって、最も先にデータ同期処理すべき同期要求を取得するようにしてもよい。 In addition, the data update processing executed for the first storage unit from the synchronization requests that are made to wait in the synchronization request storage unit for a standby time longer than the maximum delay time of the synchronization request in the communication network in the data synchronization reception processing unit The synchronization request that should be subjected to the data synchronization processing first may be acquired in accordance with the order that matches.
また、本発明にかかるデータ同期方法は、通信ネットワークを介して接続された第1および第2の情報処理装置を含み、これら情報処理装置間で通信ネットワークを介してデータ通信を行うことにより、第1の情報処理装置に設けられた第1の記憶部で記憶する第1の記憶データと、第2の情報処理装置に設けられた第2の記憶部で記憶する第2の記憶データとを同期させるデータ同期システムで用いられるデータ同期方法であって、第1の情報処理装置において、アプリケーション処理部が、第1の記憶部で記憶する第1の記憶データを更新するアプリケーションを実行するアプリケーション処理ステップと、メッセージキュー処理部が、更新の前後における第1の記憶データの差分に相当する差分情報を含む、アプリケーションからの同期要求を、順次保存するメッセージキュー処理ステップと、データ同期送信処理部が、データ同期送信処理として、メッセージキュー処理部から同期要求をそれぞれが保存された順序で順に取得し、通信ネットワークを介して第2の情報処理装置へ送信する、処理を実行するデータ同期送信処理ステップとを備え、第2の情報処理装置において、データ同期受信処理部が、データ同期受信処理として、通信ネットワークを介して第1の情報処理装置からの同期要求を受信し、当該同期要求に含まれる差分情報に基づいて、第2の記憶部で記憶する第2の記憶データを更新することにより、第1および第2の記憶データを同期させる、処理を実行するデータ同期受信処理ステップとを備えている。 The data synchronization method according to the present invention includes first and second information processing apparatuses connected via a communication network, and performs data communication between the information processing apparatuses via the communication network. The first storage data stored in the first storage unit provided in one information processing apparatus is synchronized with the second storage data stored in the second storage unit provided in the second information processing apparatus. A data synchronization method used in a data synchronization system to be executed, wherein an application processing unit executes an application for updating first stored data stored in the first storage unit in the first information processing apparatus. And the message queue processing unit includes the difference information corresponding to the difference of the first stored data before and after the update, The message queue processing step for sequentially storing the requests and the data synchronous transmission processing unit acquire the synchronization requests from the message queue processing unit in the order in which they are stored as the data synchronous transmission processing, and send them through the communication network. A data synchronization transmission processing step for executing processing to be transmitted to the second information processing device. In the second information processing device, the data synchronization reception processing unit performs the data synchronization reception processing as the first through the communication network. The first and second storages are received by receiving the synchronization request from the information processing apparatus and updating the second storage data stored in the second storage unit based on the difference information included in the synchronization request. A data synchronous reception processing step for executing processing for synchronizing data.
また、本発明にかかる情報処理装置は、通信ネットワークを介して他の情報処理装置と接続されて、他の情報処理装置との間で通信ネットワークを介してデータ通信を行うことにより、自己に設けられた記憶部で記憶する第1の記憶データと、他の情報処理装置で記憶する第2の記憶データとを同期させる情報処理装置であって、記憶部で記憶する記憶データを更新するアプリケーションを実行するアプリケーション処理部と、更新の前後における第1の記憶データの差分に相当する差分情報を含む、アプリケーションからの同期要求を、順次保存するメッセージキュー処理部と、データ同期送信処理として、メッセージキュー処理部から同期要求をそれぞれが保存された順序で順に取得し、通信ネットワークを介して他の情報処理装置へ送信する、処理を実行するデータ同期送信処理部とを備えている。 In addition, the information processing apparatus according to the present invention is connected to another information processing apparatus via a communication network, and performs data communication with the other information processing apparatus via the communication network. An information processing device that synchronizes first storage data stored in a storage unit and second storage data stored in another information processing device, and updates an application that updates storage data stored in the storage unit. An application processing unit to be executed, a message queue processing unit for sequentially storing synchronization requests from applications including difference information corresponding to the difference between the first storage data before and after the update, and a message queue as a data synchronous transmission process Acquire synchronization requests from the processing unit in the order in which they are stored, and send them to other information processing devices via the communication network. To, and a data synchronous transmission processing unit that executes processing.
この際、メッセージキュー処理部で、同期要求の保存に応じて、当該同期要求に対する同期要求受領結果を直ちにアプリケーション処理部へ返送するようにしてもよい。 At this time, the message queue processing unit may immediately return the synchronization request receipt result for the synchronization request to the application processing unit according to the storage of the synchronization request.
また、データ同期送信処理部で、同期要求を送信する際、データ同期受信処理部との間で、同期要求間の送信順序が受信側で保証されるデータ送信プロトコルを用いるようにしてもよい。 Further, when the data synchronization transmission processing unit transmits the synchronization request, a data transmission protocol in which the transmission order between the synchronization requests is guaranteed on the reception side may be used with the data synchronization reception processing unit.
また、データ同期送信処理部で、メッセージキュー処理部から取得した複数の同期要求に含まれる差分情報を1つの新たな差分情報に一括し、当該新たな差分情報を含む新たな同期要求を、通信ネットワークを介して他の情報処理装置へ送信するようにしてもよい。 Also, the data synchronization transmission processing unit collects the difference information included in the plurality of synchronization requests acquired from the message queue processing unit into one new difference information, and communicates the new synchronization request including the new difference information. You may make it transmit to another information processing apparatus via a network.
また、同期要求ごとに、当該同期要求と対応する排他情報を記憶する同期排他処理部をさらに設け、アプリケーション処理部で、同期要求をメッセージキュー処理部へ保存する際、当該同期要求と対応する排他情報として当該同期要求の処理種別を示す処理種別情報を含む排他情報を、同期排他処理部へ登録し、データ同期送信処理部で、メッセージキュー処理部から同期要求を取得して第2の情報処理装置へ送信する際、同期排他処理部により、当該同期要求の処理種別に該当する排他情報のうち、データ同期処理が未完了で当該同期要求より先にデータ同期処理すべき同期要求に関する排他情報がないことを確認した後、当該同期要求を第2の情報処理装置へ送信するようにしてもよい。 In addition, for each synchronization request, a synchronization exclusion processing unit that stores exclusive information corresponding to the synchronization request is further provided, and when the application processing unit saves the synchronization request in the message queue processing unit, an exclusion corresponding to the synchronization request is provided. The exclusive information including the processing type information indicating the processing type of the synchronous request as information is registered in the synchronous exclusive processing unit, the data synchronous transmission processing unit acquires the synchronous request from the message queue processing unit, and performs the second information processing. At the time of transmission to the device, the exclusive synchronization processing unit includes exclusive information related to the synchronization request that is not yet completed and that should be processed before the synchronization request. After confirming the absence, the synchronization request may be transmitted to the second information processing apparatus.
また、本発明にかかる他の情報処理装置は、通信ネットワークを介して他の情報処理装置と接続されて、他の情報処理装置との間で通信ネットワークを介してデータ通信を行うことにより、他の情報処理装置で記憶する第1の記憶データと、自己に設けられた記憶部で記憶する第2の記憶データとを同期させる情報処理装置であって、他の情報処理装置から受信した同期要求を順次保存する同期要求記憶部と、同期要求記憶部の同期要求に含まれる、第1の記憶データに対する更新の前後における第1の記憶データの差分に相当する差分情報に基づいて、記憶部で記憶する第2の記憶データを更新することにより、第1および第2の記憶データを同期させるデータ同期処理を実行するデータ同期受信処理部とを備え、データ同期受信処理部で、第2の記憶部のデータ同期処理を行う際、同期要求記憶部で保存している同期要求のうちから、1の記憶データに対して実行されたデータ更新処理の順序と一致した順序にしたがって、記憶部に対して最も先にデータ同期処理すべき同期要求を取得し、当該同期要求に含まれる差分情報に基づいて記憶部のデータ同期処理を行うようにしたものである。 Further, another information processing apparatus according to the present invention is connected to another information processing apparatus via a communication network, and performs data communication with the other information processing apparatus via the communication network. Information processing apparatus for synchronizing the first storage data stored in the information processing apparatus and the second storage data stored in the storage unit provided in the information processing apparatus, the synchronization request received from another information processing apparatus The synchronization request storage unit for sequentially storing the data, and the storage unit based on the difference information corresponding to the difference between the first storage data before and after the update to the first storage data included in the synchronization request of the synchronization request storage unit A data synchronization reception processing unit that executes data synchronization processing for synchronizing the first and second storage data by updating the second storage data to be stored; When performing the data synchronization processing of the second storage unit, out of the synchronization requests stored in the synchronization request storage unit, according to the order that matches the order of the data update processing executed for one storage data, A synchronization request to be subjected to data synchronization processing first is acquired from the storage unit, and data synchronization processing of the storage unit is performed based on difference information included in the synchronization request.
この際、データ同期受信処理部で、通信ネットワークにおける同期要求の最大遅延時間より長い待機時間だけ同期要求記憶部で待機させた同期要求のうちから、第1の記憶部に対して実行したデータ更新処理の順序と一致した順序にしたがって、最も先にデータ同期処理すべき同期要求を取得するようにしてもよい。 At this time, the data update executed by the data synchronization reception processing unit to the first storage unit from among the synchronization requests that are kept in the synchronization request storage unit for a standby time longer than the maximum delay time of the synchronization request in the communication network. A synchronization request to be subjected to data synchronization processing first may be acquired in accordance with an order that matches the processing order.
また、本発明にかかる情報処理方法は、通信ネットワークを介して他の情報処理装置と接続されて、他の情報処理装置との間で通信ネットワークを介してデータ通信を行うことにより、自己に設けられた記憶部で記憶する第1の記憶データと、他の情報処理装置で記憶する第2の記憶データとを同期させる情報処理装置で用いられる情報処理方法であって、アプリケーション処理部が、記憶部で記憶する記憶データを更新するアプリケーションを実行するアプリケーション処理ステップと、メッセージキュー処理部が、更新の前後における第1の記憶データの差分に相当する差分情報を含む、アプリケーションからの同期要求を、順次保存するメッセージキュー処理ステップと、データ同期送信処理部が、データ同期送信処理として、メッセージキュー処理部から同期要求をそれぞれが保存された順序で順に取得し、通信ネットワークを介して他の情報処理装置へ送信する、処理を実行するデータ同期送信処理ステップとを備えている。 In addition, the information processing method according to the present invention is provided to itself by being connected to another information processing apparatus via a communication network and performing data communication with the other information processing apparatus via the communication network. An information processing method used in an information processing device for synchronizing first storage data stored in a stored storage unit and second storage data stored in another information processing device, wherein the application processing unit stores An application processing step for executing an application for updating storage data stored in the storage unit, and a message queue processing unit including a synchronization request from the application including difference information corresponding to a difference between the first storage data before and after the update, The message queue processing step for storing sequentially and the data synchronous transmission processing unit perform message synchronization processing as data synchronous transmission processing. Each synchronization request from Jikyu processing unit acquires the order in the order in which they are stored, via the communication network to another information processing apparatus, and a data synchronous transmission processing step of executing a process.
この際、メッセージキュー処理ステップで、同期要求の保存に応じて、当該同期要求に対する同期要求受領結果を直ちにアプリケーション処理部へ返送するようにしてもよい。 At this time, in the message queue processing step, the synchronization request reception result for the synchronization request may be immediately returned to the application processing unit according to the storage of the synchronization request.
また、データ同期送信処理ステップで、同期要求を送信する際、データ同期受信処理部との間で、同期要求間の送信順序が受信側で保証されるデータ送信プロトコルを用いるようにしてもよい。 Further, when transmitting the synchronization request in the data synchronization transmission processing step, a data transmission protocol in which the transmission order between the synchronization requests is guaranteed on the reception side with the data synchronization reception processing unit may be used.
また、データ同期送信処理ステップで、メッセージキュー処理部から取得した複数の同期要求に含まれる差分情報を1つの新たな差分情報に一括し、当該新たな差分情報を含む新たな同期要求を、通信ネットワークを介して他の情報処理装置へ送信するようにしてもよい。 Further, in the data synchronization transmission processing step, the difference information included in the plurality of synchronization requests acquired from the message queue processing unit is bundled into one new difference information, and a new synchronization request including the new difference information is communicated. You may make it transmit to another information processing apparatus via a network.
また、同期排他処理部が、同期要求ごとに、当該同期要求と対応する排他情報を記憶する同期排他処理ステップをさらに設け、アプリケーション処理ステップで、同期要求をメッセージキュー処理部へ保存する際、当該同期要求と対応する排他情報として当該同期要求の処理種別を示す処理種別情報を含む排他情報を、同期排他処理部へ登録し、データ同期送信処理ステップで、メッセージキュー処理部から同期要求を取得して第2の情報処理装置へ送信する際、同期排他処理部により、当該同期要求の処理種別に該当する排他情報のうち、データ同期処理が未完了で当該同期要求より先にデータ同期処理すべき同期要求に関する排他情報がないことを確認した後、当該同期要求を第2の情報処理装置へ送信するようにしてもよい。 In addition, for each synchronization request, the synchronization exclusion processing unit further includes a synchronization exclusion processing step for storing exclusive information corresponding to the synchronization request, and when the synchronization request is stored in the message queue processing unit in the application processing step, Register exclusive information including processing type information indicating the processing type of the synchronous request as exclusive information corresponding to the synchronous request in the synchronous exclusive processing unit, and acquire the synchronous request from the message queue processing unit in the data synchronous transmission processing step. In the exclusive information corresponding to the processing type of the synchronization request, the data synchronization processing is incomplete and should be processed before the synchronization request by the synchronization exclusion processing unit. After confirming that there is no exclusive information regarding the synchronization request, the synchronization request may be transmitted to the second information processing apparatus.
また、本発明にかかる他の情報処理方法は、通信ネットワークを介して他の情報処理装置と接続されて、他の情報処理装置との間で通信ネットワークを介してデータ通信を行うことにより、他の情報処理装置で記憶する第1の記憶データと、自己に設けられた記憶部で記憶する第2の記憶データとを同期させる情報処理装置で用いられる情報処理方法であって、同期要求記憶部が、他の情報処理装置から受信した同期要求を順次保存する同期要求記憶ステップと、データ同期受信処理部が、同期要求記憶部の同期要求に含まれる、第1の記憶データに対する更新の前後における第1の記憶データの差分に相当する差分情報に基づいて、記憶部で記憶する第2の記憶データを更新することにより、第1および第2の記憶データを同期させるデータ同期処理を実行するデータ同期受信処理ステップとを備え、データ同期受信処理ステップで、第2の記憶部のデータ同期処理を行う際、同期要求記憶部で保存している同期要求のうちから、1の記憶データに対して実行されたデータ更新処理と一致した順序にしたがって、記憶部に対して最も先にデータ同期処理すべき同期要求を取得し、当該同期要求に含まれる差分情報に基づいて記憶部のデータ同期処理を行うようにしたものである。 Further, another information processing method according to the present invention is connected to another information processing apparatus via a communication network and performs data communication with the other information processing apparatus via the communication network. An information processing method used in an information processing apparatus for synchronizing first storage data stored in an information processing apparatus and second storage data stored in a storage section provided in the information processing apparatus, the synchronization request storage section The synchronization request storage step for sequentially storing the synchronization requests received from other information processing devices and the data synchronization reception processing unit before and after the update to the first storage data included in the synchronization request of the synchronization request storage unit Data for synchronizing the first and second storage data by updating the second storage data stored in the storage unit based on the difference information corresponding to the difference between the first storage data. A data synchronization reception processing step for executing the synchronization processing, and when performing the data synchronization processing of the second storage unit in the data synchronization reception processing step, among the synchronization requests stored in the synchronization request storage unit, 1 In accordance with the order that coincides with the data update processing executed for the stored data, the synchronization request to be data synchronization processed first is acquired from the storage unit, and stored based on the difference information included in the synchronization request Data synchronization processing is performed.
また、本発明にかかるプログラムは、コンピュータを、前述したいずれか1つに記載の情報処理装置を構成する各部として機能させるためのプログラムである。 Further, the program according to the present invention is a program for causing a computer to function as each unit constituting the information processing apparatus described in any one of the above.
本発明によれば、アプリケーションの処理負担を、同期要求を出力するという極めて軽微な程度まで削減できるとともに、アプリケーション側拠点でのデータ更新処理と他方の拠点でのデータ同期処理とを分離できる。
これにより、アプリケーションに対するデータ同期のための処理負担を大幅に削減でき、アプリケーションの高速応答性と、他方の拠点でのサービス停止に対する柔軟性を得ることが可能となる。
According to the present invention, the processing load on the application can be reduced to a very slight level of outputting a synchronization request, and the data update process at the application side base and the data synchronization process at the other base can be separated.
As a result, the processing load for data synchronization with respect to the application can be greatly reduced, and high-speed response of the application and flexibility for stopping the service at the other base can be obtained.
次に、本発明の実施の形態について図面を参照して説明する。
[第1の実施の形態]
まず、図1を参照して、本発明の第1の実施の形態にかかるデータ同期システムについて説明する。図1は、第1の実施の形態にかかるデータ同期システムの構成を示すブロック図である。
Next, embodiments of the present invention will be described with reference to the drawings.
[First Embodiment]
First, a data synchronization system according to a first embodiment of the present invention will be described with reference to FIG. FIG. 1 is a block diagram illustrating the configuration of the data synchronization system according to the first embodiment.
このデータ同期システム1は、通信ネットワーク30を介して相互に接続された情報処理装置(第1の情報処理装置)10と情報処理装置(第2の情報処理装置)20とを含んでいる。
データ同期システム1は、これら情報処理装置10,20間で通信ネットワーク30を介してパケットデータ通信を行うことにより、情報処理装置10に設けられた記憶部(第1の記憶部)12で記憶する記憶データ(第1の記憶データ)12Aと、情報処理装置20に設けられた記憶部(第2の記憶部)22で記憶する記憶データ(第2の記憶データ)22Aとを同期させる機能を有している。
The
The
本実施の形態は、情報処理装置10において、記憶部12で記憶する記憶データ12Aを更新するアプリケーションを実行し、この更新の前後における記憶データ12Aの差分に相当する差分情報を含む、アプリケーションからの同期要求を、順次保存し、これら同期要求をそれぞれが保存された順序で順に取得して、通信ネットワーク30を介して情報処理装置20へ送信し、情報処理装置20において、通信ネットワーク30を介して情報処理装置10からの同期要求を受信し、当該同期要求に含まれる差分情報に基づいて、記憶部22で記憶する記憶データ22Aを更新することにより、記憶データ12A,22Aを同期させる。
In this embodiment, the
[第1の実施の形態の構成]
次に、図1を参照して、本実施の形態にかかるデータ同期システムの構成について詳細に説明する。
情報処理装置10は、全体としてサーバー装置やワークステーションなど、コンピュータを含む情報処理装置から構成されており、主な機能部として、アプリケーション処理部11、記憶部12、メッセージキュー処理部13、およびデータ同期送信処理部14が設けられている。
[Configuration of First Embodiment]
Next, the configuration of the data synchronization system according to the present embodiment will be described in detail with reference to FIG.
The
アプリケーション処理部11は、各種アプリケーションを実行する機能を有している。このアプリケーションは、外部装置(図示せず)やキーボード操作により入力された要求に応じて、記憶部12で記憶する記憶データ12Aを用いた各種情報処理を行う機能と、この情報処理に応じて記憶データ12Aの更新が必要となった場合に、記憶データ12Aの更新を指示する更新要求を出力する機能と、当該更新による記憶データ12Aと記憶データ22Aとのデータ同期を指示する同期要求を出力する機能と、当該情報処理結果を当該外部装置や画面表示部(図示せず)へ出力する機能を有している。
The
同期要求と更新要求は、ともに処理制御メッセージの1つである。同期要求には、記憶部12での更新前後における記憶データ12Aの差分に相当する差分情報、例えばアプリケーションからの更新要求において記憶データ12Aの更新に用いた更新データからなる差分情報を含んでいる。更新要求には、上記更新データに加えて、より詳細な更新指示、例えば記憶データ12Aで構築されるデータベースのテーブル形式やデータ書式に合わせた更新指示が含まれている。
The synchronization request and the update request are both processing control messages. The synchronization request includes difference information corresponding to the difference between the
記憶部12は、ハードディスクなどの記憶装置からなり、アプリケーション処理部11で実行するアプリケーションで処理する各種処理情報を記憶データ12Aとして記憶する機能を有している。データ同期システム1では、1つの同期要求で、記憶部12内のすべての記憶データ12Aをデータ同期の対象としてもよく、データファイル単位など、個別の記憶データ12Aをデータ同期の対象としてもよい。また、記憶データ12Aは、データベースを構築するデータであってもよく、単純なリストデータであってもよい。
The
メッセージキュー処理部13は、半導体メモリやハードディスクなどの記憶装置からなるメッセージキューを有し、アプリケーションからの同期要求を、順次、メッセージキューへ保存する機能を有している。
The message
データ同期送信処理部14は、データ同期送信処理を実行する機能を有している。このデータ同期送信処理は、メッセージキュー処理部13のメッセージキューに保存されている同期要求を、それぞれが保存された順序で順に取得する処理と、取得した同期要求を通信ネットワーク30を介して情報処理装置20へ送信する、処理を実行する処理とを含んでいる。
The data synchronous
記憶データ12A,22Aのデータ同期を行う際、各同期要求間において処理順序の制御を必要とする場合がある。例えば、処理Aによって記憶データを保存した後、処理Bによって記憶データを更新した場合、処理A,Bの処理順序に基づき記憶データに対する更新順序を制御する必要がある。
When data synchronization of the stored
このような場合には、データ同期送信処理部14で、一連の同期要求を送信する際、後述する情報処理装置20のデータ同期受信処理部25との間で、これら同期要求間の送信順序が、受信側すなわちデータ同期受信処理部25で保証されるデータ送信プロトコル、例えばTCPなどのプロトコルを用いればよい。これにより、情報処理装置20の記憶データ22Aを、同期要求の送信順序に従って、記憶データ12Aと同一の順序で更新することができる。
In such a case, when the data synchronization
情報処理装置10における機能部のうち、アプリケーション処理部11、メッセージキュー処理部13、およびデータ同期送信処理部14は、演算処理部から構成されている。演算処理部は、CPUなどのマイクロプロセッサとその周辺回路を有し、記憶部12やその他の記憶部(図示せず)からプログラムを読み出して実行することにより、各種機能部を実現する機能を有している。このプログラムは、外部装置(図示せず)や記録媒体(図示せず)から予め読み込んで記憶部へ格納される。
なお、情報処理装置10には、データ通信インターフェース部、キーボードやマウスなどを用いた操作入力部、LCDなどを用いた画面表示部など、一般的な情報処理装置と同様の構成が設けられているものとする。
Among the functional units in the
The
情報処理装置20は、全体としてサーバー装置やワークステーションなど、コンピュータを含む情報処理装置から構成されており、主な機能部として、アプリケーション処理部21、記憶部22、およびデータ同期受信処理部25が設けられている。
The
アプリケーション処理部21は、各種アプリケーションを実行する機能を有している。このアプリケーションは、外部装置(図示せず)やキーボード操作により入力された要求に応じて、記憶部22で記憶する記憶データ22Aを用いた各種情報処理を実行し、その情報処理結果を当該外部装置や画面表示部(図示せず)へ出力する機能を有している。
The
記憶部22は、ハードディスクなどの記憶装置からなり、アプリケーション処理部21で実行するアプリケーションで処理する各種処理情報を記憶データ22Aとして記憶する機能を有している。なお、記憶データ22Aは、データベースを構築するデータであってもよく、単純なリストデータであってもよい。
The
データ同期受信処理部25は、データ同期送信処理を実行する機能を有している。このデータ同期受信処理は、通信ネットワーク30を介して情報処理装置10からの同期要求を受信し、当該同期要求に含まれる差分情報に基づいて、記憶部22で記憶する記憶データ22Aを更新することにより、記憶データ12A,22Aを同期させる処理を含んでいる。この際、データ同期受信処理部25は、受信した同期要求ごとに記憶データ22Aを更新してもよいが、受信した同期要求が所定容量や件数を満たした場合、これら同期要求をまとめて記憶データ22Aを更新してもよく、あるいは所定期間中に受信した複数の同期要求をまとめて記憶データ22Aを更新してもよい。
The data synchronization
情報処理装置20における機能部のうち、アプリケーション処理部21およびデータ同期受信処理部25は、演算処理部から構成されている。演算処理部は、CPUなどのマイクロプロセッサとその周辺回路を有し、記憶部22やその他の記憶部(図示せず)からプログラムを読み出して実行することにより、各種機能部を実現する機能を有している。このプログラムは、外部装置(図示せず)や記録媒体(図示せず)から予め読み込んで記憶部へ格納される。
なお、情報処理装置20には、データ通信インターフェース部、キーボードやマウスなどを用いた操作入力部、LCDなどを用いた画面表示部など、一般的な情報処理装置と同様の構成が設けられているものとする。
Of the functional units in the
The
[第1の実施の形態の動作]
次に、図2および図3を参照して、本実施の形態にかかるデータ同期システムの動作について説明する。図2は、第1の実施の形態にかかるデータ同期システムの動作を示すシーケンス図である。図3は、第1の実施の形態にかかるデータ同期システムの動作を示すフロー図である。
[Operation of First Embodiment]
Next, the operation of the data synchronization system according to the present embodiment will be described with reference to FIGS. FIG. 2 is a sequence diagram illustrating an operation of the data synchronization system according to the first embodiment. FIG. 3 is a flowchart illustrating the operation of the data synchronization system according to the first embodiment.
情報処理装置10のアプリケーション処理部11は、アプリケーションを起動し、入力された要求に応じて(ステップ100)、記憶部12の記憶データ12Aを用いた情報処理を実行する。
ここで、記憶データ12Aの更新が発生した場合、アプリケーション処理部11は、同期要求と前後して、アプリケーションから出力された更新要求を、記憶部12に対して出力する(ステップ101)。
記憶部12は、この更新要求を受け取って記憶データ12Aを更新し(ステップ102)、その更新結果をアプリケーション処理部11へ返送する(ステップ103)。
The
Here, when the
The
また、アプリケーション処理部11は、いわゆるenqueue処理により、アプリケーションからの同期要求を、メッセージキュー処理部13に対して出力する(ステップ104)。
メッセージキュー処理部13は、この同期要求を受け取って、メッセージキューへ順次保存し、保存した旨の同期要求受領結果を直ちにアプリケーション処理部11へ返送する(ステップ105)。
アプリケーション処理部11は、記憶部12からの更新結果やメッセージキュー処理部13での同期結果、さらにはアプリケーションでの情報処理結果に基づいて、ステップ100で入力された要求に対する応答を出力する(ステップ106)。
Further, the
The message
The
この際、ステップ101〜103による記憶データ12Aの更新については、ステップ104〜106による同期要求処理より後に実行してもよい。但し、ステップ101〜103による記憶データ12Aの更新を、ステップ104〜106による同期要求処理より先に実行することで、例えばステップ103による更新結果によりステップ102によるデータ更新の失敗が通知された場合、ステップ104〜106による同期要求処理を省くこともでき、不要な処理の実行を抑止することが可能となる。
At this time, the update of the stored
一方、データ同期送信処理部14は、メッセージキュー処理部13のメッセージキューへの同期要求の保存を契機に起動されて、いわゆるdequeue処理により、メッセージキュー処理部13に対して取得要求を出力し、新たな同期要求がメッセージキューに存在する場合には、休むことなく連続的に取得要求を出力する(ステップ110)。
メッセージキュー処理部13は、データ同期送信処理部14からの取得要求に応じて、メッセージキューに保存されている同期要求を、それぞれの保存順序に応じて順に取得して、データ同期送信処理部14へ出力する(ステップ111)。
On the other hand, the data synchronous
In response to the acquisition request from the data synchronous
データ同期送信処理部14は、この同期要求を受け取って、通信ネットワーク30を介して情報処理装置20へ送信する(ステップ120)。
情報処理装置20のデータ同期受信処理部25は、情報処理装置10からの同期要求を受信して受信キューへ一旦保存し、当該同期要求に基づいてデータ同期受信処理を実行して記憶部22の記憶データ22Aの更新を要求する。
情報処理装置20の記憶部22は、データ同期受信処理部25により受け取った、情報処理装置10からの同期要求に基づいて、記憶データ22Aを更新する(ステップ121)。これにより、記憶データ12A,22Aがデータ同期される。
この後、記憶部22は、当該同期要求による同期結果を、データ同期受信処理部25により、通信ネットワーク30を介して情報処理装置10へ返送する(ステップ122)。
The data synchronization
The data synchronization
The
Thereafter, the
[第1の実施の形態の効果]
このように、本実施の形態は、情報処理装置10において、アプリケーション処理部11により、記憶部12で記憶する記憶データ12Aを更新するアプリケーションを実行し、メッセージキュー処理部13により、当該更新前後における記憶データ12Aの差分に相当する差分情報を含む、アプリケーションからの同期要求を、順次保存し、データ同期送信処理部14により、メッセージキュー処理部13から同期要求をそれぞれが保存された順序で順に取得し、通信ネットワーク30を介して情報処理装置20へ送信し、情報処理装置20において、データ同期受信処理部25により、通信ネットワーク30を介して情報処理装置10からの同期要求を受信し、当該同期要求に含まれる差分情報に基づいて、記憶部22で記憶する第2の記憶データ22Aを更新することにより、記憶データ12A,22Aを同期させている。
[Effect of the first embodiment]
Thus, in the present embodiment, in the
したがって、記憶データ12Aを更新するごとにアプリケーションから出力される同期要求が、順次、メッセージキュー処理部13へ保存されて、順次、データ同期送信処理部14から情報処理装置20へ送信されるため、アプリケーションの処理負担を、同期要求を出力するという極めて軽微な程度まで削減できるとともに、アプリケーション側拠点でのデータ更新処理と他方の拠点でのデータ同期処理とを分離できる。
これにより、アプリケーションに対するデータ同期のための処理負担を大幅に削減でき、他方の拠点でのサービス停止に対する柔軟性を得ることが可能となる。
Therefore, each time the stored
As a result, the processing load for data synchronization with respect to the application can be greatly reduced, and the flexibility to stop the service at the other base can be obtained.
通常、ディザスタリカバリのために遠隔地間で冗長化されたシステムにおいて、通信相手となるシステムが自律的に通信先となる当該システムを切り替える利用形態においては、冗長化されたシステムに到着する要求はほとんどが独立な更新を行うものであり、片方の系に閉じて一貫していれば十分である。
しかし、稀に系切り替え動作の前後において、順序を制御すべき要求が両系に到着する場合があり得る。これに対し厳密な制御を行うことは、例えば前述した非特許文献1の技術を用いれば可能であるが、レアケースに対応するために全体の性能を落としてしまう問題がある。
Normally, in a system that is redundant between remote locations for disaster recovery, in a usage mode in which the system that is the communication partner autonomously switches the system that is the communication destination, the request to arrive at the redundant system is Most of them are independent updates, and it is enough to be closed and consistent in one system.
However, in rare cases, a request for controlling the order may arrive at both systems before and after the system switching operation. On the other hand, it is possible to perform strict control, for example, by using the technique of
そのため、発生を未然に防ぐ処理を省くことによって性能劣化を回避する方法が考えられる。ただし、この場合には、両系にデータ一貫性に影響するようなトランザクションが同時に到着してデータ不整合が起こる。
データ不整合が検知された場合は、これを検知しアプリケーションも含めてロールバックする公知の技術や、自動的にデータ不整合を復旧する公知の技術を用いればよい。
For this reason, a method for avoiding performance degradation by omitting a process for preventing the occurrence is considered. In this case, however, transactions that affect data consistency arrive at both systems simultaneously, resulting in data inconsistency.
When data inconsistency is detected, a known technique for detecting this and rolling back the application including the application, or a known technique for automatically restoring the data inconsistency may be used.
また、本実施の形態では、メッセージキュー処理部13へ同期要求が保存された際、当該同期要求に対応する応答として同期要求受領結果が直ちにアプリケーションへ返送されるため、アプリケーションでの同期処理に対する待ち時間を大幅に削減でき、アプリケーションの高速応答性を得ることが可能となる。
In this embodiment, when a synchronization request is stored in the message
また、本実施の形態では、データ同期送信処理部14により、同期要求を送信する際、データ同期受信処理部25との間で、同期要求間の送信順序が受信側で保証されるデータ送信プロトコルを用いてもよい。
これにより、情報処理装置20の記憶データ22Aを、同期要求の送信順序に従って、記憶データ12Aと同一の順序で更新することができ、各同期要求間において処理順序の制御を必要とする場合でも、データ同期処理を正確に実施することが可能となる。
In the present embodiment, when the synchronization request is transmitted by the data synchronization
Thereby, the
[第2の実施の形態]
次に、図4および図5を参照して、本発明の第2の実施の形態にかかるデータ同期システムについて説明する。図4は、第2の実施の形態にかかるデータ同期システムの動作を示すシーケンス図である。図5は、第2の実施の形態にかかるデータ同期システムの動作を示すフロー図である。
本実施の形態では、データ同期システム1におけるデータ同期処理を並列化して、処理効率を向上させる場合について説明する。
[Second Embodiment]
Next, a data synchronization system according to the second embodiment of the present invention will be described with reference to FIG. 4 and FIG. FIG. 4 is a sequence diagram illustrating an operation of the data synchronization system according to the second embodiment. FIG. 5 is a flowchart illustrating the operation of the data synchronization system according to the second embodiment.
In the present embodiment, a case will be described in which data synchronization processing in the
本実施の形態において、アプリケーション処理部11は、記憶部12の更新を含む複数の処理を並列的に実行する機能を有し、データ同期送信処理部14は、複数のデータ同期送信処理を並列的に実行する機能を有し、データ同期受信処理部25は、複数のデータ同期受信処理を並列的に実行する機能を有している。
In the present embodiment, the
このように、データ同期処理を並列化した場合、これら処理間の処理順序が問題となる。このため、本実施の形態において、データ同期受信処理部25は、並列的に実行する複数の処理を排他的に制御する排他制御機能とを含み、この排他制御機能を用いて、データ同期送信処理部14から受信した同期要求の処理順序を確保しつつ、複数のデータ同期受信処理を並列的に実行する機能を有している。
Thus, when data synchronization processing is parallelized, the processing order between these processing becomes a problem. For this reason, in the present embodiment, the data synchronous
1つのリソースを複数の処理が共用する場合、当該リソースを利用する期間がこれら処理間で競合する場合がある。排他制御とは、処理ごとにリソースを利用する順序を決定して、このような競合を調停する機能である。
前述したように、処理Aによって記憶データを保存した後、処理Bによって記憶データを更新した場合、処理A,Bの処理順序に基づき記憶データに対する更新順序を制御する必要がある。この際、ユーザごとに別個の記憶データが用いられる場合、ユーザ間では競合が発生せず、ユーザごとに記憶データに対する更新順序を制御する必要がある。
When a plurality of processes share one resource, the period for using the resource may compete between these processes. Exclusive control is a function that determines the order in which resources are used for each process and arbitrates such contention.
As described above, when the storage data is updated by the process B after the storage data is saved by the process A, it is necessary to control the update order for the storage data based on the process order of the processes A and B. At this time, when separate stored data is used for each user, no conflict occurs between users, and it is necessary to control the update order for the stored data for each user.
本実施の形態では、データ同期受信処理部25で、データ同期受信処理を並列的に実行させるため、記憶部22に対する更新順序を排他制御により保証している。
排他制御機能としては、一般的な情報処理装置で利用されている、mutexなどの公知の処理制御技術を用いればよい。このような排他制御機能では、排他制御すべき複数の処理ごとに排他制御資源を割り当て、排他制御資源間では排他制御することなく処理を実行するものとなっている。
In this embodiment, since the data synchronous
As the exclusive control function, a known process control technique such as mutex used in a general information processing apparatus may be used. In such an exclusive control function, an exclusive control resource is assigned to each of a plurality of processes to be exclusively controlled, and the process is executed without exclusive control between the exclusive control resources.
前述のように、ユーザごとに記憶データの更新順序を制御する必要がある場合、これらユーザごとに排他制御資源の割り当てを行えばよい。また、ユーザだけでなく、ドメインや装置など、排他制御の対象ごとに、排他制御資源の割り当てを行えばよい。 As described above, when it is necessary to control the update order of stored data for each user, an exclusive control resource may be allocated for each user. Further, exclusive control resources may be allocated for each exclusive control target, such as a domain or a device, as well as a user.
この際、アプリケーションまたはアプリケーション処理部11で、当該アプリケーションを実行しているユーザID、ユーザ名、ドメイン名、装置ID、装置名、アプリケーション名など、処理を識別するための識別情報を取得して、同期要求に対して排他制御の要否とともに付加して、メッセージキュー処理部13へ通知すればよい。
あるいは、これら識別情報に対する排他制御の要否を示す管理情報を予め記憶部に設定しておき、同期要求で通知された識別情報に基づき、排他制御の要否を確認するようにしてもよい。
At this time, the application or
Alternatively, management information indicating whether or not exclusive control is required for these pieces of identification information may be set in the storage unit in advance, and the necessity or absence of exclusive control may be confirmed based on the identification information notified by the synchronization request.
また、排他制御の対象数が多い場合には、例えば競合しないユーザ間で同一の排他制御資源を共用することもできる。この場合には、ハッシュ関数を使用して、共用するユーザIDから共通のID(添え字)を生成し、これらユーザに対して、当該IDと対応する排他制御資源の割り当てを行えばよい。この場合、これらユーザ間で同期処理が排他制御されることになる。
通常、排他制御資源は、排他制御資源プールとして予め用意されており、いずれかの処理に排他制御資源を割り当てた時点で、その処理の負担が小さくてもある程度の処理負担が情報処理装置内で発生する。このため、排他制御資源を複数の処理で有効利用することで、情報処理装置の処理効率を高めることが可能となる。
Further, when the number of exclusive control targets is large, for example, the same exclusive control resource can be shared among non-conflicting users. In this case, a common ID (subscript) may be generated from the shared user ID using a hash function, and an exclusive control resource corresponding to the ID may be assigned to these users. In this case, the synchronization processing is exclusively controlled between these users.
Normally, an exclusive control resource is prepared in advance as an exclusive control resource pool, and when an exclusive control resource is allocated to one of the processes, a certain amount of processing load is generated in the information processing apparatus even if the processing load is small. appear. For this reason, it is possible to increase the processing efficiency of the information processing apparatus by effectively using the exclusive control resource in a plurality of processes.
また、これらアプリケーション処理部11、データ同期送信処理部14、およびデータ同期受信処理部25において、それぞれの処理を並列的に実行する機能として、演算処理部が提供するマルチスレッド機能を利用すればよい。マルチスレッド機能は、一般的な情報処理装置で利用されている公知の処理制御技術である。
なお、本実施の形態にかかる情報処理装置10,20におけるその他の構成については、前述した第1の実施の形態と同じであり、ここでの詳細な説明は省略する。
In the
Note that other configurations of the
[第2の実施の形態の動作]
次に、図4および図5を参照して、本実施の形態にかかるデータ同期システムの動作について説明する。図4および図5において、前述した図2および図3と同じまたは同等部分については、同一符号を付してある。
[Operation of Second Embodiment]
Next, the operation of the data synchronization system according to the present embodiment will be described with reference to FIGS. 4 and 5, the same or equivalent parts as those in FIGS. 2 and 3 described above are denoted by the same reference numerals.
本実施の形態では、アプリケーション処理部11、メッセージキュー処理部13、およびデータ同期送信処理部14において、マルチスレッド機能によりそれぞれの処理が並列的に実行される。
このため、これら機能部間でやり取りされる同期要求(ステップ104)、同期結果(ステップ105)、取得要求(ステップ110)、同期要求(ステップ111)、およびアプリケーション処理部11と記憶部12との間でやり取りされる更新要求(ステップ101)、および更新結果(ステップ103)は、それぞれ並列してやり取りされる。
In the present embodiment, in the
Therefore, a synchronization request (step 104), a synchronization result (step 105), an acquisition request (step 110), a synchronization request (step 111), and the
データ同期送信処理部14は、メッセージキュー処理部13のメッセージキューへの同期要求の保存を契機に起動されて、メッセージキュー処理部13に対して並列的に取得要求を出力する(ステップ110)。
メッセージキュー処理部13は、データ同期送信処理部14からの取得要求に応じて、メッセージキューに保存されている同期要求を、それぞれの保存順序に応じて順に取得して、データ同期送信処理部14へ出力する(ステップ111)。
データ同期送信処理部14は、データ同期送信処理を並列的に実行することにより、メッセージキュー処理部13から同期要求を順次受け取るとともに、これら同期要求を並列的に通信ネットワーク30を介して情報処理装置20へ送信する(ステップ220)。
The data synchronous
In response to the acquisition request from the data synchronous
The data synchronous
情報処理装置20のデータ同期受信処理部25は、情報処理装置10からの同期要求を受信して受信キューへ一旦保存し、これら同期要求に対して排他制御を行って、これら同期要求の処理順序を決定する(ステップ221)。
図4の例では、データ同期受信処理部25から記憶部22に対して、2回に分けて同期要求が通知されて、記憶部22の記憶データ22Aが更新されている。すなわち、データ同期受信処理部25は、1回目の通知でデータ同期受信処理を並列的に実行することにより複数の同期要求を並列的に通知し(ステップ222)、これに応じて記憶部22は、記憶データ22Aをデータ更新した後(ステップ223)、同期結果を返送し(ステップ224)、データ同期受信処理部25は、この同期結果を通信ネットワーク30を介して情報処理装置10へ返送する。
The data synchronization
In the example of FIG. 4, the synchronization request is notified in two steps from the data synchronization
データ同期受信処理部25は、1回目の同期要求に対する同期結果を記憶部22から受信した後、2回目の同期要求を通知し(ステップ225)、これに応じて記憶部22は、記憶データ22Aをデータ更新した後(ステップ226)、同期結果を返送し(ステップ227)、データ同期受信処理部25は、この同期結果を通信ネットワーク30を介して情報処理装置10へ返送する。なお、並列的に通知した同期要求の順序関係については、例えば非特許文献1でも述べられているように、データベース・トランザクション間に関する処理順序に関する一般的な制約条件であり、ここでの説明は省略する。
After receiving the synchronization result for the first synchronization request from the
[第2の実施の形態の効果]
このように、本実施の形態では、アプリケーション処理部11で、記憶部12の更新を含む複数の処理を並列的に実行し、データ同期受信処理部25に、並列的に実行する複数の処理を排他的に制御する排他制御機能を含み、この排他制御機能を用いて、データ同期送信処理部14から受信した同期要求の処理順序を確保しつつ、複数のデータ同期送信処理を並列的に実行し、データ同期受信処理部25で、複数のデータ同期受信処理を並列的に実行するようにしたので、データ同期順序を確保しつつ、データ同期処理の処理効率を向上させることが可能となる。
これにより、情報処理装置10,20間の同期要求や同期結果の送達遅延が大きな環境でも、応答を待つことなく実行できる処理数が増えるため、スループットを大幅に向上させることができる。
[Effect of the second embodiment]
As described above, in the present embodiment, the
As a result, the number of processes that can be executed without waiting for a response increases even in an environment where the synchronization request between the
本実施の形態では、情報処理装置20のデータ同期受信処理部25に排他制御機能を設けた場合を例として説明したが、この排他制御機能については、情報処理装置10,20のいずれか一方に設ければよく、情報処理装置10の場合にはデータ同期送信処理部14に設ければよい。
但し、情報処理装置10は、障害等によってサービス停止が起こる前に、いち早くデータを情報処理装置20へ送信することが望ましいため、つまり、情報処理装置10はデータ送信の処理負荷が小さい方が望ましいため、この排他制御は情報処理装置20が備えることが望ましい。このようにすることで、情報処理装置10が早々にデータを送信することで、その後で情報処理装置10がサービス停止になったとしても、データを受信した情報処理装置20が適切にデータを同期することができる。
In the present embodiment, the case where the exclusive control function is provided in the data synchronous
However, since the
また、情報処理装置20で排他制御を行う際、通信ネットワーク30を介して情報処理装置10から受信した同期要求を順次保存するとともに、保存した当該同期要求に対する同期要求受領結果を直ちに情報処理装置10のデータ同期送信処理部14へ返送するメッセージキュー処理部を設け、データ同期受信処理部25は、このメッセージキュー処理部から同期要求を順に取得してデータ同期受信処理を行うようにしてもよい。
これにより、データ同期送信処理部14は、データ同期受信処理部25でのデータ同期受信処理の終了を待つことなく、送信した同期要求が上記メッセージキュー処理部に保存された時点で、次の同期要求を送信することが可能となる。このため、情報処理装置10における同期要求の送信処理負荷を低減できる。
When the
Thus, the data synchronization
なお、本実施の形態では、アプリケーション処理部11で、記憶部12の更新を含む複数の処理が並列的に実行される場合を想定しているが、このような処理状況としては、アプリケーション処理部11で実行されている1つのアプリケーションが並列的にこれら処理を実行する場合、さらにはアプリケーション処理部11で実行されている複数のアプリケーションが並列的にこれら処理を実行する場合がある。本実施の形態は、これらいずれの場合にも適用でき、前述と同様の作用効果が得られる。
In the present embodiment, it is assumed that the
[第3の実施の形態]
次に、図6および図7を参照して、本発明の第3の実施の形態にかかるデータ同期システムについて説明する。図6は、第3の実施の形態にかかるデータ同期システムの動作を示すシーケンス図である。図7は、第3の実施の形態にかかるデータ同期システムの動作を示すフロー図である。
本実施の形態では、データ同期システム1におけるデータ同期処理を一括化して、処理効率を向上させる場合について説明する。
[Third Embodiment]
Next, a data synchronization system according to the third embodiment of the present invention will be described with reference to FIG. 6 and FIG. FIG. 6 is a sequence diagram illustrating the operation of the data synchronization system according to the third embodiment. FIG. 7 is a flowchart illustrating the operation of the data synchronization system according to the third embodiment.
In the present embodiment, a case will be described in which data synchronization processing in the
本実施の形態において、データ同期送信処理部14は、メッセージキュー処理部13から取得した複数の同期要求に含まれる差分情報を1つの新たな差分情報に一括し、当該新たな差分情報を含む新たな同期要求を、通信ネットワーク30を介して情報処理装置20へ送信する機能を有している。
In the present embodiment, the data synchronization
同期要求には、例えば同じ記憶データ22A内の異なるデータに対して、それぞれ個別差分情報に基づき更新を行うなど、互いの更新内容が競合しない場合も存在する。これら、同期要求に基づくデータ同期処理を個別に実行した場合、同期要求や同期結果のやり取りがそれぞれ必要となる。
In the synchronization request, for example, different data in the same stored
一方、互いの更新内容が競合しない場合、複数の同期要求に含まれる差分情報を1つの新たな差分情報に一括し、新たな差分情報を含む新たな同期要求を生成することができる。例えば、データベース言語の1つであるSQLでは、データベースに対する一連の処理をまとめた1つの手続きとして設定する技術として、ストアドプロシージャ (stored procedure) と呼ばれる処理が設けられている。
データ同期送信処理部14では、このような公知の技術を利用して、複数のデータ同期処理を一括化している。
On the other hand, when the update contents do not conflict with each other, the difference information included in the plurality of synchronization requests can be integrated into one new difference information, and a new synchronization request including the new difference information can be generated. For example, in SQL, which is one of database languages, a process called a stored procedure is provided as a technique for setting a series of processes for a database as one procedure.
The data synchronization
ストアドプロシージャは、一連の更新処理命令をまとめたものであり、データ同期受信処理部25に予め登録しておく。データ同期送信処理部14では、このストアドプロシージャを実行するのに必要なパラメータを、複数の同期要求から生成し、新たな同期要求としてデータ同期受信処理部25へ送信することになる。
これにより更新処理命令を含む同期要求を送信する場合と比較して、データ同期受信処理部25における更新処理命令の解釈などの処理が不要となり、記憶データ22Aに対する更新処理時間を短縮できる。
The stored procedure is a collection of a series of update processing instructions and is registered in advance in the data synchronous
This eliminates the need for processing such as interpretation of the update processing command in the data synchronous
また、多くの場合、情報処理装置20からの同期結果は不要であるため、データ同期送信処理部14では、情報処理装置20へ同期要求を送信した後、これに対する情報処理装置20からの受信確認(ACK)を受け取ったら、直ちに次のデータ同期送信処理を開始して、メッセージキュー処理部13から次の同期要求を取得することができる。
したがって、メッセージキュー処理部13におけるメッセージキューのサイズは、情報処理装置20での処理時間を見込む必要がなくなり、同期要求の送達に関する遅延時間に応じたサイズまで削減することが可能となり、設計の容易性、さらにはリソースの有効利用を実現できる。
なお、本実施の形態にかかる情報処理装置10,20におけるその他の構成については、前述した第1の実施の形態と同じであり、ここでの詳細な説明は省略する。
In many cases, since the synchronization result from the
Therefore, the size of the message queue in the message
Note that other configurations of the
[第3の実施の形態の動作]
次に、図6および図7を参照して、本実施の形態にかかるデータ同期システムの動作について説明する。図6および図7において、前述した図2および図3と同じまたは同等部分については、同一符号を付してある。
ここでは、第2の実施の形態と同様に、アプリケーション処理部11は、マルチスレッド機能に基づき、複数のアプリケーション処理を並列的に実行する機能を有し、データ同期送信処理部14も、マルチスレッド機能に基づき、複数のデータ同期送信処理を並列的に実行する機能を有する場合を例として説明する。
[Operation of Third Embodiment]
Next, the operation of the data synchronization system according to this exemplary embodiment will be described with reference to FIGS. 6 and 7, the same or equivalent parts as those in FIGS. 2 and 3 described above are denoted by the same reference numerals.
Here, as in the second embodiment, the
情報処理装置10のアプリケーション処理部11は、アプリケーション処理スレッド11Aにより、入力された要求に応じて(ステップ300)、記憶部12の記憶データ12Aを用いた情報処理を実行し、その処理結果に応じた応答を出力するとともに(ステップ301)、同期要求をメッセージキュー処理部13に対して出力する(ステップ302)。
The
また、アプリケーション処理部11は、アプリケーション処理スレッド11Bにより、入力された要求に応じて(ステップ303)、記憶部12の記憶データ12Aを用いた情報処理を実行し、その処理結果に応じた応答を出力するとともに(ステップ304)、同期要求をメッセージキュー処理部13に対して出力する(ステップ305)。
メッセージキュー処理部13は、これら同期要求を受け取って、メッセージキューへ順次保存する。
In addition, the
The message
一方、データ同期送信処理部14は、データ同期送信処理スレッド14A,14Bにより、メッセージキュー処理部13のメッセージキューへの同期要求の保存を契機に起動される。
したがって、ステップ302,305で2つの同期要求がメッセージキューに保存された場合、データ同期送信処理スレッド14A,14Bは、これら同期要求を取得する(ステップ310,311)。
On the other hand, the data synchronous
Therefore, when two synchronization requests are stored in the message queue in
この後、データ同期送信処理部14は、これら2つの同期要求について、同期要求の一括化処理を実行して、新たな1つの同期要求を生成し(ステップ312)、データ同期送信処理部14へ出力する(ステップ320)。
情報処理装置20の記憶部22は、データ同期受信処理部25により受け取った、情報処理装置10からの同期要求に基づいて、記憶データ22Aを更新する(ステップ321)。これにより、記憶データ12A,22Aがデータ同期される。
この後、記憶部22は、当該同期要求による同期結果を、データ同期受信処理部25により、通信ネットワーク30を介して情報処理装置10へ返送する(ステップ322)。
Thereafter, the data synchronization
The
Thereafter, the
[第3の実施の形態の効果]
このように、本実施の形態では、データ同期送信処理部14で、メッセージキュー処理部13から取得した複数の同期要求に含まれる差分情報を1つの新たな差分情報に一括し、当該新たな差分情報を含む新たな同期要求を、通信ネットワーク30を介して情報処理装置20へ送信するようにしたので、情報処理装置10,20間でのデータ同期処理でやり取りする通信量、さらには記憶部22に対するアクセス回数を削減することができ、通信ネットワーク30に対する通信負荷や、情報処理装置10,20での処理負荷を削減することが可能となる。
[Effect of the third embodiment]
As described above, in the present embodiment, the data synchronous
[第4の実施の形態]
次に、図8を参照して、本発明の第4の実施の形態にかかるデータ同期システムについて説明する。図8は、第4の実施の形態にかかるデータ同期システムの動作を示すフロー図である。
本実施の形態では、情報処理装置10の記憶部12および情報処理装置20の記憶部22を、冗長化する場合について説明する。
[Fourth Embodiment]
Next, a data synchronization system according to the fourth exemplary embodiment of the present invention will be described with reference to FIG. FIG. 8 is a flowchart showing the operation of the data synchronization system according to the fourth embodiment.
In the present embodiment, a case will be described in which the
本実施の形態において、記憶部12,22は、複数の記憶装置を用いた冗長性を有している。例えば、データベースサーバを複数台接続する冗長化技術では、高い処理性能を保ったまま、任意のサーバでサービスを提供できるクラウド技術が実現されており、このような公知の冗長化技術を組み合わせて、記憶部12,22を冗長化すればよい。
なお、本実施の形態にかかる情報処理装置10,20におけるその他の構成については、前述した第1の実施の形態と同じであり、ここでの詳細な説明は省略する。
In the present embodiment, the
Note that other configurations of the
[第4の実施の形態の効果]
このように、本実施の形態によれば、記憶部12,22を冗長化するようにしたので、DBMSアプリケーション障害など、記憶部12,22に関する何らかの小規模な故障が発生しても、保守者が即時に故障を復旧しなくても自動的にシステムを切り替えてサービスを継続できる。
これにより、激甚災害など大規模な故障が発生しても、拠点を切り替えてサービスを継続できるため、あらゆるタイプの故障に対しても保守運用の手間を軽減できるシステムを構成することが可能となる。
[Effect of the fourth embodiment]
As described above, according to the present embodiment, since the
As a result, even if a large-scale failure such as a catastrophic disaster occurs, it is possible to continue the service by switching bases, so it is possible to configure a system that can reduce the effort of maintenance operation for any type of failure .
[第5の実施の形態]
次に、図9を参照して、本発明の第5の実施の形態にかかるデータ同期システムについて説明する。図9は、第5の実施の形態にかかるデータ同期システムの構成を示すブロック図である。
本実施の形態では、汎用化した情報処理装置10,20について説明する。
[Fifth Embodiment]
Next, a data synchronization system according to the fifth exemplary embodiment of the present invention will be described with reference to FIG. FIG. 9 is a block diagram illustrating a configuration of a data synchronization system according to the fifth embodiment.
In the present embodiment, general-purpose
データ同期システム1を構成する際、前述した第1〜第4の実施の形態のように、同期要求を指示する情報処理装置10と、この同期要求に応じてデータ同期を行う情報処理装置20と、2種類の情報処理装置を用いてデータ同期システム1を構成してもよいが、これら情報処理装置10,20の両方の機能を有している情報処理装置が現実的である。
When configuring the
本実施の形態にかかるデータ同期システム1を構成する、情報処理装置10,20は、互いに等しい構成を有している。
情報処理装置10には、主な機能として、アプリケーション処理部11、記憶部12、メッセージキュー処理部13、データ同期送信処理部14、およびデータ同期受信処理部15が設けられている。
このうち、データ同期受信処理部15は、前述した情報処理装置20におけるデータ同期受信処理部25と同等である。
The
The
Among these, the data synchronous
また、情報処理装置20には、主な機能として、アプリケーション処理部21、記憶部22、メッセージキュー処理部23、データ同期送信処理部24、およびデータ同期受信処理部25が設けられている。
このうち、メッセージキュー処理部23およびデータ同期送信処理部24は、前述した情報処理装置10におけるメッセージキュー処理部13、およびデータ同期送信処理部14と同等である。
なお、本実施の形態にかかる情報処理装置10,20におけるその他の構成については、前述した第1の実施の形態と同じであり、ここでの詳細な説明は省略する。
The
Among these, the message
Note that other configurations of the
[第5の実施の形態の効果]
このように、本実施の形態によれば、情報処理装置10,20を、同期要求を指示する情報処理装置、またはこの同期要求に応じてデータ同期を行う情報処理装置のいずれにも使用することが可能となる。
[Effect of Fifth Embodiment]
As described above, according to the present embodiment, the
[第6の実施の形態]
次に、図10〜図12を参照して、本発明の第6の実施の形態にかかるデータ同期システムについて説明する。図10は、第6の実施の形態にかかるデータ同期システムの構成を示すブロック図である。図11は、第6の実施の形態にかかるデータ同期システムの動作を示すシーケンス図である。図12は、第6の実施の形態にかかるデータ同期システムの動作を示すフロー図である。
[Sixth Embodiment]
Next, a data synchronization system according to a sixth embodiment of the present invention will be described with reference to FIGS. FIG. 10 is a block diagram illustrating a configuration of a data synchronization system according to the sixth embodiment. FIG. 11 is a sequence diagram illustrating the operation of the data synchronization system according to the sixth embodiment. FIG. 12 is a flowchart illustrating the operation of the data synchronization system according to the sixth embodiment.
第2の実施の形態では、データ同期システム1におけるデータ同期処理を並列化した場合に生じる、これら処理間の処理順序の問題を解決する方法として、情報処理装置20のデータ同期受信処理部25に、並列的に実行する複数の処理を排他的に制御する排他制御機能を設け、この排他制御機能を用いて、情報処理装置10のデータ同期送信処理部14から受信した同期要求の処理順序(受信順)を確保しつつ、複数のデータ同期受信処理を並列的に実行する場合を例として説明した。
In the second embodiment, as a method for solving the problem of the processing order between these processes that occurs when the data synchronization processes in the
この際、情報処理装置10のデータ同期送信処理部14に、例えばマルチスレッド機能を利用して、複数のデータ同期送信処理を並列的に実行する機能を設けた場合、記憶部12の更新処理順序に応じてメッセージキュー処理部13へ保存(エンキュー)された同期要求を、その保存順序で取得(デキュー)を開始するものの、並列的に同期要求の取得が実行されるため、同期要求の保存順序に対して、取得完了順や送信完了順が異なる順序となる可能性がある。この理由としては、例えば各スレッドのCPU割当順序を正確に制御できない、同期要求のデータ長が大きく異なるなど、様々な要因が考えられる。
At this time, when the data synchronous
したがって、情報処理装置20のデータ同期受信処理部25では、データ同期送信処理部14から受信した同期要求の受信順を確保しつつ、複数のデータ同期受信処理を並列的に実行するため、データ同期送信処理部14での送信処理順序が逆転した場合、データ同期受信処理部25において、同期要求のデータ同期処理順序を元に戻すことはできない。
本実施の形態では、このような情報処理装置10でのデータ更新順序と情報処理装置20でのデータ同期順序との逆転を回避する構成について説明する。
Therefore, the data synchronization
In the present embodiment, a configuration for avoiding the reversal of the data update order in the
本実施の形態にかかる情報処理装置10は、半導体メモリやハードディスクなどの記憶装置からなる同期排他テーブル16Aを有し、同期要求ごとに当該同期要求と対応する排他情報を同期排他テーブル16Aで記憶する同期排他処理部16をさらに備えている。
また、アプリケーション処理部11は、同期要求をメッセージキュー処理部13へ保存する際、当該同期要求と対応する排他情報として当該同期要求の処理種別を示す処理種別情報を含む排他情報を、同期排他処理部16へ登録する機能を有している。
The
Further, when storing the synchronization request in the message
また、データ同期送信処理部14は、メッセージキュー処理部13から任意の処理種別の同期要求を取得して情報処理装置20へ送信する際、同期排他処理部16に対して排他確認要求を出力して、同期排他処理部16により、当該同期要求の処理種別に該当する排他情報のうち、データ同期処理が未完了で当該同期要求より先にデータ同期処理すべき同期要求に関する排他情報がないことを確認した後、当該同期要求を情報処理装置20へ送信する機能を有している。
なお、本実施の形態にかかる情報処理装置10,20におけるその他の構成については、前述した第2の実施の形態と同じであり、ここでの詳細な説明は省略する。また、情報処理装置10,20で計時される時刻について、公知の技術により同期されているものとする。
Further, the data synchronous
In addition, about the other structure in the
[第6の実施の形態の動作]
次に、図11および図12を参照して、本実施の形態にかかるデータ同期システムの動作について説明する。
本実施の形態では、アプリケーション処理部11、メッセージキュー処理部13、およびデータ同期送信処理部14において、マルチスレッド機能によりそれぞれの処理が並列的に実行される。
[Operation of Sixth Embodiment]
Next, the operation of the data synchronization system according to the present embodiment will be described with reference to FIGS. 11 and 12.
In the present embodiment, in the
情報処理装置10のアプリケーション処理部11は、アプリケーションを起動し、入力された認証要求などの要求に応じて(ステップ400)、記憶部12の記憶データ12Aを用いた情報処理を実行する。
ここで、記憶データ12Aの更新が発生した場合、アプリケーション処理部11は、同期要求と前後して、アプリケーションから出力された更新要求を、記憶部12に対して出力する(ステップ401)。
記憶部12は、この更新要求を受け取って記憶データ12Aを更新するデータ更新処理を実行し(ステップ402)、その更新結果をアプリケーション処理部11へ返送する(ステップ403)。
The
Here, when the
The
また、アプリケーション処理部11は、アプリケーションからの同期要求と対応する排他情報を同期排他処理部16へ登録するため、同期排他処理部16に対して排他情報登録要求を出力する(ステップ404)。
同期排他処理部16は、この排他情報登録要求に応じて、指定された排他情報を保存し(ステップ405)、排他情報登録結果をアプリケーション処理部11へ返送する(ステップ406)。
Further, the
In response to the exclusive information registration request, the synchronous
また、アプリケーション処理部11は、排他情報の登録処理と並行して、いわゆるenqueue処理により、アプリケーションからのエンキュー要求(同期要求)を、メッセージキュー処理部13に対して出力する(ステップ407)。
メッセージキュー処理部13は、この同期要求を受け取って、メッセージキューへ順次保存し(ステップ408)、保存した旨のエンキュー結果(同期要求受領結果)を直ちにアプリケーション処理部11へ返送する(ステップ409)。
アプリケーション処理部11は、記憶部12からの更新結果やメッセージキュー処理部13での同期結果、さらにはアプリケーションでの情報処理結果に基づいて、ステップ100で入力された要求に対する応答を出力する(ステップ410)。
The
The message
The
一方、データ同期送信処理部14は、データ同期送信処理部14自身のデータ同期送信処理が完了したことを契機に、あるいは定期的に起動されて、いわゆるdequeue処理により、メッセージキュー処理部13に対してデキュー要求(取得要求)を出力し、新たな同期要求がメッセージキューに存在する場合には、休むことなく連続的にデキュー要求を出力する(ステップ420)。
メッセージキュー処理部13は、データ同期送信処理部14からのデキュー要求に応じて、メッセージキューに保存されている同期要求を、それぞれの保存順序に応じて順に取得して(ステップ421)、データ同期送信処理部14へデキュー結果として出力する(ステップ422)。
On the other hand, the data synchronous
In response to the dequeue request from the data synchronization
続いて、データ同期送信処理部14は、メッセージキュー処理部13から取得した同期要求に関する排他確認を行うための排他確認要求を同期排他処理部16へ出力する(ステップ423)。
同期排他処理部16は、この排他確認要求に応じて、保存されている排他情報のうちから、当該同期要求の処理種別に該当する同期未完了の排他情報を検索することにより、当該同期要求より先にデータ同期処理すべき同期未完了の同期要求と対応する排他情報の存在有無を確認する(ステップ424)。
Subsequently, the data synchronous
In response to this exclusion confirmation request, the synchronization
ここで、当該同期要求より先にデータ同期処理すべき同期要求の排他情報が存在していた場合、同期排他処理部16は、これら排他情報と対応する同期要求によるデータ同期処理が完了するまで、当該排他確認要求に対する排他確認結果の出力を待機する。
また、当該同期要求より先にデータ同期処理すべき同期要求の排他情報が存在しない場合、当該同期要求によるデータ同期処理が最先であることが確認されたことから、同期排他処理部16は、当該排他確認要求に対する排他確認結果を出力する(ステップ425)。
Here, if there is exclusive information of the synchronization request that should be subjected to data synchronization processing prior to the synchronization request, the synchronization
Further, when there is no exclusive information of the synchronization request to be subjected to data synchronization processing prior to the synchronization request, it is confirmed that the data synchronization processing by the synchronization request is the earliest, so the synchronization
データ同期送信処理部14は、この排他確認結果に応じて、当該同期要求を通信ネットワーク30を介して情報処理装置20へ送信する(ステップ426)。
情報処理装置20のデータ同期受信処理部25は、情報処理装置10からの同期要求を受信して受信キューへ一旦保存し、当該同期要求に基づいてデータ同期受信処理を実行して記憶部22の記憶データ22Aの更新を要求する。
情報処理装置20の記憶部22は、データ同期受信処理部25により受け取った、情報処理装置10からの同期要求に基づいて、記憶データ22Aを更新する(ステップ427)。これにより、記憶データ12A,22Aがデータ同期される。
The data synchronization
The data synchronization
The
この後、記憶部22は、当該同期要求による同期結果を、データ同期受信処理部25により、通信ネットワーク30を介して情報処理装置10へ返送する(ステップ428)。
情報処理装置10のデータ同期送信処理部14は、この同期結果を受信して、当該同期要求に対応する排他情報の無効化を行うための無効化要求を同期排他処理部16へ出力する(ステップ429)。
同期排他処理部16は、この無効化要求に応じて当該同期要求と対応する排他情報を無効化する(ステップ430)。
Thereafter, the
The data synchronization
In response to the invalidation request, the synchronization
これにより、情報処理装置10のデータ同期送信処理部14に、例えばマルチスレッド機能を利用して、複数のデータ同期送信処理を並列的に実行する機能を設けた場合でも、メッセージキュー処理部13への同期要求の保存順序と同じ順序、すなわち記憶部12に対するデータ更新処理と同じ順序で、データ同期送信処理部14の各データ同期送信処理(スレッド)が同期要求を情報処理装置20へ送信することができる。
Thereby, even when the data synchronous
[排他情報登録処理]
次に、図13〜図17を参照して、同期排他処理部16で排他情報を登録する際の排他情報登録処理について説明する。図13は、同期要求の構成例である。図14は、排他情報の構成例である。図15は、排他情報登録処理を示すフローチャートである。図16は、排他情報の登録状態を示す説明図である。図17は、排他情報の他の登録状態を示す説明図である。
[Exclusive information registration process]
Next, with reference to FIGS. 13 to 17, the exclusive information registration process when registering exclusive information in the synchronous
メッセージキュー処理部13に登録される同期要求には、例えばRADIUSプロトコルの場合、図13に示すように、パケット受信日時、同期要求登録要求時刻、排他情報レコードインデックス、更新種別、レルム番号、ユーザID、Acct-Session-Id、Framed-IP-Address、RADIUSクライアントIPアドレス、更新内容などの項目が設けられている。
For example, in the case of the RADIUS protocol, the synchronization request registered in the message
このうち、パケット受信日時は、アプリケーション処理部11が、例えば認証要求などの要求を受信した日時であり、同期要求登録要求時刻は、メッセージキュー処理部13に対する当該同期要求の登録要求を行った時刻であり、排他情報レコードインデックスは、当該同期要求に対応する排他情報レコードを指すインデックスであり、更新種別は、当該同期要求による記憶部12,22の更新処理に関する、他の同期要求による更新処理に対する排他条件であり、更新内容は、当該同期要求による記憶部12の更新内容である。
Among these, the packet reception date and time is the date and time when the
また、レルム番号、ユーザID、Acct-Session-Id、Framed-IP-Address、RADIUSクライアントIPアドレスは、アプリケーション処理部11へ入力された認証要求およびこれら対する認証応答に関する属性情報であり、これら属性情報のいずれか1つ、または複数の組み合わせが処理種別情報として用いられる。
Further, the realm number, user ID, Acct-Session-Id, Framed-IP-Address, and RADIUS client IP address are attribute information relating to the authentication request input to the
同期排他処理部16に登録される排他情報には、例えばRADIUSプロトコルの場合、図14に示すように、同期要求と同じ項目として、同期要求登録要求時刻、更新種別、レルム番号、ユーザID、Acct-Session-Id、Framed-IP-Address、RADIUSクライアントIPアドレス、更新内容などの項目が設けられており、また新たな項目として、データフラグおよびロックが設けられている。
For example, in the case of the RADIUS protocol, the exclusive information registered in the synchronous
データフラグは、当該排他情報の有効/無効を示すフラグ情報であり、当該排他情報と対応する同期要求による更新処理が未完了の場合には有効を示し、更新処理が完了した場合には無効を示す。
ロックは、当該排他情報に対する更新可否を示すフラグ情報であり、当該排他情報と対応する同期要求による更新処理が未完了で当該排他情報の更新が不可の場合にはロック(Loched)を示し、更新処理が完了して当該排他情報の更新が可能な場合にはアンロック(Unlocked)を示す。
The data flag is flag information indicating validity / invalidity of the exclusive information. The data flag indicates validity when the update process by the synchronization request corresponding to the exclusive information is not completed, and indicates invalidity when the update process is completed. Show.
The lock is flag information indicating whether or not the exclusive information can be updated. If the update process based on the synchronization request corresponding to the exclusive information is not completed and the exclusive information cannot be updated, the lock is indicated and updated. When the processing is completed and the exclusive information can be updated, it indicates unlocked.
同期排他処理部16は、アプリケーション処理部11からの排他情報登録要求に応じて、図15の排他情報登録処理を実行する。
まず、同期排他処理部16は、同期排他テーブル16AをWriteロックすることにより、他のスレッドによる同期排他テーブル16Aでの書込動作を禁止し(ステップ440)、同期排他テーブル16Aに保存されている排他情報レコードのうち、次にレコードを登録すべき位置を示す次レコードインデックスを基点として、次レコードインデックス以降のレコードからデータフラグが「無効」を示す無効化レコードを検索する(ステップ441)。この際、Writeロック状態において、当該スレッドではRead/Writeいずれも可とし、他のスレッドではRead/Writeいずれも不可でブロック(処理待ち)とする。
In response to the exclusive information registration request from the
First, the synchronization
次に、同期排他処理部16は、検索した無効化レコードに対して、排他情報登録要求で通知された新たな排他情報を登録するとともに、登録したレコードの次のレコードに次レコードインデックスを設定し(ステップ442)、当該レコードのデータフラグを「有効」に更新する(ステップ443)。
この後、同期排他処理部16は、同期排他テーブル16AのWriteロックを開放し(ステップ444)、一連の排他情報登録処理を終了する。
Next, the synchronous
Thereafter, the synchronization
したがって、同期排他テーブル16Aが排他情報登録処理開始時に、例えば図16に示す状態であった場合、データフラグが「無効」のレコード、すなわち当該排他情報と対応する同期要求のデータ同期処理が完了している無効化レコードとして、レコード1,4,5が存在している。
Therefore, when the exclusive synchronization table 16A is in the state shown in FIG. 16, for example, when the exclusive information registration process is started, the data synchronization process of the synchronization request corresponding to the record whose data flag is “invalid”, that is, the exclusive information is completed. As invalidated records,
ここで、次レコードインデックスがレコード4を示している場合、同期排他処理部16は、レコード4を基点として、レコード4以降に登録されている無効化レコードを検索する。
図16の場合、レコード4が無効化レコードであることから、レコード4が更新対象として選択される。そして、図17に示すように、レコード4に新たな排他情報が登録されて、当該レコードのデータフラグが「有効」に更新され、次レコードインデックスはレコード5に設定される。なお、図16および図17は、RADIUSプロトコルの場合における同期排他テーブルの状態例であり、このうちロック欄における「Locked」および「Unlocked」は、個々のレコードに対するReadロックの有無を示している。
Here, when the next record index indicates the
In the case of FIG. 16, since the
[排他情報確認処理]
次に、図18〜図21を参照して、同期排他処理部16における排他情報確認処理について説明する。図18は、排他情報確認処理を示すフローチャートである。図19は、更新種別の詳細を示す説明図である。図20は、排他確認要求での同期要求指定例である。図21は、排他情報確認処理時における同期排他テーブルの検索状態を示す説明図である。なお、図19〜図21には、RADIUSプロトコルの場合の例が示されている。
[Exclusive information confirmation processing]
Next, with reference to FIGS. 18 to 21, the exclusive information confirmation processing in the synchronous
同期排他処理部16は、データ同期送信処理部14からの排他確認要求に応じて、図15の排他情報登録処理を実行する。
まず、同期排他処理部16は、同期排他テーブル16Aから、排他確認要求で指定された同期要求に関連するレコード、すなわち当該同期要求と処理種別が一致するレコードであって、データフラグが「有効」を示すレコードを、関連レコードとして検索し(ステップ450)、検索した関連レコードをReadロックすることにより、他のスレッドによる読出動作を禁止する(ステップ451)。この際、Readロック状態において、当該スレッドではReadのみ可とし、他のスレッドではReadのみ可でWriteはブロック(処理待ち)とする。
The synchronous
First, the synchronization
続いて、同期排他処理部16は、検索した関連レコードに、当該同期要求と対応する排他情報以外のレコードであって、当該同期要求より先に優先してデータ同期処理すべき同期要求に関する優先処理レコードが含まれているか否か確認する(ステップ452)。
ここで、優先処理レコードが含まれている場合(ステップ452:YES)、同期排他処理部16は、関連レコードのReadロックを開放した後(ステップ453)、これらすべての優先処理レコードのデータフラグが「無効」となるまで待機し(ステップ454)、これら優先処理のすべてのレコードのデータフラグが「無効」となった時点でステップ450へ移行する。
Subsequently, the synchronization
If a priority processing record is included (step 452: YES), the synchronous
一方、ステップ452において、検索した関連レコードに優先処理レコードが含まれていない場合(ステップ452:NO)、同期排他処理部16は、関連レコードのReadロックを開放した後(ステップ455)、当該排他確認要求に対応する排他確認結果として、指定された同期要求より先に優先してデータ同期処理すべき他の同期要求が存在しない旨を示す排他確認結果をデータ同期送信処理部14へ出力し(ステップ456)、一連の排他情報確認処理を終了する。
On the other hand, if the priority record is not included in the retrieved related record in step 452 (step 452: NO), the synchronous
これにより、同期排他処理部16において、排他確認要求で指定された同期要求より先にデータ同期処理をすべき同期未完了の同期要求が存在するか確認され、同期未完了の同期要求が存在する場合には、これら同期未完了の同期要求がすべてデータ同期処理された後、排他確認要求で指定された同期要求のデータ同期処理がデータ同期送信処理部14で実行される。
As a result, the synchronization
排他情報には、図19に示すように、同期要求と同様、記憶部12に対するデータ更新処理の処理方法に関する種別を示す更新種別が含まれており、これら更新種別ごとに、データ同期送信処理部14からの排他確認要求で指定された同期要求と処理種別が一致する排他情報であるか否かを判定するための判定条件が設定されている。
例えば、更新種別「1.Access-Accept」の同期要求については、レルム番号とユーザIDの両方が同一の場合に当該同期要求と処理種別が一致していると判断される。また、更新種別「8.Accounnting-On」の排他情報については、RADIUSクライアントIPアドレスが同一の場合に当該同期要求と処理種別が一致していると判断される。
As shown in FIG. 19, the exclusive information includes an update type indicating a type related to the processing method of the data update process for the
For example, regarding the synchronization request of the update type “1. Access-Accept”, it is determined that the synchronization request and the processing type match when both the realm number and the user ID are the same. Further, regarding the exclusive information of the update type “8.Accounnting-On”, it is determined that the synchronization request and the processing type match when the RADIUS client IP address is the same.
したがって、データ同期送信処理部14からの排他確認要求で指定された同期要求が、例えば図20のような属性値を持っていた場合、当該更新種別が「1.Access-Accept」であることから、レルム番号とユーザIDの両方が同一の排他情報が、当該同期要求に関連する関連レコードとして検索される。
この場合、レルム番号が「12345」でユーザIDが「User03」であることから、図21に示す同期排他テーブル16Aでは、レコード2,3,4の3つが当該同期要求に関連する関連レコードとして検索される。なお、図21のロック欄における「Locked」および「Unlocked」は、個々のレコードに対するReadロックの有無を示している。
Therefore, when the synchronization request specified by the exclusive confirmation request from the data synchronization
In this case, since the realm number is “12345” and the user ID is “User03”, in the synchronous exclusion table 16A shown in FIG. 21, three
また、これら関連レコードのうち当該同期要求と対応するレコード4以外のレコード2,3が優先処理レコードとして選択される。なお、関連レコードのうち、当該同期要求と対応するレコードより後に登録されたレコードが含まれている場合には、これらレコードの同期要求登録要求時刻を比較して、当該同期要求と対応するレコードより前に登録されたレコードのみを優先処理レコードとして選択すればよい。
Of these related records,
また、同期排他テーブル16Aにおいて、関連レコードをReadロックする場合、これら関連レコードの項目のロックを「Locked」に更新し、Readロックを開放する場合、ロックを「Unlocked」に更新する。これにより、同期排他テーブル16Aに登録されている排他情報のうち、排他確認の対象となる同期要求に関連する関連レコードのみがReadロックされる。このため、処理種別が異なる他の同期要求に関連する関連レコードについては、読出動作することが可能となり、処理種別が異なる他の同期要求、すなわちデータ同期処理の処理順序において関係性のない同期要求に関する排他確認処理を、並行して実行することができる。 In the synchronous exclusion table 16A, when the related record is Read-locked, the lock of the item of the related record is updated to “Locked”, and when the Read lock is released, the lock is updated to “Unlocked”. As a result, only the related records related to the synchronization request to be excluded from the exclusion information registered in the synchronization exclusion table 16A are Read-locked. For this reason, related records related to other synchronization requests with different processing types can be read, and other synchronization requests with different processing types, that is, synchronization requests that are not related in the processing order of data synchronization processing. The exclusion confirmation process related to can be executed in parallel.
[排他情報無効化処理]
次に、図22〜図24を参照して、同期排他処理部16で排他情報を無効化する際の排他情報無効化処理について説明する。図22は、排他情報無効化処理を示すフローチャートである。図23は、無効化要求での同期要求指定例である。図24は、排他情報無効化処理時における同期排他テーブルの検索状態を示す説明図である。なお、図23、図24には、RADIUSプロトコルの場合の例が示されている。
[Exclusion information invalidation processing]
Next, with reference to FIGS. 22 to 24, the exclusive information invalidation processing when the exclusive information is invalidated by the synchronous
同期排他処理部16は、データ同期送信処理部14からの無効化要求に応じて、図22の排他情報無効化処理を実行する。
まず、同期排他処理部16は、同期排他テーブル16AをWriteロックすることにより、他のスレッドによる同期排他テーブル16Aでの書込動作を禁止し(ステップ460)、無効化要求で指定された同期要求と対応するレコードを検索する(ステップ461)。
続いて、同期排他処理部16は、検索したレコードのデータフラグを「無効」に更新して(ステップ462)、同期排他テーブル16AのWriteロックを開放し(ステップ463)、一連の排他情報無効化処理を終了する。
In response to the invalidation request from the data synchronous
First, the synchronous
Subsequently, the synchronization
したがって、データ同期送信処理部14からの無効化要求で指定された同期要求が、例えば図23のような属性値を持っていた場合、Acct-Session-IDが「0123456789abcdef」であることから、図24に示す同期排他テーブル16Aでは、レコード2が当該同期要求と対応するレコードとして検索され、このレコードのデータフラグが「有効」から「無効」に更新されるとともに、ロックが「Locked」から「Unlocked」に更新される。なお、図24のロック欄における「Locked」および「Unlocked」は、個々のレコードに対するReadロックの有無を示している。
Therefore, if the synchronization request specified by the invalidation request from the data synchronization
[第6の実施の形態の効果]
このように本実施の形態は、情報処理装置10に、同期要求ごとに、当該同期要求と対応する排他情報を記憶する同期排他処理部16をさらに設けて、アプリケーション処理部11で、同期要求をメッセージキュー処理部13へ保存する際、当該同期要求と対応する排他情報として当該同期要求の処理種別を示す処理種別情報を含む排他情報を、同期排他処理部16へ登録し、データ同期送信処理部14で、メッセージキュー処理部13から同期要求を取得して情報処理装置20へ送信する際、同期排他処理部16により、当該同期要求の処理種別に該当する排他情報のうち、データ同期処理が未完了で当該同期要求より先にデータ同期処理すべき同期要求に関する排他情報がないことを確認した後、当該同期要求を情報処理装置20へ送信するようにしたものである。
[Effect of the sixth embodiment]
As described above, according to the present exemplary embodiment, the
これにより、情報処理装置10のデータ同期送信処理部14に、例えばマルチスレッド機能を利用して、複数のデータ同期送信処理を並列的に実行する機能を設けた場合でも、メッセージキュー処理部13への同期要求の保存順序と同じ順序、すなわち記憶部12に対するデータ更新処理と同じ順序で、データ同期送信処理部14の各データ同期送信処理(スレッド)が同期要求を情報処理装置20へ送信することができる。
したがって、情報処理装置20のデータ同期受信処理部25では、情報処理装置10の記憶部12に対するデータ更新処理と同じ順序で、記憶部22に対するデータ同期処理を実行することが可能となり、情報処理装置10でのデータ更新順序と情報処理装置20でのデータ同期順序との逆転を回避することができる。
Thereby, even when the data synchronous
Therefore, the data synchronization
また、本実施の形態では、排他情報確認処理において、他のスレッドとの競合を回避するため同期排他テーブル16Aでの読出動作をロックする際、排他確認対象となる同期要求と関連する関連レコードのみをReadロックするようにしたので、処理種別が異なる他の同期要求に関連する関連レコードについては、読出動作することが可能となり、処理種別が異なる他の同期要求、すなわちデータ同期処理の処理順序において関係性のない同期要求に関する排他確認処理を、並行して実行することができる。 Further, in the present embodiment, in the exclusive information confirmation processing, when the reading operation in the synchronous exclusion table 16A is locked in order to avoid contention with other threads, only the related records related to the synchronization request that is the exclusive confirmation target. Is read-locked, so related records related to other synchronization requests with different processing types can be read, and in other synchronization requests with different processing types, that is, in the processing order of data synchronization processing It is possible to execute in parallel the exclusive confirmation process regarding the synchronization request having no relation.
[第7の実施の形態]
次に、図25〜図27を参照して、本発明の第7の実施の形態にかかるデータ同期システムについて説明する。図25は、第7の実施の形態にかかるデータ同期システムの構成を示すブロック図である。図26は、第7の実施の形態にかかるデータ同期システムの動作を示すフロー図である。図27は、第7の実施の形態にかかるデータ同期システムの動作を示すシーケンス図である。
[Seventh Embodiment]
Next, a data synchronization system according to the seventh embodiment of the present invention will be described with reference to FIGS. FIG. 25 is a block diagram illustrating a configuration of a data synchronization system according to the seventh embodiment. FIG. 26 is a flowchart illustrating the operation of the data synchronization system according to the seventh embodiment. FIG. 27 is a sequence diagram illustrating an operation of the data synchronization system according to the seventh embodiment.
第6の実施の形態では、情報処理装置10に排他情報処理部16を設けて、情報処理装置10でのデータ更新処理順序と情報処理装置20でのデータ同期処理順序との逆転を回避する場合を例として説明した。
本実施の形態では、情報処理装置20により、情報処理装置10でのデータ更新順序に基づいて、記憶部22へのデータ同期処理を行う場合について説明する。
In the sixth embodiment, when the exclusive
In the present embodiment, a case will be described in which the
本実施の形態にかかる情報処理装置20は、半導体メモリやハードディスクなどの記憶装置からなる同期テーブル26Aを有し、通信ネットワーク30を介して情報処理装置10から受信した同期要求を同期テーブル26Aへ順次保存する同期要求記憶部26をさらに備えている。
The
また、データ同期受信処理部25は、記憶部22のデータ同期処理を行う際、記憶部12でのデータ更新処理の順序と一致した順序にしたがって、記憶部22に対して最も先にデータ同期処理すべき同期要求を同期要求記憶部26から順に取得し、当該同期要求に含まれる、更新の前後における記憶データ12Aの差分に相当する差分情報に基づいて、順次、記憶部22のデータ同期処理を行う機能を有している。
なお、本実施の形態にかかる情報処理装置10,20におけるその他の構成については、前述した第2の実施の形態と同じであり、ここでの詳細な説明は省略する。
In addition, when performing data synchronization processing of the
In addition, about the other structure in the
[第7の実施の形態の動作]
次に、図26および図27を参照して、本実施の形態にかかるデータ同期システムの動作について説明する。
まず、情報処理装置10のアプリケーション処理部11は、アプリケーションを起動し、入力された認証要求などの要求に応じて(ステップ500)、記憶部12の記憶データ12Aを用いた情報処理を実行する。
[Operation of the seventh embodiment]
Next, with reference to FIG. 26 and FIG. 27, the operation of the data synchronization system according to the present embodiment will be described.
First, the
ここで、記憶データ12Aの更新が発生した場合、アプリケーション処理部11は、同期要求と前後して、アプリケーションから出力された更新要求を、記憶部12に対して出力する(ステップ501)。
記憶部12は、この更新要求を受け取って記憶データ12Aを更新するデータ更新処理を実行し(ステップ502)、その更新結果をアプリケーション処理部11へ返送する(ステップ503)。
Here, when the
The
また、アプリケーション処理部11は、排他情報の登録処理と並行して、いわゆるenqueue処理により、アプリケーションからのエンキュー要求(同期要求)を、メッセージキュー処理部13に対して出力する(ステップ504)。
メッセージキュー処理部13は、この同期要求を受け取って、メッセージキューへ順次保存し(ステップ505)、保存した旨のエンキュー結果(同期要求受領結果)を直ちにアプリケーション処理部11へ返送する(ステップ506)。
アプリケーション処理部11は、記憶部12からの更新結果やメッセージキュー処理部13での同期結果、さらにはアプリケーションでの情報処理結果に基づいて、ステップ500で入力された要求に対する応答を出力する(ステップ507)。
In parallel with the exclusive information registration process, the
The message
The
一方、データ同期送信処理部14は、データ同期送信処理部14自身のデータ同期送信処理が完了したことを契機に、あるいは定期的に起動されて、いわゆるdequeue処理により、メッセージキュー処理部13に対してデキュー要求(取得要求)を出力し、新たな同期要求がメッセージキューに存在する場合には、休むことなく連続的にデキュー要求を出力する(ステップ510)。
メッセージキュー処理部13は、データ同期送信処理部14からのデキュー要求に応じて、メッセージキューに保存されている同期要求を、それぞれの保存順序に応じて順に取得して(ステップ511)、データ同期送信処理部14へデキュー結果として出力する(ステップ512)。
On the other hand, the data synchronous
In response to the dequeue request from the data synchronization
これに応じて、データ同期送信処理部14は、メッセージキュー処理部13からのデキュー結果に含まれる同期要求を情報処理装置20の同期要求記憶部26へ登録するための登録要求を、通信ネットワーク30を介して情報処理装置20へ送信する(ステップ513)。
情報処理装置20の同期要求記憶部26は、通信ネットワーク30を介してデータ同期送信処理部14からの登録要求を受信し、この登録要求で通知された同期要求を同期テーブル26Aへ登録し(ステップ514)、登録した旨の登録結果を、通信ネットワーク30を介して情報処理装置10へ返送する(ステップ515)。
In response to this, the data synchronization
The synchronization
情報処理装置20のデータ同期受信処理部25は、同期要求記憶部26への同期要求の登録を契機に、データ同期受信処理部25自身のデータ同期受信処理が完了したことを契機に、あるいは定期的に起動されて、同期要求を取得するための取得要求を同期要求記憶部26へ出力する(ステップ520)。
同期要求記憶部26は、データ同期受信処理部25からの取得要求に応じて、登録されている同期要求のうちから、記憶部12に対して実行したデータ更新処理の順序と一致した順序にしたがって、記憶部22に対して最も先にデータ同期処理すべき同期要求を取得し(ステップ521)、データ同期受信処理部25へ取得結果として出力する(ステップ522)。
The data synchronization
In response to the acquisition request from the data synchronization
これに応じて、データ同期受信処理部25は、同期要求記憶部26からの取得結果で通知された同期要求に含まれる差分情報に基づいて、記憶部22の記憶データ22Aの更新を要求する(ステップ523)。
情報処理装置20の記憶部22は、データ同期受信処理部25により受け取った、情報処理装置10からの同期要求に基づいて、記憶データ22Aを更新する(ステップ524)。これにより、記憶データ12A,22Aがデータ同期される。
In response to this, the data synchronization
The
この後、記憶部22は、当該同期要求による同期結果を、データ同期受信処理部25へ出力する(ステップ525)。
データ同期受信処理部25は、この同期結果に応じて、同期要求記憶部26のうちデータ同期処理が完了した同期要求を削除するための削除要求を同期要求記憶部26へ出力する(ステップ526)。
これに応じて、同期要求記憶部26は、データ同期受信処理部25の削除要求で指定された同期要求を同期テーブル26Aから削除し(ステップ527)、その削除結果をデータ同期受信処理部25へ出力する(ステップ528)。
Thereafter, the
In response to the synchronization result, the data synchronization
In response to this, the synchronization
これにより、情報処理装置10のデータ同期送信処理部14に、例えばマルチスレッド機能を利用して、複数のデータ同期送信処理を並列的に実行する機能を設けた場合でも、記憶部12に対するデータ更新処理と同じ順序で、情報処理装置20の記憶部22に対してデータ同期処理を行うことができる。
Thus, even when the data synchronous
[同期要求取得処理]
次に、図28および図29を参照して、同期要求記憶部26における同期要求取得処理について説明する。図28は、同期要求取得処理を示すフローチャートである。図29は、同期要求取得処理を示す説明図である。
同期要求記憶部26は、データ同期受信処理部25からの取得要求に応じて図28の同期要求取得処理を実行する。
[Synchronous request acquisition processing]
Next, the synchronization request acquisition process in the synchronization
The synchronization
まず、同期要求記憶部26は、同期テーブル26Aに登録されているすべての同期要求を、当該同期要求のパケット受信日時の順でソート(並べ替え)し(ステップ530)、ソート結果の先頭に位置する同期要求、すなわちパケット受信日時が最も古い同期要求を選択する(ステップ531)。この場合、ソート以外の方法、例えば各同期要求のうちからパケット受信日時が最小の同期要求を選択するなどの方法を用いてもよい。
First, the synchronization
この後、同期要求記憶部26は、選択した最古の同期要求を、取得結果としてデータ同期受信処理部25へ通知し(ステップ532)、一連の同期要求取得処理を終了する。
これにより、同期要求記憶部26において、記憶部22に対して最も先にデータ同期処理すべき同期要求を選択して、データ同期受信処理部25へ通知することができる。
Thereafter, the synchronization
As a result, the synchronization
前述の図13に示したように、同期要求のパケット受信日時は、アプリケーション処理部11が、例えば認証要求など、記憶部12の記憶データ12Aの更新を含む要求を受信した日時である。アプリケーション処理部11では、これら要求を受信した時点で、直ちに記憶データ12Aのデータ更新処理を実行する。このため、このパケット受信日時の順序は、記憶部12でのデータ更新処理の順序と一致しているから、同期テーブル26Aのうち要求を受信した日時が最古の同期要求が、記憶部22に対して最も先にデータ同期処理すべき同期要求となる。
As shown in FIG. 13 described above, the packet reception date and time of the synchronization request is the date and time when the
なお、記憶部12に対するデータ更新処理の順序を示す時刻情報については、パケット受信日時だけでなく、他の時刻情報を用いてもよい。例えば、アプリケーション処理部11が同期要求をメッセージキュー処理部13へエンキューした時刻、すなわち図13の同期要求登録要求時刻も、記憶部12でのデータ更新処理の順序と一致しているので、パケット受信日時に代えて同期要求登録要求時刻を用いてもよい。また、データ同期送信処理部14から同期要求を送信した順序も、記憶部12でのデータ更新処理の順序と一致しているので、パケット受信日時に代えてデータ同期送信処理部14での同期要求送信時刻を用いてもよい。
In addition, about the time information which shows the order of the data update process with respect to the memory |
同期要求記憶部26に登録されている同期要求は、情報処理装置10から通信ネットワーク30を介して情報処理装置20へ転送されたものである。この際、通信ネットワーク30では、スループットが大幅に変化した場合、特定の同期要求のみが遅延して情報処理装置20へ到着する場合がある。したがって、ある同期要求Bより先にデータ同期処理すべき同期要求Aが通信ネットワーク30で遅延したため、同期要求Aが到着していない時点で、同期要求Aより先に同期要求Bが同期要求記憶部26から読み出されてデータ同期処理される場合も考えられる。
The synchronization request registered in the synchronization
したがって、このような通信ネットワーク30における同期要求の遅延ばらつきが大きいデータ同期システムでは、その最大遅延時間より長い待機時間以上、同期要求記憶部26で待機させた同期要求のうちから、最も先にデータ同期処理すべき同期要求を選択するようにしてもよい。この際、最大遅延時間については、事前に試験等をして遅延時間を測定し、その中で測定された遅延時間の最大値を最大遅延時間として設定すればよい。
Therefore, in such a data synchronization system in which the delay variation of the synchronization request in the
具体的には、図28において、ステップ530を実行する前に、同期要求取得処理の実行時刻から予め記憶部22に設定されている待機時間を減算することにより、処理除外時刻を算出し、同期テーブル26Aに登録されているすべての同期要求のうち、当該同期要求のパケット受信日時が処理除外時刻より過去の同期要求を抽出しておく。そして、ステップ530において、これら抽出したすべての同期要求を、当該同期要求のパケット受信日時の順でソート(並べ替え)して、以降のステップを実行すればよい。
これにより、通信ネットワーク30における同期要求の遅延ばらつきが同期要求記憶部26で吸収されて、同期要求Aが到着していない時点で、同期要求Aより先に同期要求Bが同期要求記憶部26から読み出されることを回避することができる。
Specifically, in FIG. 28, before executing
Thereby, the synchronization request delay variation in the
また、同期要求記憶部26に登録される同期要求の数が多い場合、これら同期要求のうちから最も先にデータ同期処理すべき同期要求を選択する処理の計算コストが高くなり、処理負担や処理時間が増加する。
例えば、すべての同期要求をソートする方法で、最も先にデータ同期処理すべき同期要求を選択する場合、典型的なソートアルゴリズムによれば、N個のレコードすべてをソートするのに必要となる計算量(回数)は、最善値でNlogN、最悪値でN2となる。N=1000個の場合、最善値で3000回、最悪値で100万回となり、非常に計算コストが高い。
In addition, when the number of synchronization requests registered in the synchronization
For example, in the method of sorting all synchronization requests, when selecting the synchronization request that is to be synchronized with the data first, according to a typical sorting algorithm, the calculation required to sort all N records The amount (number of times) is NlogN at the best value and N 2 at the worst value. In the case of N = 1000, the best value is 3000 times and the worst value is 1 million times, and the calculation cost is very high.
一方、前述したように、同期テーブル26Aに登録されているすべての同期要求のうち、当該同期要求のパケット受信日時が処理除外時刻より過去の同期要求を抽出した後、これら同期要求を、それぞれの同期要求のパケット受信日時の順でソートすれば、ソート対象となる同期要求を削減できる。
例えば、これら比較により抽出したレコード数が100個の場合、これらレコードをソートするのに必要となる計算量(回数)は、最善値で200回、最悪値で1万回であるから、N=1000個のレコードのパケット受信日時を処理除外時刻と比較する処理の計算量=1000回を加算しても、最善値で1200回、最悪値で11000回となる。したがって、前述したすべてのレコード1000個をソートする場合と比較して、最善値で約1/3、最悪値約1/100となり、計算コストを大幅に削減できる。
On the other hand, as described above, out of all the synchronization requests registered in the synchronization table 26A, after extracting the synchronization requests whose packet reception date / time of the synchronization request is earlier than the processing exclusion time, Sorting in order of the packet reception date and time of synchronization requests can reduce the synchronization requests to be sorted.
For example, when the number of records extracted by these comparisons is 100, the calculation amount (number of times) required to sort these records is 200 times at the best value and 10,000 times at the worst value. Even if the calculation amount of processing for comparing the packet reception date and time of 1000 records with the processing exclusion time = 1000 times is added, the best value is 1200 times and the worst value is 11000 times. Therefore, compared with the case where all 1000 records described above are sorted, the best value is about 1/3 and the worst value is about 1/100, and the calculation cost can be greatly reduced.
また、同期テーブル26Aに登録されているすべての同期要求のうち、当該同期要求のパケット受信日時が処理除外時刻より過去の同期要求を抽出した後、抽出したもののうちから、同期テーブル26Aに登録された順序で先頭から指定個数分の同期要求を再抽出し、再抽出した同期要求を、それぞれの同期要求のパケット受信日時の順でソートするようにしてもよい。これにより、ソート対象となる同期要求の数をさらに絞り込むことができ、計算コストのさらなる削減を実現できる。 Further, among all the synchronization requests registered in the synchronization table 26A, after extracting the synchronization requests whose packet reception date / time of the synchronization request is earlier than the processing exclusion time, the ones extracted from the extracted synchronization requests are registered in the synchronization table 26A. It is also possible to re-extract a specified number of synchronization requests from the beginning in the same order and sort the re-extracted synchronization requests in the order of the packet reception date and time of each synchronization request. Thereby, the number of synchronization requests to be sorted can be further narrowed down, and the calculation cost can be further reduced.
[第7の実施の形態の効果]
このように、本実施の形態は、情報処理装置20に、第1の情報処理装置から受信した同期要求を順次保存する同期要求記憶部26をさらに設け、データ同期受信処理部25で、記憶部22のデータ同期処理を行う際、同期要求記憶部26で保存している同期要求のうちから、記憶部12に対して実行したデータ更新処理の順序と一致した順序にしたがって、記憶部22に対して最も先にデータ同期処理すべき同期要求を取得し、当該同期要求に含まれる、更新の前後における記憶データ12Aの差分に相当する差分情報に基づいて記憶部22のデータ同期処理を行うようにしたものである。
[Effect of the seventh embodiment]
As described above, according to the present embodiment, the
これにより、情報処理装置10のデータ同期送信処理部14に、例えばマルチスレッド機能を利用して、複数のデータ同期送信処理を並列的に実行する機能を設けた場合でも、メッセージキュー処理部13への同期要求の保存順序と同じ順序、すなわち記憶部12に対するデータ更新処理と同じ順序で、情報処理装置20の記憶部22に対してデータ同期処理を行うことができ、情報処理装置10でのデータ更新順序と情報処理装置20でのデータ同期順序との逆転を回避することができる。
Thereby, even when the data synchronous
また、本実施の形態において、最も先にデータ同期処理すべき同期要求を取得する際、通信ネットワーク30における同期要求の最大遅延時間より長い待機時間だけ同期要求記憶部で待機させた同期要求のうちから、第1の記憶部に対して実行したデータ更新処理の順序と一致した順序にしたがって、最も先にデータ同期処理すべき同期要求を取得するようにしてもよい。
これにより、通信ネットワーク30における同期要求の遅延ばらつきが同期要求記憶部26で吸収されて、データ同期受信処理部25が同期要求記憶部26から取得する同期要求の順序の逆転を回避することができる。
Further, in the present embodiment, when acquiring a synchronization request to be subjected to data synchronization processing first, out of the synchronization requests that are waited in the synchronization request storage unit for a standby time longer than the maximum delay time of the synchronization request in the
As a result, the delay variation of the synchronization request in the
また、本実施の形態では、データ同期受信処理部25からの取得要求に応じて、同期要求記憶部26で、同期テーブル26Aに登録されている同期要求のうちから、最も先にデータ同期処理すべき同期要求を選択する処理を実行する場合を例として説明したが、これに限定されるものではなく、データ同期受信処理部25で実行してもよい。
この場合、データ同期受信処理部25が、記憶部22のデータ同期処理を行う際、取得要求を同期要求記憶部26へ出力して、同期テーブル26Aに登録されているすべての同期要求を取得し、これら同期要求に対して図28に示した同期要求取得処理を実行すればよい。
In this embodiment, in response to an acquisition request from the data synchronization
In this case, when the data synchronization
[第8の実施の形態]
次に、図30および図31を参照して、本発明の第8の実施の形態にかかるデータ同期システムについて説明する。図30は、第8の実施の形態にかかるデータ同期システムの構成を示すブロック図である。図31は、第8の実施の形態にかかるデータ同期システムの動作を示すフロー図である。
[Eighth Embodiment]
Next, with reference to FIGS. 30 and 31, a data synchronization system according to an eighth embodiment of the present invention will be described. FIG. 30 is a block diagram illustrating a configuration of a data synchronization system according to the eighth embodiment. FIG. 31 is a flowchart illustrating the operation of the data synchronization system according to the eighth embodiment.
第7の実施の形態では、情報処理装置20に同期要求記憶部26を設けて、情報処理装置10でのデータ更新順序と情報処理装置20でのデータ同期順序との逆転を回避する場合を例として説明した。
この際、同期要求記憶部26では、一般的なデータベースシステムで使用されているインデックス(索引)を構築して、同期要求に対してより高速にアクセス可能とすることにより、データ同期処理の完了までの時間を短縮することが想定される。
In the seventh embodiment, an example is provided in which the synchronization
At this time, the synchronization
一方、インデックスを構築したテーブルでは、レコードの登録や削除を頻繁に繰り返した場合、インデックスが断片化(フラグメンテーション)してしまい、レコードに対するアクセス速度が低下する可能性がある。 On the other hand, in a table in which an index is constructed, if registration and deletion of records are frequently repeated, the index may become fragmented (fragmentation), which may reduce the access speed to the records.
例えば、一般的なインデックスの1つであるBツリーインデックスは、ルートノードX、ブランチノードY、リーフノードZの3の階層に分かれた構造をしている。このうち、リーフノードは、検索対象となるデータが登録されている実データテーブル上のアドレスを示すDBAと実データテーブルの検索キーとなるINDEXキーカラムデータとで構成されており、1つのリーフノードにはDBAとINDEXキーカラムデータのセットが複数行まとめて格納される。 For example, a B-tree index, which is one of general indexes, has a structure divided into three layers of a root node X, a branch node Y, and a leaf node Z. Among these, a leaf node is composed of a DBA indicating an address on an actual data table in which data to be searched is registered, and INDEX key column data serving as a search key for the actual data table. The DBA and INDEX key column data sets are stored together in a plurality of rows.
このインデックスは、データの更新・削除を行うと状況が変化するが、リーフの数、削除されたリーフの扱いがどのようになるかが重要な観点となる。例えば、「10」、「20」、「30」、「40」、「50」、「60」、「70」、「80」の8個の検索キー(INDEXキーカラムデータ)があった場合、70を小さい数から順々に探していくと、7回目の比較処理で見つかることになる。
これに対して、X(10,50)、Y1(10,30),Y2(50,70)、Z1(10,20)、Z2(30,40)、Z3(50,60)、Z4(70,80)というインデックス構造を持っている場合、検索キー「70」は、X→Y2→Z4という3回目の処理で見つかることになり、計算量を削減できる。
The situation of this index changes when data is updated / deleted, but the important point is how the number of leaves and how deleted leaves are handled. For example, when there are eight search keys (INDEX key column data) of “10”, “20”, “30”, “40”, “50”, “60”, “70”, “80”, 70 Are searched in order from the smallest number, they will be found in the seventh comparison process.
On the other hand, X (10, 50), Y1 (10, 30), Y2 (50, 70), Z1 (10, 20), Z2 (30, 40), Z3 (50, 60), Z4 (70 , 80), the search key “70” is found in the third process of X → Y2 → Z4, and the amount of calculation can be reduced.
このようにインデックス構造では、実データテーブルへのデータ追加に伴ってブランチノードの変更が必要となった場合、リーフノード内の行数がインデックス作成時の設定値を超える際にはリーフノードの追加が必要となる。例えばデータ「25」が追加された場合、Y1がY1(10,25,30)に変更され、Z1,Z2への追加が検討される。ここでZ1,Z2の行数が設定値2に達しているため追加できず、新たなリーフノードZ5(25,)が追加される。また、データ「15」を追加する場合には、Z1(10,20)の中間の値であるため、元のZ1が分離されて、Z1(10,15)、Z5(20,)となる。
In this way, in the index structure, when the branch node needs to be changed as data is added to the actual data table, the leaf node is added when the number of rows in the leaf node exceeds the set value at the time of index creation. Is required. For example, when data “25” is added, Y1 is changed to Y1 (10, 25, 30), and addition to Z1 and Z2 is considered. Here, since the number of rows of Z1 and Z2 has reached the
また、実データテーブルのデータを更新する際、更新する元データの格納されていたリーフから元データの行が削除され、更新後データはリーフに空きがない場合には、新たにリーフノードを増やして追加される。
また、実データテーブルのデータを削除する際、それぞれのノードで管理するデータがすべて削除されてもノード自体は削除されない。
Also, when updating the data in the actual data table, if the original data row is deleted from the leaf where the original data to be updated is stored and there is no space in the leaf after the update, a new leaf node is added. Added.
In addition, when deleting data in the actual data table, the node itself is not deleted even if all data managed by each node is deleted.
このように、データの追加、更新、削除が頻繁に発生すると、削除リーフの増加と新たなリーフノードの増加が発生し、またリーフが散在することになるため、インデックスが断片化する。
したがって、極めて短い間隔でデータ同期処理を実行する必要がある場合、同期要求記憶部26に対して同期要求の登録や削除が頻繁に実行されるため、同期要求記憶部26で構築したインデックスが断片化してしまい、同期要求に対するアクセス速度が低下する可能性がある。
As described above, if data is frequently added, updated, or deleted, an increase in deleted leaves and an increase in new leaf nodes occur, and the leaves are scattered, so that the index is fragmented.
Therefore, when it is necessary to execute data synchronization processing at an extremely short interval, registration and deletion of the synchronization request are frequently performed on the synchronization
本実施の形態は、情報処理装置20の同期要求記憶部26に複数の同期テーブル26Aを設け、これら同期テーブル26Aを切り替えて運用することにより、待機中の同期テーブル26Aに対するインデックスの再構築や、さらには不要レコードの削除などのテーブル初期化処理を行う場合について説明する。なお、ここでは、2つの同期テーブル26Aを切り替えて運用する場合を例として説明したが、3つ以上の同期テーブル26Aを切り替えて運用してもよい。
In the present embodiment, a plurality of synchronization tables 26A are provided in the synchronization
本実施の形態にかかる情報処理装置20は、半導体メモリやハードディスクなどの記憶装置からなる同期テーブル26Aを複数有し、通信ネットワーク30を介して情報処理装置10から受信した同期要求を同期テーブル26Aへ順次保存する同期要求記憶部26と、待機中の同期テーブル26Aに対してインデックスの再構築や、さらには不要レコードの削除などのテーブルの初期化を行うテーブル初期化処理部27をさらに備えている。
The
また、データ同期受信処理部25は、記憶部22のデータ同期処理を行う際、同期要求記憶部26の各同期テーブル26Aに登録されているすべての同期要求のうちから、記憶部12でのデータ更新処理の順序と一致した順序にしたがって、記憶部22に対して最も先にデータ同期処理すべき同期要求を1つだけ、同期処理対象として取得し、当該同期要求に含まれる、更新の前後における記憶データ12Aの差分に相当する差分情報に基づいて順次記憶部22のデータ同期処理を行う機能を有している。
In addition, when the data synchronization
この際、同期処理対象を選択する具体例としては、同期テーブル26Aごとに、当該同期テーブル内の同期要求をそれぞれのパケット受信日時の順でソートして、最も先にデータ同期処理すべき同期要求をそれぞれ選択し、これら同期テーブル26Aごとに選択した同期要求のうちパケット受信日時が最も古い同期要求を、同期処理対象として選択してもよい。また、これらソートについては、前述した第7の実施の形態と同様にして計算コストを削減することもできる。 At this time, as a specific example of selecting the synchronization processing target, for each synchronization table 26A, the synchronization requests in the synchronization table are sorted in the order of packet reception date and time, and the synchronization request to be subjected to data synchronization processing first. And the synchronization request with the oldest packet reception date / time among the synchronization requests selected for each of the synchronization tables 26A may be selected as the synchronization processing target. For these sorts, the calculation cost can be reduced in the same manner as in the seventh embodiment described above.
また、情報処理装置10のデータ同期送信処理部14は、期間ごとに登録先となる同期テーブル26Aを定めた切替データに基づいて、メッセージキュー処理部13から取得した同期要求を、当該登録処理時点における同期テーブル26Aに対して登録する機能を有している。
なお、本実施の形態にかかる情報処理装置10,20におけるその他の構成については、前述した第7の実施の形態と同じであり、ここでの詳細な説明は省略する。
In addition, the data synchronization
The other configurations of the
[第8の実施の形態の動作]
次に、図30および図31を参照して、本実施の形態にかかるデータ同期システムの動作について説明する。以下では、情報処理装置20の同期要求記憶部26に、同期テーブル26Aとして同期テーブルAと同期テーブルBの2つの同期テーブルが設けられている場合を例として説明する。また、全体的な動作の流れについては、第7の実施の形態と同様であることから、前述した図27を参照して説明する。
[Operation of Eighth Embodiment]
Next, the operation of the data synchronization system according to the present embodiment will be described with reference to FIGS. Hereinafter, a case where two synchronization tables of the synchronization table A and the synchronization table B are provided as the synchronization table 26A in the synchronization
情報処理装置10のデータ同期送信処理部14は、メッセージキュー処理部13から取得した同期要求を、情報処理装置20の同期要求記憶部26へ登録する際、予め設定されている切替データを参照して、当該登録処理時点における登録先となる同期要求記憶部26の同期テーブル26Aを特定する。そして、特定した同期テーブル26Aを登録先として指定した登録要求を、通信ネットワーク30を介して情報処理装置20へ送信する(ステップ513)。
The data synchronization
図32は、切替データの構成例である。ここでは、登録処理時刻が切替時刻「00:00」以降の期間については、同期要求の登録先として同期テーブルAが割り当てられており、登録処理時刻が切替時刻「12:00」以降の期間については、同期要求の登録先として同期テーブルBが割り当てられている。
したがって、データ同期送信処理部14は、「00:00〜12:00」の期間については、同期テーブルAに同期要求を登録し、「12:00〜24:00」の期間については、同期テーブルBに同期要求を登録することになる。
FIG. 32 is a configuration example of the switching data. Here, for the period after the registration processing time “00:00”, the synchronization table A is assigned as the registration destination of the synchronization request, and for the period after the registration processing time “12:00”. Is assigned with the synchronization table B as the registration destination of the synchronization request.
Therefore, the data synchronization
情報処理装置20の同期要求記憶部26は、通信ネットワーク30を介してデータ同期送信処理部14からの登録要求を受信し、この登録要求で通知された同期要求を、この同期要求で指定された登録先となる同期テーブル26Aを選択して登録し(ステップ514)、登録した旨の登録結果を、通信ネットワーク30を介して情報処理装置10へ返送する(ステップ515)。
The synchronization
情報処理装置20のデータ同期受信処理部25は、同期要求記憶部26への同期要求の登録を契機に、データ同期受信処理部25自身のデータ同期受信処理が完了したことを契機に、あるいは定期的に起動されて、同期要求を取得するための取得要求を同期要求記憶部26へ出力する(ステップ520)。
同期要求記憶部26は、データ同期受信処理部25からの取得要求に応じて、各同期テーブル26Aに登録されているすべての同期要求のうちから、記憶部12に対して実行したデータ更新処理の順序と一致した順序にしたがって、記憶部22に対して最も先にデータ同期処理すべき同期要求を1つだけ、同期処理対象として取得し(ステップ521)、データ同期受信処理部25へ取得結果として出力する(ステップ522)。
The data synchronization
In response to the acquisition request from the data synchronization
この際、同期テーブル26Aに対する同期要求の登録は、切替データに基づき期間ごとに決定されるものの、登録される同期要求の登録順は、通信ネットワーク30で前後する場合が考えられる。このため、切替後の同期テーブルに登録された同期要求のほうが、切替前の同期テーブルに登録された同期要求より先にデータ同期処理をする必要がある場合も起こりうる。
したがって、本実施の形態では、各同期テーブル26Aを参照して、これら同期テーブル26Aのうちから最も先にデータ同期処理すべき同期要求を取得している。
At this time, although the registration of the synchronization request to the synchronization table 26A is determined for each period based on the switching data, the registration order of the synchronization request to be registered may be mixed in the
Therefore, in the present embodiment, referring to each synchronization table 26A, a synchronization request to be subjected to data synchronization processing is acquired first from among these synchronization tables 26A.
同期要求記憶部26からの取得結果に応じて、データ同期受信処理部25は、当該取得結果で通知された同期要求に含まれる差分情報に基づいて、記憶部22の記憶データ22Aの更新を要求する(ステップ523)。
これ以降、前述と同様に、記憶部22の記憶データ22Aが更新されてデータ同期処理が行われた後、同期要求記憶部26の同期テーブル26Aに登録されている同期要求が削除される。
In response to the acquisition result from the synchronization
Thereafter, as described above, after the
また、情報処理装置20のテーブル初期化処理部27は、同期要求記憶部26の同期テーブル26Aのうち、すべての同期要求についてデータ同期処理が完了した使用後の同期テーブル26A、すなわち待機中の同期テーブル26Aについて、初期化処理が未実行であれば、インデックスの再構築や、さらには不要レコードの削除などのテーブルの初期化を実行する。
これにより、同期テーブル26Aに対して、間欠的にテーブル初期化処理が行われるため、同期テーブル26Aのインデックスの断片化か解消されて、同期要求に対するアクセス速度の低下を回避することができる。
In addition, the table
Thereby, since the table initialization process is intermittently performed on the synchronization table 26A, the fragmentation of the index of the synchronization table 26A is eliminated, and the decrease in the access speed for the synchronization request can be avoided.
[第8の実施の形態の効果]
このように、本実施の形態は、情報処理装置20の同期要求記憶部26に複数の同期テーブル26Aを設け、これら同期テーブル26Aを切り替えて運用することにより、待機中の同期テーブル26Aに対するインデックスの再構築や、さらには不要レコードの削除などのテーブル初期化処理を行うようにしたので、これら同期テーブル26Aの切替に応じて、同期テーブル26Aのインデックスの断片化を解消することができ、同期要求に対するアクセス速度の低下を回避することが可能となる。
[Effect of the eighth embodiment]
As described above, according to the present embodiment, a plurality of synchronization tables 26A are provided in the synchronization
また、本実施の形態では、情報処理装置10側でのみ切替データを利用する場合を例として説明したが、切替データを情報処理装置20側でも利用してもよい。
例えば、図32で示したように、同期テーブルの切替時点において、切替元テーブルと切替先テーブルが確定している。このため、最も先にデータ同期処理すべき同期要求を取得する際、これら切替元テーブルと切替先テーブルに登録されている同期要求のみを検索対象として絞り込みすることができる。
In this embodiment, the case where the switching data is used only on the
For example, as shown in FIG. 32, the switching source table and the switching destination table are determined at the time of switching of the synchronization table. For this reason, when acquiring a synchronization request to be subjected to data synchronization processing first, only the synchronization requests registered in the switching source table and the switching destination table can be narrowed down as search targets.
これにより、3つ以上の同期テーブル26Aを順に切り替えて運用した際、同期テーブル26Aのすべてを検索対象とする場合と比較して、検索処理に要する計算量を大幅に削減できる。また、3つ以上の同期テーブル26Aを順に切り替えて運用した際、切替元テーブルおよび切替先テーブル以外のテーブルが、同期未完了の同期要求が残存していない待機テーブルとなるため、テーブル初期化処理を実行する際、同期要求の残存有無を確認する必要がなくなり、処理負担を大幅に軽減できる。 As a result, when three or more synchronization tables 26A are sequentially switched and operated, the amount of calculation required for the search process can be greatly reduced as compared to the case where all of the synchronization tables 26A are set as search targets. In addition, when three or more synchronization tables 26A are sequentially switched and operated, tables other than the switching source table and the switching destination table become standby tables in which synchronization requests that have not yet been synchronized remain, so that table initialization processing , It is no longer necessary to check whether or not there is a synchronization request remaining, and the processing load can be greatly reduced.
また、切替元テーブルに登録されているすべての同期要求に関するデータ同期処理が終了した時点で、切替先テーブルのみを検索対象とすることにより、検索処理に要する計算量をさらに削減できる。
この際、前述したように、通信ネットワーク30における同期要求の最大遅延時間を用いて、切替時刻から最大遅延時間に相当する時間以上経過した後、切替元テーブルに同期要求が残存していないことを確認してから、切替先テーブルのみを検索対象とするようにしてもよい。これにより、切替元テーブルの同期要求に関するデータ同期処理の終了を確認する処理を実行する必要がなくなり、検索処理に要する計算量を削減できる。
Further, when the data synchronization processing regarding all the synchronization requests registered in the switching source table is completed, only the switching destination table is set as a search target, so that the calculation amount required for the search processing can be further reduced.
At this time, as described above, the synchronization request does not remain in the switching source table after the time corresponding to the maximum delay time has elapsed from the switching time using the maximum delay time of the synchronization request in the
また、同期テーブルの切替時点において、切替元テーブルと切替先テーブルが確定していることから、切替時に、切替元テーブルに残っている同期未完了の同期要求を、切替先テーブルへ結合(join)するようにしてもよい。これにより、最も先にデータ同期処理すべき同期要求を取得する際、検索対象となる同期テーブルが、当該取得時刻に応じた1つの同期テーブルに限定されるため、検索処理に要する計算量を削減できる。 In addition, since the switching source table and the switching destination table are determined at the time of switching of the synchronization table, at the time of switching, an unsynchronized synchronization request remaining in the switching source table is joined to the switching destination table (join). You may make it do. This reduces the amount of calculation required for the search process because the synchronization table to be searched is limited to one synchronization table according to the acquisition time when acquiring the synchronization request that should be synchronized first. it can.
また、本実施の形態では、テーブル初期化処理部27において、同期要求に関するデータ同期処理の終了を確認した時点で、初期化処理が未実行であれば、当該待機中の同期テーブルを初期化する場合を例として説明したが、切替データに設定されている切替時刻に合わせて、各同期テーブルを初期化するようにしてもよい。
例えば、図32では、時刻12:00に同期テーブルAから同期テーブルBへ切り替えられることから、時刻12:00から一定の待機時間経過後に、待機中の同期テーブルAを初期化処理すればよい。この際、待機時間としては、通信ネットワーク30における同期要求の最大遅延時間より長く、次の切替時刻までの切替間隔より短い時間長を用いればよい。
In this embodiment, if the initialization process is not executed at the time when the table
For example, in FIG. 32, since the synchronization table A is switched to the synchronization table B at time 12:00, the standby synchronization table A may be initialized after a certain waiting time has elapsed from time 12:00. At this time, as the standby time, a time length that is longer than the maximum delay time of the synchronization request in the
[実施の形態の拡張]
以上、実施形態を参照して本発明を説明したが、本発明は上記実施形態に限定されるものではない。本発明の構成や詳細には、本発明のスコープ内で当業者が理解しうる様々な変更をすることができる。また、これら実施形態を任意に組み合わせ実施してもよい。
[Extended embodiment]
The present invention has been described above with reference to the embodiments, but the present invention is not limited to the above embodiments. Various changes that can be understood by those skilled in the art can be made to the configuration and details of the present invention within the scope of the present invention. Moreover, you may implement combining these embodiment arbitrarily.
以上の実施の形態では、アプリケーション処理部11で実行されているアプリケーションから出力された同期要求を、アプリケーション処理部11がメッセージキュー処理部13へ出力する場合を例として説明したが、これに限定されるものではない。例えば、アプリケーションから出力された記憶部12に対する更新要求を、OSなどからなるアプリケーション処理部11や他のアプリケーションがキャプチャし、その更新要求に基づいてメッセージキュー処理部13へ同期要求を出力するようにしてもよい。
これにより、アプリケーションが同期要求を出力する機能を持つ必要がなくなり、データ同期処理に対応していないアプリケーションについてもデータ同期処理を適用することができる。
In the above embodiment, the case where the
As a result, the application need not have a function of outputting a synchronization request, and the data synchronization process can be applied to an application that does not support the data synchronization process.
また、以上の実施の形態は、DBMSにおける2つの記憶部のデータ同期処理に限定されるものではなく、一般的なファイルシステム上のファイルの更新に対するデータ同期処理にも適用することができ、前述と同様の作用効果を得ることができる。 Further, the above embodiment is not limited to the data synchronization processing of the two storage units in the DBMS, but can also be applied to the data synchronization processing for file update on a general file system. The same effect can be obtained.
また、前述した図3、図5、図7、および図8における、記憶部12と記憶部22との間を結ぶデータ同期の矢印は、それぞれの実施の形態を適用することにより、結果として記憶部12と記憶部22との間でデータ同期された状態となることを示しており、これら記憶部12と記憶部22との間で、直接、データ同期処理が行われることを示すものではない。
In addition, the data synchronization arrows connecting the
1…データ同期システム、10…情報処理装置、11…アプリケーション処理部、11A,11B…アプリケーション処理スレッド、12…記憶部、12A…記憶データ、13…メッセージキュー処理部、14…データ同期送信処理部、14A,14B…データ同期送信処理スレッド、15…データ同期受信処理部、16…同期排他処理部、16A…同期排他テーブル、20…情報処理装置、21…アプリケーション処理部、22…記憶部、22A…記憶データ、23…メッセージキュー処理部、24…データ同期送信処理部、25…データ同期受信処理部、26…同期要求記憶部、26A…同期テーブル、27…テーブル初期化処理部、30…通信ネットワーク。
DESCRIPTION OF
Claims (24)
前記第1の情報処理装置は、
前記第1の記憶部で記憶する前記第1の記憶データを更新するアプリケーションを実行するアプリケーション処理部と、
前記更新の前後における前記第1の記憶データの差分に相当する差分情報を含む、前記アプリケーションからの同期要求を、順次保存するメッセージキュー処理部と、
データ同期送信処理として、前記メッセージキュー処理部から前記同期要求をそれぞれが保存された順序で順に取得し、前記通信ネットワークを介して前記第2の情報処理装置へ送信する、処理を実行するデータ同期送信処理部と
を備え、
前記第2の情報処理装置は、
データ同期受信処理として、前記通信ネットワークを介して前記第1の情報処理装置からの前記同期要求を受信し、当該同期要求に含まれる前記差分情報に基づいて、前記第2の記憶部で記憶する前記第2の記憶データを更新することにより、前記第1および第2の記憶データを同期させる、処理を実行するデータ同期受信処理部と
を備える
ことを特徴とするデータ同期システム。 Provided in the first information processing apparatus by including first and second information processing apparatuses connected via a communication network and performing data communication between the information processing apparatuses via the communication network. A data synchronization system that synchronizes first storage data stored in a first storage unit and second storage data stored in a second storage unit provided in the second information processing apparatus,
The first information processing apparatus includes:
An application processing unit that executes an application for updating the first storage data stored in the first storage unit;
A message queue processing unit for sequentially storing synchronization requests from the application, including difference information corresponding to the difference between the first storage data before and after the update;
As data synchronization transmission processing, data synchronization for performing processing is acquired in which the synchronization requests are sequentially acquired from the message queue processing unit in the order in which they are stored, and transmitted to the second information processing apparatus via the communication network. A transmission processing unit, and
The second information processing apparatus
As the data synchronization reception process, the synchronization request from the first information processing apparatus is received via the communication network, and stored in the second storage unit based on the difference information included in the synchronization request. A data synchronization reception processing unit that executes processing for synchronizing the first and second storage data by updating the second storage data.
前記メッセージキュー処理部は、前記同期要求の保存に応じて、当該同期要求に対する同期要求受領結果を直ちに前記アプリケーション処理部へ返送することを特徴とするデータ同期システム。 The data synchronization system according to claim 1,
The data queue system, wherein the message queue processing unit immediately returns a synchronization request reception result for the synchronization request to the application processing unit in response to the storage of the synchronization request.
前記データ同期送信処理部は、前記同期要求を送信する際、前記データ同期受信処理部との間で、前記同期要求間の送信順序が受信側で保証されるデータ送信プロトコルを用いることを特徴とするデータ同期システム。 In the data synchronization system according to claim 1 or 2,
The data synchronous transmission processing unit uses a data transmission protocol that guarantees a transmission order between the synchronization requests on the receiving side with the data synchronous reception processing unit when transmitting the synchronization request. Data synchronization system.
前記メッセージキュー処理部は、前記アプリケーション処理部から並列的に出力された前記同期メッセージを順次保存し、
前記データ同期送信処理部は、複数の前記データ同期送信処理を並列的に実行し、
前記データ同期受信処理部は、並列的に実行する複数の処理を排他的に制御する排他制御機能を含み、この排他制御機能を用いて、前記データ同期送信処理部から受信した前記同期要求の処理順序を確保しつつ、複数の前記同期受信処理を並列的に実行する
ことを特徴とするデータ同期システム。 In the data synchronization system according to any one of claims 1 to 3,
The message queue processing unit sequentially stores the synchronization messages output in parallel from the application processing unit,
The data synchronous transmission processing unit executes a plurality of the data synchronous transmission processes in parallel,
The data synchronization reception processing unit includes an exclusive control function that exclusively controls a plurality of processes executed in parallel, and processing of the synchronization request received from the data synchronous transmission processing unit using the exclusive control function A data synchronization system, wherein the plurality of synchronous reception processes are executed in parallel while securing an order.
前記データ同期送信処理部は、前記メッセージキュー処理部から取得した複数の前記同期要求に含まれる前記差分情報を1つの新たな差分情報に一括し、当該新たな差分情報を含む新たな同期要求を、前記通信ネットワークを介して前記第2の情報処理装置へ送信することを特徴とするデータ同期システム。 In the data synchronization system according to any one of claims 1 to 4,
The data synchronization transmission processing unit collects the difference information included in the plurality of synchronization requests acquired from the message queue processing unit into one new difference information, and sends a new synchronization request including the new difference information. A data synchronization system that transmits to the second information processing apparatus via the communication network.
前記第1の情報処理装置は、前記同期要求ごとに、当該同期要求と対応する排他情報を記憶する同期排他処理部をさらに備え、
前記アプリケーション処理部は、前記同期要求を前記メッセージキュー処理部へ保存する際、当該同期要求と対応する排他情報として当該同期要求の処理種別を示す処理種別情報を含む排他情報を、前記同期排他処理部へ登録し、
前記データ同期送信処理部は、前記メッセージキュー処理部から前記同期要求を取得して前記第2の情報処理装置へ送信する際、前記同期排他処理部により、当該同期要求の処理種別に該当する排他情報のうち、前記データ同期処理が未完了で当該同期要求より先にデータ同期処理すべき同期要求に関する排他情報がないことを確認した後、当該同期要求を前記第2の情報処理装置へ送信する
ことを特徴とするデータ同期システム。 In the data synchronization system according to any one of claims 1 to 5,
The first information processing apparatus further includes a synchronization exclusion processing unit that stores exclusion information corresponding to the synchronization request for each synchronization request,
When the application processing unit stores the synchronization request in the message queue processing unit, the application processing unit displays exclusive information including processing type information indicating a processing type of the synchronization request as exclusive information corresponding to the synchronization request. Register to the department,
When the data synchronization transmission processing unit acquires the synchronization request from the message queue processing unit and transmits the synchronization request to the second information processing apparatus, the data synchronization transmission processing unit performs an exclusion corresponding to the processing type of the synchronization request by the synchronization exclusion processing unit. Among the information, after confirming that the data synchronization processing is not completed and there is no exclusive information regarding the synchronization request to be subjected to the data synchronization processing before the synchronization request, the synchronization request is transmitted to the second information processing apparatus. A data synchronization system characterized by that.
前記第2の情報処理装置は、前記第1の情報処理装置から受信した前記同期要求を順次保存する同期要求記憶部をさらに備え、
前記データ同期受信処理部は、前記第2の記憶部のデータ同期処理を行う際、前記同期要求記憶部で保存している前記同期要求のうちから、前記第1の記憶部に対して実行した前記データ更新処理の順序と一致した順序にしたがって、前記第2の記憶部に対して最も先にデータ同期処理すべき同期要求を取得し、当該同期要求に含まれる前記差分情報に基づいて前記第2の記憶部のデータ同期処理を行う
ことを特徴とするデータ同期システム。 In the data synchronization system according to any one of claims 1 to 6,
The second information processing apparatus further includes a synchronization request storage unit that sequentially stores the synchronization requests received from the first information processing apparatus,
When the data synchronization reception processing unit performs the data synchronization processing of the second storage unit, the data synchronization reception processing unit is executed for the first storage unit from among the synchronization requests stored in the synchronization request storage unit In accordance with an order that matches the order of the data update process, a synchronization request to be subjected to data synchronization processing first is acquired from the second storage unit, and the first request is acquired based on the difference information included in the synchronization request. A data synchronization system that performs data synchronization processing of two storage units.
前記データ同期受信処理部は、前記通信ネットワークにおける前記同期要求の最大遅延時間より長い待機時間だけ前記同期要求記憶部で待機させた同期要求のうちから、前記第1の記憶部に対して実行した前記データ更新処理の順序と一致した順序にしたがって、前記最も先にデータ同期処理すべき同期要求を取得することを特徴とするデータ同期システム。 The data synchronization system according to claim 7, wherein
The data synchronization reception processing unit is executed for the first storage unit from among the synchronization requests that are waited in the synchronization request storage unit for a standby time longer than the maximum delay time of the synchronization request in the communication network. A data synchronization system, wherein a synchronization request to be subjected to data synchronization processing first is acquired according to an order that matches the order of the data update processing.
前記第1の情報処理装置において、
アプリケーション処理部が、前記第1の記憶部で記憶する前記第1の記憶データを更新するアプリケーションを実行するアプリケーション処理ステップと、
メッセージキュー処理部が、前記更新の前後における前記第1の記憶データの差分に相当する差分情報を含む、前記アプリケーションからの同期要求を、順次保存するメッセージキュー処理ステップと、
データ同期送信処理部が、データ同期送信処理として、前記メッセージキュー処理部から前記同期要求をそれぞれが保存された順序で順に取得し、前記通信ネットワークを介して前記第2の情報処理装置へ送信する、処理を実行するデータ同期送信処理ステップと
を備え、
前記第2の情報処理装置において、
データ同期受信処理部が、データ同期受信処理として、前記通信ネットワークを介して前記第1の情報処理装置からの前記同期要求を受信し、当該同期要求に含まれる前記差分情報に基づいて、前記第2の記憶部で記憶する前記第2の記憶データを更新することにより、前記第1および第2の記憶データを同期させる、処理を実行するデータ同期受信処理ステップと
を備える
ことを特徴とするデータ同期方法。 Provided in the first information processing apparatus by including first and second information processing apparatuses connected via a communication network and performing data communication between the information processing apparatuses via the communication network. Data used in a data synchronization system that synchronizes the first storage data stored in the first storage unit and the second storage data stored in the second storage unit provided in the second information processing apparatus A synchronization method,
In the first information processing apparatus,
An application processing unit that executes an application for updating the first storage data stored in the first storage unit; and
A message queue processing step, wherein the message queue processing unit sequentially stores synchronization requests from the application, including difference information corresponding to the difference between the first storage data before and after the update;
A data synchronization transmission processing unit acquires the synchronization requests from the message queue processing unit in the order in which they are stored as data synchronization transmission processing, and transmits the synchronization requests to the second information processing apparatus via the communication network. A data synchronous transmission processing step for executing processing, and
In the second information processing apparatus,
A data synchronization reception processing unit receives the synchronization request from the first information processing apparatus via the communication network as a data synchronization reception process, and based on the difference information included in the synchronization request, A data synchronization reception processing step for executing processing for synchronizing the first and second storage data by updating the second storage data stored in the second storage unit. Synchronization method.
前記記憶部で記憶する前記記憶データを更新するアプリケーションを実行するアプリケーション処理部と、
前記更新の前後における前記第1の記憶データの差分に相当する差分情報を含む、前記アプリケーションからの同期要求を、順次保存するメッセージキュー処理部と、
データ同期送信処理として、前記メッセージキュー処理部から前記同期要求をそれぞれが保存された順序で順に取得し、前記通信ネットワークを介して前記他の情報処理装置へ送信する、処理を実行するデータ同期送信処理部と
を備えることを特徴とする情報処理装置。 A first storage unit connected to another information processing apparatus via a communication network and performing data communication with the other information processing apparatus via the communication network to store the first information in a storage unit provided therein. And the second storage data stored in the other information processing apparatus,
An application processing unit that executes an application for updating the storage data stored in the storage unit;
A message queue processing unit for sequentially storing synchronization requests from the application, including difference information corresponding to the difference between the first storage data before and after the update;
Data synchronization transmission for performing processing, in which the synchronization requests are sequentially acquired from the message queue processing unit in the order in which they are stored and transmitted to the other information processing apparatus via the communication network as data synchronization transmission processing An information processing apparatus comprising: a processing unit.
前記メッセージキュー処理部は、前記同期要求の保存に応じて、当該同期要求に対する同期要求受領結果を直ちに前記アプリケーション処理部へ返送することを特徴とする情報処理装置。 The information processing apparatus according to claim 10,
The information processing apparatus, wherein the message queue processing unit immediately returns a synchronization request reception result for the synchronization request to the application processing unit in response to the storage of the synchronization request.
前記データ同期送信処理部は、前記同期要求を送信する際、前記データ同期受信処理部との間で、前記同期要求間の送信順序が受信側で保証されるデータ送信プロトコルを用いることを特徴とする情報処理装置。 The information processing apparatus according to claim 10 or 11,
The data synchronous transmission processing unit uses a data transmission protocol that guarantees a transmission order between the synchronization requests on the receiving side with the data synchronous reception processing unit when transmitting the synchronization request. Information processing apparatus.
前記データ同期送信処理部は、前記メッセージキュー処理部から取得した複数の前記同期要求に含まれる前記差分情報を1つの新たな差分情報に一括し、当該新たな差分情報を含む新たな同期要求を、前記通信ネットワークを介して前記他の情報処理装置へ送信することを特徴とする情報処理装置。 The information processing apparatus according to any one of claims 10 to 12,
The data synchronization transmission processing unit collects the difference information included in the plurality of synchronization requests acquired from the message queue processing unit into one new difference information, and sends a new synchronization request including the new difference information. An information processing apparatus that transmits to the other information processing apparatus via the communication network.
前記同期要求ごとに、当該同期要求と対応する排他情報を記憶する同期排他処理部をさらに備え、
前記アプリケーション処理部は、前記同期要求を前記メッセージキュー処理部へ保存する際、当該同期要求と対応する排他情報として当該同期要求の処理種別を示す処理種別情報を含む排他情報を、前記同期排他処理部へ登録し、
前記データ同期送信処理部は、前記メッセージキュー処理部から前記同期要求を取得して前記第2の情報処理装置へ送信する際、前記同期排他処理部により、当該同期要求の処理種別に該当する排他情報のうち、前記データ同期処理が未完了で当該同期要求より先にデータ同期処理すべき同期要求に関する排他情報がないことを確認した後、当該同期要求を前記第2の情報処理装置へ送信する
ことを特徴とする情報処理装置。 In the information processing apparatus according to any one of claims 10 to 13,
For each synchronization request, further comprising a synchronization exclusion processing unit that stores exclusion information corresponding to the synchronization request,
When the application processing unit stores the synchronization request in the message queue processing unit, the application processing unit displays exclusive information including processing type information indicating a processing type of the synchronization request as exclusive information corresponding to the synchronization request. Register to the department,
When the data synchronization transmission processing unit acquires the synchronization request from the message queue processing unit and transmits the synchronization request to the second information processing apparatus, the data synchronization transmission processing unit performs an exclusion corresponding to the processing type of the synchronization request by the synchronization exclusion processing unit. Among the information, after confirming that the data synchronization processing is not completed and there is no exclusive information regarding the synchronization request to be subjected to the data synchronization processing before the synchronization request, the synchronization request is transmitted to the second information processing apparatus. An information processing apparatus characterized by that.
前記他の情報処理装置から受信した前記同期要求を順次保存する同期要求記憶部と、
前記同期要求記憶部の同期要求に含まれる、前記第1の記憶データに対する更新の前後における前記第1の記憶データの差分に相当する差分情報に基づいて、前記記憶部で記憶する前記第2の記憶データを更新することにより、前記第1および第2の記憶データを同期させるデータ同期処理を実行するデータ同期受信処理部と
を備え、
前記データ同期受信処理部は、前記第2の記憶部のデータ同期処理を行う際、前記同期要求記憶部で保存している前記同期要求のうちから、前記1の記憶データに対して実行されたデータ更新処理と一致した順序にしたがって、前記記憶部に対して最も先にデータ同期処理すべき同期要求を取得し、当該同期要求に含まれる前記差分情報に基づいて前記記憶部のデータ同期処理を行う
ことを特徴とする情報処理装置。 The first information stored in the other information processing apparatus is connected to another information processing apparatus via the communication network and performs data communication with the other information processing apparatus via the communication network. An information processing apparatus that synchronizes stored data and second stored data stored in a storage unit provided in the storage data,
A synchronization request storage unit for sequentially storing the synchronization requests received from the other information processing devices;
The second stored in the storage unit based on the difference information corresponding to the difference between the first stored data before and after the update to the first stored data included in the synchronization request of the synchronization request storage unit A data synchronization reception processing unit that executes data synchronization processing for synchronizing the first and second storage data by updating the storage data; and
When the data synchronization reception processing unit performs the data synchronization processing of the second storage unit, the data synchronization reception processing unit is executed on the first stored data from among the synchronization requests stored in the synchronization request storage unit According to the order that matches the data update process, the synchronization request to be first synchronized with the storage unit is acquired, and the data synchronization process of the storage unit is performed based on the difference information included in the synchronization request. An information processing apparatus characterized by performing.
前記データ同期受信処理部は、前記通信ネットワークにおける前記同期要求の最大遅延時間より長い待機時間だけ前記同期要求記憶部で待機させた同期要求のうちから、前記第1の記憶部に対して実行した前記データ更新処理と一致した順序にしたがって、前記最も先にデータ同期処理すべき同期要求を取得することを特徴とする情報処理装置。 The information processing apparatus according to claim 15,
The data synchronization reception processing unit is executed for the first storage unit from among the synchronization requests that are waited in the synchronization request storage unit for a standby time longer than the maximum delay time of the synchronization request in the communication network. An information processing apparatus that acquires a synchronization request for data synchronization processing first in accordance with an order that matches the data update processing.
アプリケーション処理部が、前記記憶部で記憶する前記記憶データを更新するアプリケーションを実行するアプリケーション処理ステップと、
メッセージキュー処理部が、前記更新の前後における前記第1の記憶データの差分に相当する差分情報を含む、前記アプリケーションからの同期要求を、順次保存するメッセージキュー処理ステップと、
データ同期送信処理部が、データ同期送信処理として、前記メッセージキュー処理部から前記同期要求をそれぞれが保存された順序で順に取得し、前記通信ネットワークを介して前記他の情報処理装置へ送信する、処理を実行するデータ同期送信処理ステップと
を備えることを特徴とする情報処理方法。 A first storage unit connected to another information processing apparatus via a communication network and performing data communication with the other information processing apparatus via the communication network to store the first information in a storage unit provided therein. An information processing method used in an information processing device for synchronizing the stored data of the second storage data stored in the other information processing device,
An application processing unit that executes an application for updating the stored data stored in the storage unit; and
A message queue processing step, wherein the message queue processing unit sequentially stores synchronization requests from the application, including difference information corresponding to the difference between the first storage data before and after the update;
A data synchronization transmission processing unit sequentially acquires the synchronization requests from the message queue processing unit in the order in which they are stored as data synchronization transmission processing, and transmits the synchronization requests to the other information processing apparatus via the communication network. An information processing method comprising: a data synchronous transmission processing step for executing processing.
前記メッセージキュー処理ステップは、前記同期要求の保存に応じて、当該同期要求に対する同期要求受領結果を直ちに前記アプリケーション処理部へ返送することを特徴とする情報処理方法。 The information processing method according to claim 17,
In the message queue processing step, the synchronization request reception result for the synchronization request is immediately returned to the application processing unit in response to the storage of the synchronization request.
前記データ同期送信処理ステップは、前記同期要求を送信する際、前記データ同期受信処理部との間で、前記同期要求間の送信順序が受信側で保証されるデータ送信プロトコルを用いることを特徴とする情報処理方法。 The information processing method according to claim 17 or 18,
The data synchronization transmission processing step uses a data transmission protocol that guarantees a transmission order between the synchronization requests on the receiving side with the data synchronization reception processing unit when transmitting the synchronization request. Information processing method.
前記データ同期送信処理ステップは、前記メッセージキュー処理部から取得した複数の前記同期要求に含まれる前記差分情報を1つの新たな差分情報に一括し、当該新たな差分情報を含む新たな同期要求を、前記通信ネットワークを介して前記他の情報処理装置へ送信することを特徴とする情報処理方法。 In the information processing method according to any one of claims 17 to 19,
In the data synchronization transmission processing step, the difference information included in the plurality of synchronization requests acquired from the message queue processing unit is bundled into one new difference information, and a new synchronization request including the new difference information is generated. An information processing method comprising: transmitting to the other information processing apparatus via the communication network.
同期排他処理部が、前記同期要求ごとに、当該同期要求と対応する排他情報を記憶する同期排他処理ステップをさらに備え、
前記アプリケーション処理ステップは、前記同期要求を前記メッセージキュー処理部へ保存する際、当該同期要求と対応する排他情報として当該同期要求の処理種別を示す処理種別情報を含む排他情報を、前記同期排他処理部へ登録し、
前記データ同期送信処理ステップは、前記メッセージキュー処理部から前記同期要求を取得して前記第2の情報処理装置へ送信する際、前記同期排他処理部により、当該同期要求の処理種別に該当する排他情報のうち、前記データ同期処理が未完了で当該同期要求より先にデータ同期処理すべき同期要求に関する排他情報がないことを確認した後、当該同期要求を前記第2の情報処理装置へ送信する
ことを特徴とする情報処理方法。 The information processing method according to any one of claims 17 to 20,
The synchronization exclusion processing unit further includes a synchronization exclusion processing step for storing exclusion information corresponding to the synchronization request for each synchronization request,
In the application processing step, when the synchronization request is stored in the message queue processing unit, exclusive information including processing type information indicating a processing type of the synchronization request is included as the exclusive information corresponding to the synchronization request. Register to the department,
In the data synchronization transmission processing step, when the synchronization request is acquired from the message queue processing unit and transmitted to the second information processing apparatus, the synchronization exclusion processing unit performs an exclusion corresponding to the processing type of the synchronization request. Among the information, after confirming that the data synchronization processing is not completed and there is no exclusive information regarding the synchronization request to be subjected to the data synchronization processing before the synchronization request, the synchronization request is transmitted to the second information processing apparatus. An information processing method characterized by the above.
同期要求記憶部が、前記他の情報処理装置から受信した前記同期要求を順次保存する同期要求記憶ステップと、
データ同期受信処理部が、前記同期要求記憶部の同期要求に含まれる、前記第1の記憶データに対する更新の前後における前記第1の記憶データの差分に相当する差分情報に基づいて、前記記憶部で記憶する前記第2の記憶データを更新することにより、前記第1および第2の記憶データを同期させるデータ同期処理を実行するデータ同期受信処理ステップと
を備え、
前記データ同期受信処理ステップは、前記第2の記憶部のデータ同期処理を行う際、前記同期要求記憶部で保存している前記同期要求のうちから、前記1の記憶データに対して実行されたデータ更新処理の順序と一致した順序にしたがって、前記記憶部に対して最も先にデータ同期処理すべき同期要求を取得し、当該同期要求に含まれる前記差分情報に基づいて前記記憶部のデータ同期処理を行う
ことを特徴とする情報処理方法。 The first information stored in the other information processing apparatus is connected to another information processing apparatus via the communication network and performs data communication with the other information processing apparatus via the communication network. An information processing method used in an information processing apparatus for synchronizing stored data with second stored data stored in a storage unit provided in the storage data,
A synchronization request storage step in which a synchronization request storage unit sequentially stores the synchronization requests received from the other information processing apparatus;
The data synchronization reception processing unit is based on the difference information corresponding to the difference of the first storage data before and after the update to the first storage data included in the synchronization request of the synchronization request storage unit. A data synchronization reception processing step of executing data synchronization processing for synchronizing the first and second storage data by updating the second storage data stored in
The data synchronization reception processing step is performed on the first stored data from among the synchronization requests stored in the synchronization request storage unit when performing the data synchronization process of the second storage unit In accordance with an order that matches the order of data update processing, obtains a synchronization request to be data synchronization processed first for the storage unit, and data synchronization of the storage unit based on the difference information included in the synchronization request An information processing method characterized by performing processing.
前記データ同期受信処理ステップは、前記通信ネットワークにおける前記同期要求の最大遅延時間より長い待機時間だけ前記同期要求記憶部で待機させた同期要求のうちから、前記第1の記憶部に対して実行した前記データ更新処理の順序と一致した順序にしたがって、前記最も先にデータ同期処理すべき同期要求を取得することを特徴とする情報処理方法。 The information processing method according to claim 22,
The data synchronization reception processing step is executed for the first storage unit from among the synchronization requests that are waited in the synchronization request storage unit for a standby time longer than the maximum delay time of the synchronization request in the communication network. An information processing method comprising: acquiring a synchronization request to be subjected to data synchronization processing first in accordance with an order that matches the order of the data update processing.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2010097249A JP5331050B2 (en) | 2009-08-27 | 2010-04-20 | Data synchronization system, data synchronization method, information processing apparatus, information processing method, and program |
Applications Claiming Priority (3)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2009196742 | 2009-08-27 | ||
JP2009196742 | 2009-08-27 | ||
JP2010097249A JP5331050B2 (en) | 2009-08-27 | 2010-04-20 | Data synchronization system, data synchronization method, information processing apparatus, information processing method, and program |
Publications (2)
Publication Number | Publication Date |
---|---|
JP2011070636A true JP2011070636A (en) | 2011-04-07 |
JP5331050B2 JP5331050B2 (en) | 2013-10-30 |
Family
ID=44015814
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2010097249A Active JP5331050B2 (en) | 2009-08-27 | 2010-04-20 | Data synchronization system, data synchronization method, information processing apparatus, information processing method, and program |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP5331050B2 (en) |
Cited By (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2014178827A (en) * | 2013-03-14 | 2014-09-25 | Nec Corp | Replication system |
US9544459B2 (en) | 2014-07-28 | 2017-01-10 | Canon Kabushiki Kaisha | Information processing apparatus, image forming apparatus, information processing system, method for controlling information processing apparatus, method for controlling image forming apparatus, and storage medium storing program |
JP2018505496A (en) * | 2015-02-13 | 2018-02-22 | アリババ グループ ホウルディング リミテッド | Method, apparatus and system for synchronizing data |
US9930202B2 (en) | 2015-11-27 | 2018-03-27 | Canon Kabushiki Kaisha | Information processing apparatus ensuring temporal matching with server, method of controlling the information processing apparatus, information processing system, and storage medium |
JP2021174185A (en) * | 2020-04-23 | 2021-11-01 | 旭精工株式会社 | Server management type point management system for automatic service equipment |
US20230229533A1 (en) * | 2022-01-17 | 2023-07-20 | Fujitsu Limited | Control method, computer-readable recording medium storing control program, and information processing apparatus |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2000155693A (en) * | 1998-11-18 | 2000-06-06 | Fujitsu Ltd | Message controller |
JP2002049517A (en) * | 2000-05-25 | 2002-02-15 | Hitachi Ltd | Storage system |
JP2003202962A (en) * | 2003-01-15 | 2003-07-18 | Hitachi Ltd | Storage controller |
JP2004334460A (en) * | 2003-05-07 | 2004-11-25 | Hitachi Ltd | Method and system for database snapshot |
-
2010
- 2010-04-20 JP JP2010097249A patent/JP5331050B2/en active Active
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2000155693A (en) * | 1998-11-18 | 2000-06-06 | Fujitsu Ltd | Message controller |
JP2002049517A (en) * | 2000-05-25 | 2002-02-15 | Hitachi Ltd | Storage system |
JP2003202962A (en) * | 2003-01-15 | 2003-07-18 | Hitachi Ltd | Storage controller |
JP2004334460A (en) * | 2003-05-07 | 2004-11-25 | Hitachi Ltd | Method and system for database snapshot |
Cited By (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2014178827A (en) * | 2013-03-14 | 2014-09-25 | Nec Corp | Replication system |
US9544459B2 (en) | 2014-07-28 | 2017-01-10 | Canon Kabushiki Kaisha | Information processing apparatus, image forming apparatus, information processing system, method for controlling information processing apparatus, method for controlling image forming apparatus, and storage medium storing program |
JP2018505496A (en) * | 2015-02-13 | 2018-02-22 | アリババ グループ ホウルディング リミテッド | Method, apparatus and system for synchronizing data |
US10509585B2 (en) | 2015-02-13 | 2019-12-17 | Alibaba Group Holding Limited | Data synchronization method, apparatus, and system |
US9930202B2 (en) | 2015-11-27 | 2018-03-27 | Canon Kabushiki Kaisha | Information processing apparatus ensuring temporal matching with server, method of controlling the information processing apparatus, information processing system, and storage medium |
JP2021174185A (en) * | 2020-04-23 | 2021-11-01 | 旭精工株式会社 | Server management type point management system for automatic service equipment |
JP7249038B2 (en) | 2020-04-23 | 2023-03-30 | 旭精工株式会社 | Server management type point management system for automatic service equipment |
US20230229533A1 (en) * | 2022-01-17 | 2023-07-20 | Fujitsu Limited | Control method, computer-readable recording medium storing control program, and information processing apparatus |
Also Published As
Publication number | Publication date |
---|---|
JP5331050B2 (en) | 2013-10-30 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN107977376B (en) | Distributed database system and transaction processing method | |
US9959178B2 (en) | Transactional and parallel log replay for asynchronous table replication | |
Lin et al. | Towards a non-2pc transaction management in distributed database systems | |
US9367346B2 (en) | Accelerating distributed transactions on key-value stores through dynamic lock localization | |
US10157108B2 (en) | Multi-way, zero-copy, passive transaction log collection in distributed transaction systems | |
US10296371B2 (en) | Passive two-phase commit system for high-performance distributed transaction execution | |
US20130117307A1 (en) | Snapshot isolation support for distributed query processing in a shared disk database cluster | |
US20150161016A1 (en) | Method and system of self-managing nodes of a distributed database cluster with a consensus algorithm | |
JP5331050B2 (en) | Data synchronization system, data synchronization method, information processing apparatus, information processing method, and program | |
US10599677B2 (en) | Methods and systems of splitting database indexes and digests | |
JP5686034B2 (en) | Cluster system, synchronization control method, server device, and synchronization control program | |
WO2017192174A1 (en) | Splitting and moving ranges in a distributed system | |
US11263236B2 (en) | Real-time cross-system database replication for hybrid-cloud elastic scaling and high-performance data virtualization | |
US11615068B2 (en) | Methods and systems of managing deletes in a database node of a NoSQL database | |
US11003550B2 (en) | Methods and systems of operating a database management system DBMS in a strong consistency mode | |
Ghandeharizadeh et al. | Strong consistency in cache augmented SQL systems | |
WO2017077616A1 (en) | Database system, transaction management node, method, and program | |
US20190251006A1 (en) | Methods and systems of managing consistency and availability tradeoffs in a real-time operational dbms | |
Sciascia et al. | RAM-DUR: In-memory deferred update replication | |
Fan et al. | ALOHA-KV: high performance read-only and write-only distributed transactions | |
US8615769B2 (en) | Data processing system, data processing method, and data processing program | |
Ghandeharizadeh et al. | Rejig: a scalable online algorithm for cache server configuration changes | |
Shin et al. | Parqua: Online reconfigurations in virtual ring-based nosql systems | |
Fan et al. | Gossip-based visibility control for high-performance geo-distributed transactions | |
Lehner et al. | Transactional data management services for the cloud |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
RD02 | Notification of acceptance of power of attorney |
Free format text: JAPANESE INTERMEDIATE CODE: A7422 Effective date: 20111031 |
|
RD04 | Notification of resignation of power of attorney |
Free format text: JAPANESE INTERMEDIATE CODE: A7424 Effective date: 20111031 |
|
A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20120606 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20120619 |
|
A521 | Written amendment |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20120820 |
|
A02 | Decision of refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A02 Effective date: 20130312 |
|
A521 | Written amendment |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20130528 |
|
A911 | Transfer to examiner for re-examination before appeal (zenchi) |
Free format text: JAPANESE INTERMEDIATE CODE: A911 Effective date: 20130604 |
|
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: 20130723 |
|
A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20130726 |
|
R150 | Certificate of patent or registration of utility model |
Ref document number: 5331050 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R150 Free format text: JAPANESE INTERMEDIATE CODE: R150 |
|
S531 | Written request for registration of change of domicile |
Free format text: JAPANESE INTERMEDIATE CODE: R313531 |
|
R350 | Written notification of registration of transfer |
Free format text: JAPANESE INTERMEDIATE CODE: R350 |