JP6684030B2 - Session information management system and session information management method - Google Patents
Session information management system and session information management method Download PDFInfo
- Publication number
- JP6684030B2 JP6684030B2 JP2017025649A JP2017025649A JP6684030B2 JP 6684030 B2 JP6684030 B2 JP 6684030B2 JP 2017025649 A JP2017025649 A JP 2017025649A JP 2017025649 A JP2017025649 A JP 2017025649A JP 6684030 B2 JP6684030 B2 JP 6684030B2
- Authority
- JP
- Japan
- Prior art keywords
- session information
- web
- web server
- unit
- new
- 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.)
- Active
Links
Images
Landscapes
- Computer And Data Communications (AREA)
- Information Transfer Between Computers (AREA)
Description
本発明は、WebクライアントとWebサーバとの間の状態を管理するセッション情報管理システムおよびセッション情報管理方法に関する。 The present invention relates to a session information management system and a session information management method for managing a state between a web client and a web server.
従来、WebサーバがWebブラウザを通じてWebクライアントに一時的にデータを書き込んで保存させる仕組みとして、Cookieが利用されている。このCookieによりWebクライアントが保存できる情報量は制限されており、Webクライアントから大きなデータサイズの送信を行うことは難しい、そのため、Webサーバ側で情報を保持する方式を採っていた。 Conventionally, Cookie has been used as a mechanism for a web server to temporarily write and save data in a web client through a web browser. The amount of information that can be stored in the Web client is limited by this cookie, and it is difficult to transmit a large data size from the Web client. Therefore, the method of holding the information on the Web server side has been adopted.
Webシステムに用いられるWeb3層(プレゼンテーション層、アプリケーション層、データ層)の構成においては、Webサーバ、および、当該Webサーバに通信するWebクライアントとの間の状態(セッション情報等)を管理するデータベースが存在する。そして、Webクライアントの数が増加すると、Webサーバの増設だけでは対応できなくなり、データベースをスケールアウトしてセッション情報等を分割して格納する必要があった(非特許文献1参照)。 In the configuration of the Web3 layer (presentation layer, application layer, data layer) used in the Web system, a database that manages the state (session information, etc.) between the Web server and the Web client that communicates with the Web server is provided. Exists. Then, as the number of Web clients increases, it is not possible to deal with it by only adding Web servers, and it is necessary to scale out the database and store session information and the like in a divided manner (see Non-Patent Document 1).
一方、HTML(HyperText Markup Language)5において、Webクライアント側にデータを保存する仕組みとして、Web Storageが規定されている(非特許文献2参照)。このWeb Storageでは、WebサーバがWebクライアントに対してKey-Valueデータを保存させることができる。また、データ領域サイズもCookieが4096Byte程度であったのに対し、5MB程度まで拡張され、より大きなデータを保存できるようになった。 On the other hand, in HTML (HyperText Markup Language) 5, Web Storage is specified as a mechanism for storing data on the Web client side (see Non-Patent Document 2). In this Web storage, the Web server can store the Key-Value data in the Web client. Also, the data area size was about 4096 bytes for Cookie, but it was expanded to about 5 MB, and it became possible to store larger data.
これまでのWebシステムでは、上記のようにWebサーバ側が状態を管理するデータベースを保持し、そのデータベースに複数のWebサーバからのアクセスが認められている。そのため、データベースを保持するサーバを増設して負荷分散を行う際には、セッション情報等の状態データを新たなサーバに移行させる手順が複雑になる。これを回避するために、Web Storage等を利用してWebクライアント側にセッション情報等の状態データを保持させることが想定されるが、その場合には、Webクライアントが毎回すべてのセッション情報を送信することになり通信量が膨大になってしまう。また、Webクライアントは、Webサーバに比べ信頼性が低いため、状態データが失われる可能性が高まってしまう。
さらに、従来、WebクライアントがWebサーバをまたがって移動する場合には、セッション情報を移動元と移動先のWebサーバにおいて同期して保持する必要がある。このため、Webクライアントが各Webサーバを移動するに伴って、重複したセッション情報が各Webサーバに残っていくという問題もある。
In the conventional Web systems, the Web server holds a database for managing the state as described above, and access to the database from a plurality of Web servers is permitted. Therefore, when load balancing is performed by adding a server holding a database, the procedure of migrating the state data such as session information to a new server becomes complicated. In order to avoid this, it is assumed that the Web client uses the Web storage or the like to hold state data such as session information. In that case, the Web client sends all session information every time. As a result, the amount of communication becomes enormous. Further, since the Web client is less reliable than the Web server, there is a high possibility that the state data will be lost.
Further, conventionally, when a Web client moves across Web servers, it is necessary to hold session information in synchronization between the source and destination Web servers. Therefore, there is also a problem that duplicate session information remains in each Web server as the Web client moves each Web server.
このような点を鑑みて本発明がなされたのであり、複数のWebサーバでの重複したセッション情報の保持をなくし、かつ、Webサーバのスケールアウトや障害復旧を容易に行うことができる、セッション情報管理システムおよびセッション情報管理方法を提供することを課題とする。 The present invention has been made in view of such a point, and it is possible to eliminate the need to retain duplicate session information in a plurality of Web servers and to easily perform scale-out and failure recovery of the Web servers. An object is to provide a management system and a session information management method.
前記した課題を解決するため、請求項1に記載の発明は、Webクライアントに対してWebサービスを提供する複数のWebサーバを備えるセッション情報管理システムであって、前記Webサーバのそれぞれが、前記Webサーバそれぞれに1対1で対応する不揮発ストレージと、前記Webクライアントから前記Webサービスの提供のための初期セッション情報を受信するセッション情報受信部と、前記受信した初期セッション情報に、当該Webサーバのアドレスを付して更新したセッション情報を示す新セッション情報を生成するとともに、生成した前記新セッション情報を前記不揮発ストレージに記憶するセッション情報生成部と、前記生成した新セッション情報を前記Webクライアントに送信するセッション情報送信部と、を備え、前記Webクライアントが、前記Webサービスの提供を受けるためのセッション情報を記憶するセッション情報記憶部と、前記初期セッション情報をユーザ登録サーバから取得するユーザ登録要求部と、前記初期セッション情報を前記Webサーバに送信するとともに、前記Webサーバから受信した前記新セッション情報を前記セッション情報記憶部に記憶するセッション情報処理部と、を備え、前記新セッション情報が、前記Webサーバの前記不揮発ストレージと、前記Webクライアントの前記セッション情報記憶部との両方に記憶されることを特徴とするセッション情報管理システムとした。
In order to solve the above-mentioned problems, the invention according to
また、請求項6に記載の発明は、Webクライアントに対してWebサービスを提供する複数のWebサーバを備えるセッション情報管理システムのセッション情報管理方法であって、前記Webサーバのそれぞれが、前記Webサーバそれぞれに1対1で対応する不揮発ストレージを備え、前記Webクライアントから前記Webサービスの提供のための初期セッション情報を受信するステップと、前記受信した初期セッション情報に、当該Webサーバのアドレスを付して更新したセッション情報を示す新セッション情報を生成するとともに、生成した前記新セッション情報を前記不揮発ストレージに記憶するステップと、前記生成した新セッション情報を前記Webクライアントに送信するステップと、を実行し、前記Webクライアントが、前記Webサービスの提供を受けるためのセッション情報を記憶するセッション情報記憶部を備え、前記初期セッション情報をユーザ登録サーバから取得するステップと、前記初期セッション情報を前記Webサーバに送信するとともに、前記Webサーバから受信した前記新セッション情報を前記セッション情報記憶部に記憶するステップと、を実行し、前記新セッション情報が、前記Webサーバの前記不揮発ストレージと、前記Webクライアントの前記セッション情報記憶部との両方に記憶されることを特徴とするセッション情報管理方法とした。
Further, the invention according to
このように、セッション情報管理システムのWebクライアントは、セッション情報を記憶する容量を有するセッション情報記憶部を備え、Webサーバが生成したセッション情報(新セッション情報)を記憶しておくことができる。また、Webサーバのそれぞれは、1対1で対応する不揮発ストレージに自身が生成したセッション情報(新セッション情報)を記憶しておく。
これにより、Webクライアントが複数のWebサーバを移動する場合であっても、移動先のWebサーバは、Webクライアントからセッション情報を取得すればよいため、セッション情報を移動元と移動先のWebサーバで同期する必要をなくすことができる。さらに、Webサーバは、対応する1つの不揮発ストレージにセッション情報を記憶することから、例えば、Webサーバのスケールアウトや障害復旧の際において、セッションデータを移行させる手順が複雑になるのを避けることができる。
As described above, the Web client of the session information management system includes the session information storage unit having the capacity to store the session information, and can store the session information (new session information) generated by the Web server. In addition, each of the Web servers stores the session information (new session information) generated by itself in the one-to-one corresponding nonvolatile storage.
As a result, even when the Web client moves a plurality of Web servers, the Web server of the moving destination only needs to acquire the session information from the Web client. You can eliminate the need to synchronize. Further, since the Web server stores the session information in the corresponding one non-volatile storage, it is possible to avoid a complicated procedure of migrating the session data when the Web server is scaled out or the failure is recovered. it can.
請求項2に記載の発明は、前記Webクライアントの前記セッション情報処理部が、当該Webクライアントが移動することにより、前記新セッション情報を用いた前記Webサーバとの間のWebサービスの提供が受けられない場合に、前記セッション情報記憶部に記憶された新セッション情報を抽出し、新たにWebサービスの提供先となる他のWebサーバに、抽出した前記新セッション情報を送信することを特徴とする請求項1に記載のセッション情報管理システムとした。
According to a second aspect of the present invention, the session information processing unit of the Web client receives the provision of the Web service using the new session information by moving the Web client. In the case where there is no new session information, the new session information stored in the session information storage unit is extracted, and the extracted new session information is transmitted to another Web server that is newly provided with the Web service. The session information management system according to
このように、Webクライアントのセッション情報処理部は、Webクライアントが移動することにより、それまでのWebサーバとの間でWebサービスの提供を受けられない場合に、セッション情報記憶部に記憶しておいたセッション情報(新セッション情報)を、新たにWebサービスの提供先となるWebサーバに送信することができる。
これにより、Webクライアントが移動した場合であっても、Webクライアントが記憶するセッション情報(新セッション情報)を用いて、移動先のWebサーバがWebサービスを継続して提供することが可能となる。
As described above, the session information processing unit of the Web client stores the session information in the session information storage unit when the Web client cannot be provided with the Web service until then due to the movement of the Web client. The existing session information (new session information) can be transmitted to the Web server that is the new destination of the Web service.
Accordingly, even if the Web client has moved, using the Web session information client stores (new session information), Web server of the destination it is possible to continuously provide Web service.
請求項3に記載の発明は、前記Webサーバのそれぞれが、さらに、セッション情報削除部を備え、前記セッション情報生成部が、前記Webクライアントから前記新セッション情報を受信した場合に、当該Webサーバのアドレスを付して更新した第2の新セッション情報を生成し、前記不揮発ストレージに記憶し、前記セッション情報送信部は、生成した前記第2の新セッション情報を前記Webクライアントに送信する処理を行い、前記セッション情報削除部は、前記新セッション情報に付されたWebサーバのアドレスを抽出し、当該抽出したアドレスのWebサーバに対し、新セッション情報の削除指示を送信し、前記新セッション情報の削除指示を受信したWebサーバのセッション情報削除部は、自身の前記不揮発ストレージに記憶されている前記新セッション情報を削除することを特徴とする請求項2に記載のセッション情報管理システムとした。 In the invention according to claim 3, each of the Web servers further includes a session information deleting unit, and when the session information generating unit receives the new session information from the Web client, The second new session information updated with an address is generated and stored in the non-volatile storage, and the session information transmission unit performs a process of transmitting the generated second new session information to the Web client. The session information deleting unit extracts the address of the Web server attached to the new session information, transmits a deletion instruction of the new session information to the Web server having the extracted address, and deletes the new session information. The session information deleting unit of the Web server that receives the instruction is the nonvolatile storage of its own. It was session information management system according to claim 2, characterized in that to remove the new session information stored.
このように、新セッション情報を受信したWebサーバは、その新セッション情報に付されたアドレスを抽出し、そのアドレスのWebサーバに対して、新セッション情報の削除指示を送信することができる。よって、複数のWebサーバに同じセッション情報が重複して記憶されることを避けることができる。 In this way, the Web server that has received the new session information can extract the address attached to the new session information and send a deletion instruction of the new session information to the Web server at that address. Therefore, it is possible to prevent the same session information from being redundantly stored in a plurality of Web servers.
請求項4に記載の発明は、前記Webサーバのそれぞれが、さらに、セッション情報取得部およびセッション情報削除部を備え、前記セッション情報取得部は、自身の不揮発ストレージに記憶されたセッション情報では、前記Webクライアントに対するWebサービスの提供ができないと判定した場合に、前記Webサーバのそれぞれに対し、当該Webクライアントに関する前記新セッション情報を問い合わせて取得し、自身のアドレスを付して更新した第2の新セッション情報を生成して、前記不揮発ストレージに記憶し、前記セッション情報送信部は、生成した前記第2の新セッション情報を前記Webクライアントに送信する処理を行い、前記セッション情報削除部は、前記新セッション情報に付されたWebサーバのアドレスを抽出し、当該抽出したアドレスのWebサーバに対し、新セッション情報の削除指示を送信し、前記新セッション情報の削除指示を受信したWebサーバのセッション情報削除部は、自身の前記不揮発ストレージに記憶されている前記新セッション情報を削除することを特徴とする請求項1に記載のセッション情報管理システムとした。
In the invention according to claim 4, each of the Web servers further includes a session information acquisition unit and a session information deletion unit, and the session information acquisition unit uses the session information stored in its own non-volatile storage as the session information acquisition unit. When it is determined that the Web service cannot be provided to the Web client, the second new information obtained by inquiring and acquiring the new session information related to the Web client from each of the Web servers, and updating with the own address. The session information is generated and stored in the non-volatile storage, the session information transmission unit performs a process of transmitting the generated second new session information to the Web client, and the session information deletion unit performs the new information. Enter the web server address attached to the session information. The session information deleting unit of the Web server which has sent the instruction to delete the new session information to the Web server of the extracted address and has received the instruction to delete the new session information is stored in the nonvolatile storage of its own. The session information management system according to
このように、例えば、Webクライアントが記憶するセッション情報が障害等で喪失したことにより、WebサーバがWebクライアントに対しWebサービスを提供できないと場合であっても、セッション情報取得部が、他のWebサーバそれぞれにそのWebクライアントに関するセッション情報を問い合わせ、当該セッション情報を記憶するWebサーバから取得できる。これにより、他のWebサーバがWebサービスを継続して提供することが可能となる。 In this way, for example, even when the Web server cannot provide the Web service to the Web client due to the loss of the session information stored in the Web client due to a failure or the like, the session information acquisition unit determines that another Web Each server can be inquired about session information about the Web client, and the session information can be acquired from the Web server that stores the session information. As a result, another web server can continue to provide web services.
請求項5に記載の発明は、前記Webサーバのそれぞれが、さらに、セッション情報分配部、サーバ負荷監視部およびセッション情報削除部を備え、前記サーバ負荷監視部は、自身のWebサーバの負荷情報を監視し、当該負荷情報の値が所定の閾値を超えたことを示す監視情報を、前記セッション情報分配部に出力し、前記セッション情報分配部は、前記監視情報を取得した場合に、自身の前記不揮発ストレージに記憶しているセッション情報を、自身が担当するセッション情報と、増設されたWebサーバに担当させるセッション情報とに分配し、前記Webクライアントから、前記増設されたWebサーバに担当させるセッション情報である前記新セッション情報を用いたWebサービスの提供要求を受信すると、前記増設されたWebサーバのアドレスを含むリダイレクト指示を当該Webクライアントに送信し、前記リダイレクト指示を受信したWebクライアントが、前記増設されたWebサーバのアドレスを用いて当該Webサーバに前記新セッション情報を送信し、前記増設されたWebサーバが、前記セッション情報生成部が、前記Webクライアントから前記新セッション情報を受信し、当該増設されたWebサーバのアドレスを付して更新した第2の新セッション情報を生成し、前記不揮発ストレージに記憶し、前記セッション情報送信部は、生成した前記第2の新セッション情報を前記Webクライアントに送信する処理を行い、前記セッション情報削除部は、前記新セッション情報に付されたWebサーバのアドレスを抽出し、当該抽出したアドレスのWebサーバに対し、新セッション情報の削除指示を送信し、前記新セッション情報の削除指示を受信したWebサーバのセッション情報削除部は、自身の前記不揮発ストレージに記憶されている前記新セッション情報を削除することを特徴とする請求項1に記載のセッション情報管理システムとした。
In the invention according to
このように、Webサーバの負荷が増え、Webサーバを増設する場合であっても、増設されたWebサーバは、Webクライアントからセッション情報(新セッション情報)を取得し、Webサービスを提供することができる。また、増設されたWebサーバは、取得した新セッション情報に付されたアドレスを抽出し、そのアドレスのWebサーバに対して、新セッション情報の削除指示を送信することができる。よって、複数のWebサーバに同じセッション情報が重複して記憶されることを避けることができる。 As described above, even when the load on the Web server increases and the number of Web servers is increased, the added Web server can acquire session information (new session information) from the Web client and provide the Web service. it can. Further, the added Web server can extract the address attached to the acquired new session information, and can transmit the deletion instruction of the new session information to the Web server having the address. Therefore, it is possible to prevent the same session information from being redundantly stored in a plurality of Web servers.
本発明によれば、複数のWebサーバでの重複したセッション情報の保持をなくし、かつ、Webサーバのスケールアウトや障害復旧を容易に行うことができる。 According to the present invention, it is possible to prevent duplicate session information from being held in a plurality of Web servers and to easily perform scale-out and failure recovery of Web servers.
次に、本発明を実施するための形態(以下、「本実施形態」と称する。)における、セッション情報管理システム1等について説明する。
図1は、本実施形態に係るセッション情報管理システム1の構成を示す図である。
セッション情報管理システム1は、Webクライアント10に対してWebサービスを提供するWebシステムであり、1つ以上のWebクライアント10と、各拠点内ネットワーク(NW)5に収容されるWebサーバ20と、各拠点内ネットワーク(NW)5と接続する拠点間ネットワーク(NW)6に接続されるユーザ登録サーバ30およびDNS(Domain Name System)サーバ40とを備える。図1においては、セッション情報管理システム1内において、拠点内ネットワーク5(5−1)(拠点内NW「1」)に収容されるWebサーバ20(20−1)(Webサーバ「1」)と、拠点内ネットワーク5(5−2)(拠点内NW「2」)に収容されるWebサーバ20(20−2)(Webサーバ「2」)とが設置されており、Webクライアント10が、Webサーバ20(20−1,20−2)のいずれかと接続して、Webサービスを利用するものとして説明する。
Next, the session
FIG. 1 is a diagram showing the configuration of a session
The session
本実施形態に係るWebクライアント10は、セッション情報を保存する仕組みとして、従来のCookieと比較し、より大きいデータ領域を持つセッション情報記憶部100を備えることを特徴とする。このセッション情報記憶部100は、例えば、HTML5で規定されるWeb Storageにより実現することができる。そして、Webクライアント10は、このセッション情報記憶部100に、Webサービスにおいて利用するセッション情報等を保存しておく。
なお、本実施形態に係る「セッション情報」とは、Webクライアント10によりクライアントがWebサーバ20を利用する際の一時的なデータ、例えば、ネットショッピングの買物かごの情報や、最終送信前の入力フォームの情報等だけではなく、従来のWebシステムの共有データベースで管理されるデータであり、コンテンツを購入した際のコンテンツ購入情報のような、継続的に保存されるデータも含まれる。
The
The “session information” according to the present embodiment is temporary data when the client uses the
また、各Webサーバ20は、自身と1対1に対応した不揮発ストレージ200を備える。つまり、各不揮発ストレージ200は、自身と接続する1つのWebサーバ20以外のWebサーバ20からはアクセスされず、他のWebサーバ20が処理したセッション情報は保存しない。これにより、Webサーバ20を増設する際等に、セッション情報等の状態データを移行させる手順が複雑になることを避けることができる。
さらに、各Webサーバ20は、Webクライアント10がWebサーバ20をまたがって移動する場合に、移動先のWebサーバ20がWebクライアント10からセッション情報を取得する。これにより、セッション情報を移動元と移動先のWebサーバ20において同期する必要をなくすことができる。そして、セッション情報をWebクライアント10が保存しているため、移動元のWebサーバ20は、不要となったセッション情報を削除することができる。
以下、セッション情報管理システム1を構成する各装置について、具体的に説明する。
In addition, each
Furthermore, in each
Hereinafter, each device constituting the session
<ユーザ登録サーバ>
本実施形態に係るユーザ登録サーバ30は、図1に示すように、各Webクライアント10がWebサービスを利用するための初期セッション情報を、初期セッション情報DB(DataBase)300に記憶する。この初期セッション情報には、Webクライアント10を所持するユーザがWebサービスを利用する際の認証IDや、Webサービスを利用する際の初期設定(利用時間の設定、利用データの種別、利用エリア等)の情報が格納される。このユーザ登録サーバ30は、その記憶部(不図示)に、Webクライアント10および各Webサーバ20との間で共有された鍵(共通鍵)を備え、Webクライアント10からユーザ登録要求メッセージを受信すると、初期セッション情報DB300参照し該当する初期セッション情報を抽出して共通鍵で暗号化しWebクライアント10に送信する。
<User registration server>
As illustrated in FIG. 1, the
<DNSサーバ>
本実施形態に係るDNSサーバ40は、図1に示すように各Webサーバ20のアドレス(IPアドレス)をWebサーバアドレス情報DB400に記憶する。そして、DNSサーバ40は、Webクライアント10からのWebサーバ20のIPアドレスの問合せメッセージ(アドレス問合せメッセージ)を受信すると、Webクライアント10を収容する拠点内ネットワーク5に属するWebサーバ20のIPアドレスを、Webサーバアドレス情報DB400を参照して抽出し、そのWebクライアント10へ送信する。
<DNS server>
The
<Webクライアント>
図2は、本実施形態に係るWebクライアント10の構成例を示す機能ブロック図である。
Webクライアント10は、Webサービスを利用する装置であり、例えば、スマートフォン、タブレット端末等である。このWebクライアント10は、従来のCookieに保存される情報と比べてより情報量の多いセッション情報を記憶するための記憶手段として、例えば、HTML5において規定されるWeb Storageのようなセッション情報記憶部100を備える。そして、Webクライアント10は、Webサーバ20から最新の(更新された)セッション情報を取得し、セッション情報記憶部100に記憶しておく。また、Webクライアント10は、それまで接続していたWebサーバ20から他のWebサーバ20に接続先を変更した場合や、Webサーバ20が増設された場合などに、自身が記憶するセッション情報を新たに接続先となるWebサーバ20に送信する。
このWebクライアント10は、図2に示すように、制御部11と、入出力部12と、メモリ部13と、記憶部14とを含んで構成される。
<Web client>
FIG. 2 is a functional block diagram showing a configuration example of the
The
As shown in FIG. 2, the
入出力部12は、ユーザ登録サーバ30や、DNSサーバ40、Webサーバ20等との間で情報の送受信を行うための通信インタフェースと、タッチパネルやキーボード等の入力装置や、モニタ等の出力装置との間で情報の送受信を行うための入出力インタフェースとから構成される。
The input /
メモリ部13は、RAM(Random Access Memory)等の一次記憶装置からなり、制御部11によるデータ処理に必要な情報を一時的に記憶する。
The
記憶部14は、フラッシュメモリ等の記憶装置からなり、セッション情報を記憶するセッション情報記憶部100がその記憶領域として確保される。
なお、この記憶部14には、ユーザ登録サーバ30および各Webサーバ20との間で共有された鍵(共通鍵)が格納される。
The
The
制御部11は、Webクライアント10全体の制御を司り、ユーザ登録要求部111と、アドレス問合せ部112と、セッション情報処理部113とを備える。なお、ここでは、Webサービスの利用に関する機能のみを抽出して説明するが、Webクライアント10が他の機能を備えていてもよい。
また、この制御部11は、例えば、記憶部14に格納されたプログラムを不図示のCPU(Central Processing Unit)が、メモリ部13としてのRAMに展開し実行することにより実現される。
The
Further, the
ユーザ登録要求部111は、Webサービスを利用するために、ユーザ登録サーバ30に対し、ユーザ登録要求メッセージを送信する。また、ユーザ登録要求部111は、ユーザ登録サーバ30から、共通鍵等で暗号化された初期セッション情報を取得する。
The user
アドレス問合せ部112は、ユーザ登録要求部111が、ユーザ登録サーバ30から、初期セッション情報を受信したことを契機として、Webサービスを利用するWebサーバ20のIPアドレスの問合せメッセージ(アドレス問合せメッセージ)を、DNSサーバ40に送信する。そして、アドレス問合せ部112は、DNSサーバ40から、Webクライアント10が接続する拠点内ネットワーク5に属するWebサーバ20のIPアドレスを取得する。
When the user
セッション情報処理部113は、ユーザ登録要求部111が受信した暗号化された初期セッション情報を、共通鍵を用いて復号化し、セッション情報記憶部100に記憶する。
また、セッション情報処理部113は、各Webサーバ20から暗号化された既存のセッション情報(更新されたセッション情報)を受信し、共通鍵を用いて復号化した上で、セッション情報記憶部100に記憶する。
さらに、セッション情報処理部113は、自身のセッション情報記憶部100に記憶された既存のセッション情報を、共通鍵を用いて暗号化した上で、Webサービスの提供を新たに行うWebサーバ20に対して送信する。
The session
Further, the session
Further, the session
このように、Webクライアント10は、既存の(更新された)セッション情報を、セッション情報記憶部100に記憶しておき、新たにWebサービスの提供を行うWebサーバ20に対して送信することができる。
In this way, the
<Webサーバ>
図3は、本実施形態に係るWebサーバ20の構成例を示す機能ブロック図である。
Webサーバ20は、Webクライアント10からの要求により、Webサービスを提供する装置である。このWebサーバ20は、自身と1対1に対応した不揮発ストレージ200を備える。また、各Webサーバ20は、Webクライアント10が移動した場合でも、移動元と移動先のWebサーバ20においてセッション情報の同期は行わず、移動先のWebサーバ20は、セッション情報をWebクライアント10から取得する。そして、移動先のWebサーバ20やスケールアウトにより増設されたWebサーバ20は、移動元や増設する前のWebサーバ20に対し、セッション情報の削除指示メッセージを送信することにより、不要となったセッション情報を削除させる。
このWebサーバ20は、図3に示すように、制御部21と、入出力部22と、メモリ部23と、不揮発ストレージ200とを備える。
<Web server>
FIG. 3 is a functional block diagram showing a configuration example of the
The
As shown in FIG. 3, the
入出力部22は、Webクライアント10や他のWebサーバ20等との間で情報の送受信を行うための通信インタフェースと、タッチパネルやキーボード等の入力装置や、モニタ等の出力装置との間で情報の送受信を行うための入出力インタフェースとから構成される。
The input /
メモリ部23は、RAM等の一次記憶装置からなり、制御部21によるデータ処理に必要な情報を一時的に記憶する。
不揮発ストレージ200は、ハードディスクやフラッシュメモリ等の記憶装置からなり、Webサービスを提供する際に更新されるセッション情報を記憶する。
なお、この不揮発ストレージ200には、ユーザ登録サーバ30や、Webクライアント10、他のWebサーバ20との間で共有された鍵(共通鍵)が格納される。
なお、この不揮発ストレージ200は、Webサーバ20の外部に設置され、1対1で接続される構成でも構わない。
The
The
The
The
制御部21は、Webサーバ20全体の制御を司り、セッション情報制御部211と、サービス提供部218と、サーバ負荷監視部219とを含んで構成される。
なお、この制御部21は、例えば、不揮発ストレージ200に格納されたプログラムを不図示のCPUが、メモリ部23としてのRAMに展開し実行することにより実現される。
The
The
セッション情報制御部211は、Webサーバ20がWebクライアント10に対してWebサービスを提供する際のセッション情報の制御を実行する機能を備え、セッション情報受信部212、セッション情報生成部213、セッション情報送信部214、セッション情報取得部215、セッション情報削除部216およびセッション情報分配部217を備える。
The session
セッション情報受信部212は、Webクライアント10から、Webサービスの提供を要求するサービス要求メッセージを受信すると、そのWebサービスの提供に必要となるセッション情報の送信を指示するセッション情報要求メッセージをWebクライアント10に送信する。
そして、セッション情報受信部212は、Webクライアント10や他のWebサーバ20から暗号化されたセッション情報を受信すると、不揮発ストレージ200に記憶されている共通鍵を用いて復号化し、セッション情報を抽出する。
Upon receiving the service request message requesting the provision of the Web service from the
When the session
セッション情報生成部213は、セッション情報受信部212が受信し復号化したセッション情報について、Webサービスの提供に伴う新たなセッション情報(以下、「新セッション情報」「更新されたセッション情報」と称する場合がある。)を生成する。また、セッション情報生成部213は、新セッション情報を生成する際に、そのWebサーバ20自身のアドレス(例えば、IPアドレス)を含めて生成する。
そして、セッション情報生成部213は、そのWebサーバ20自身のアドレス(IPアドレス)を含む新セッション情報を、不揮発ストレージ200に記憶する。
Regarding the session information received and decrypted by the session
Then, the session
セッション情報送信部214は、セッション情報生成部213が生成(更新)したそのWebサーバ20自身のアドレス(IPアドレス)を含む新セッション情報(更新されたセッション情報)を共通鍵を用いて暗号化し、Webクライアント10に送信する。
The session information transmission unit 214 encrypts new session information (updated session information) including the address (IP address) of the
セッション情報取得部215は、セッション情報受信部212が受信したセッション情報では、サービス提供部218がWebサービスを提供するための情報(セッション情報)が不足していると判定した場合(つまり、セッション情報が最新の情報でない場合)に、ネットワーク内に存在する各Webサーバ20に向けて、既存のセッション情報(既存セッション情報)の問合せメッセージをブロードキャストで送信する。なお、セッション情報取得部215は、例えば、Webクライアント10に固有の認証ID等を付して、既存セッション情報の問合せメッセージを送信する。
When the session information acquisition unit 215 determines that the session information received by the session
また、セッション情報取得部215は、自身以外の他のWebサーバ20から既存セッション情報の問合せメッセージを受信すると、不揮発ストレージ200内のセッション情報を検索する。そして、セッション情報取得部215は、該当する認証IDが付されたセッション情報を保存していた場合には、そのセッション情報を、既存セッション情報の問合せメッセージを送信してきたWebサーバ20に向けて送信する。
When the session information acquisition unit 215 receives an inquiry message for existing session information from another
セッション情報削除部216は、Webクライアント10や他のWebサーバ20から既存のセッション情報を取得した場合に、その既存のセッション情報を記憶しているWebサーバ20に対し、当該セッション情報の削除指示メッセージを送信する。
When the session information deletion unit 216 acquires existing session information from the
また、セッション情報削除部216は、他のWebサーバ20からセッション情報の削除指示メッセージを受信した場合に、その既存のセッション情報を、不揮発ストレージ200から削除する。
Further, when the session information deletion unit 216 receives a session information deletion instruction message from another
セッション情報分配部217は、サーバ負荷監視部219が、Webサーバ20自身の負荷が所定の閾値を超えたと判定した場合に、ネットワーク管理者(ネットワーク管理装置等)に、新たなWebサーバ20の増設を要求する。これにより、新たなWebサーバ20が増設される。そして、セッション情報分配部217は、自身が担当していたWebクライアント10のセッション情報を、そのまま自身が担当するセッション情報と、新たに増設されたWebサーバ20が担当するセッション情報とに分配する。この分配の手法は、均等に振り分けてもよいし、そのWebサーバ20の性能等に基づき分配比率を決定して振り分けてもよく、予め分配のためのロジックを格納しておけばよい。
また、セッション情報分配部217が、新たなWebサーバ20のアドレス(IPアドレス)をネットワーク管理装置等から取得し、DNSサーバ40に登録するように依頼するようにしてもよい。
When the server
Further, the session
サービス提供部218は、Webクライアント10からの要求のあったWebサービスを提供する処理を行う。
また、サービス提供部218は、セッション情報受信部212が受信したセッション情報では、情報が不足して当該セッションを継続できない場合には、その旨の情報をセッション情報取得部215に出力する。
The
Further, when the session information received by the session
サーバ負荷監視部219は、予め設定されたサーバの負荷情報を収集し、所定の閾値を超えたか否かを監視する。サーバの負荷情報としては、例えば、CPU使用率やメモリ使用率であったり、不揮発ストレージ200の使用率であったりしてもよい。
サーバ負荷監視部219は、所定の閾値を超えた場合に、その旨の情報(監視情報)をセッション情報分配部217に出力する。
The server
The server
このように、Webサーバ20は、Webクライアント10が移動した場合であっても、Webサーバ20同士ではセッション情報の同期は行わない。その代わりに、Webサーバ20は、必要となるセッション情報を、Webクライアント10や他のWebサーバ20から取得する。そして、Webサーバ20は、セッション情報を取得すると、他のWebサーバ20に対して、不要なセッション情報の削除指示メッセージを送信することにより、そのセッション情報を削除させることができる。
In this way, the
≪処理の流れ≫
次に、本実施形態に係るセッション情報管理システム1が実行する処理の流れについて説明する。ここでは、(1)Webサーバ20をまたがってWebクライアント10が移動する場合、(2)Webクライアント10が障害発生等によりセッション情報を喪失した場合、(3)Webクライアント10の増加等によりWebサーバ20のスケールアウトを実行しセッション情報を分配する場合、を例に説明する。
≪Process flow≫
Next, a flow of processing executed by the session
<Webクライアントの移動>
図4は、本実施形態係るセッション情報管理システム1において、Webサーバ20をまたがってWebクライアント10が移動した場合の処理を示すシーケンス図である。
<Move Web Client>
FIG. 4 is a sequence diagram showing processing in the session
まず、Webクライアント10のユーザ登録要求部111は、Webサービスを利用するために、ユーザ登録サーバ30に対し、ユーザ登録要求メッセージを送信する(ステップS1)。
First, the user
続いて、ユーザ登録サーバ30は、Webクライアント10からユーザ登録要求メッセージを受信すると、初期セッション情報DB300(図1)を参照し、ユーザ登録要求メッセージを送信してきたWebクライアント10に関する初期セッション情報を抽出する(ステップS2)。
そして、ユーザ登録サーバ30は、Webクライアント10および各Webサーバ20との間で共有された鍵(共通鍵)を用いて初期セッション情報を暗号化し、Webクライアント10に送信する(ステップS3)。
Subsequently, when the
Then, the
次に、Webクライアント10のユーザ登録要求部111が、ユーザ登録サーバ30から暗号化された初期セッション情報を受信する。そして、その暗号化された初期セッション情報を、セッション情報処理部113が復号化し、セッション情報記憶部100に記憶する(ステップS4)。
Next, the user
続いて、Webクライアント10のアドレス問合せ部112は、Webサービスを利用するWebサーバ20のアドレス(IPアドレス)の問合せメッセージ(アドレス問合せメッセージ)を、DNSサーバ40に送信する(ステップS5)。
Next, the
そして、DNSサーバ40は、Webクライアント10からWebサーバ20のアドレス問合せメッセージを受信すると、Webクライアント10を収容する拠点内ネットワーク(NW)5に属するWebサーバ20(例えば、最寄のWebサーバ20)のアドレス(IPアドレス)を、Webサーバアドレス情報DB400(図1)を参照して抽出する。続いて、DNSサーバ40は、抽出したWebサーバ20のIPアドレスをWebクライアント10に送信する(ステップS6)。
ここでは、DNSサーバ40が、Webクライアント10の最寄りのWebサーバ20として、Webサーバ20(Webサーバ「1」)を抽出し、そのIPアドレスをWebクライアント10に送信したものとする。
Then, when the
Here, it is assumed that the
次に、Webクライアント10のアドレス問合せ部112がWebサーバ20のIPアドレスを受信すると、セッション情報処理部113は、そのIPアドレスを用いて、Webサーバ20に対し、サービス要求メッセージ(ここでは、サービス要求「1」とする。)を送信する(ステップS7)。
ここでは、Webクライアント10が、Webサーバ20(Webサーバ「1」)にサービス要求メッセージ(サービス要求「1」)を送信する。
Next, when the
Here, the
サービス要求メッセージ(サービス要求「1」)を受信したWebサーバ20(Webサーバ「1」)のセッション情報受信部212は、そのWebサービスの提供に必要となるセッション情報の送信を指示するセッション情報要求メッセージを、例えばHTMLにより生成し、Webクライアント10に送信する(ステップS8)。
Upon receiving the service request message (service request “1”), the session
続いて、Webクライアント10のセッション情報処理部113は、セッション情報要求メッセージを受信すると、セッション情報記憶部100に記憶された初期セッション情報を抽出し、共通鍵を用いて暗号化した上で、例えば、POSTを使ってその初期セッション情報をWebサーバ20(Webサーバ「1」)に送信する(ステップS9)。
Subsequently, when the session
次に、暗号化された初期セッション情報を受信したWebサーバ20(Webサーバ「1」)のセッション情報受信部212は、その初期セッション情報を復号化し、セッション情報生成部213に出力する。セッション情報生成部213は、そのWebサーバ20自身のアドレス(IPアドレス)を含む更新されたセッション情報(新セッション情報「1」)を生成し、不揮発ストレージ200に記憶する(ステップS10)。
また、セッション情報送信部214は、セッション情報生成部213が生成したWebサーバ20のアドレスを含む新セッション情報「1」を共通鍵を用いて暗号化し、暗号化した新セッション情報「1」を含むHTMLを、Webクライアント10に送信する(ステップS11)。
Next, the session
Further, the session information transmitting unit 214 encrypts the new session information “1” including the address of the
Webクライアント10は、Webサーバ20(Webサーバ「1」)から暗号化された新セッション情報「1」を受信すると、セッション情報処理部113が復号化し、その新セッション情報「1」をセッション情報記憶部100に記憶する(ステップS12)。
その後、Webクライアント10は、Webサーバ20のWebサービスの提供によりセッション情報が更新される度に、Webサーバ20から更新されたセッション情報(新セッション情報)を受信し、その新セッション情報を既存のセッション情報として不揮発ストレージ200に記憶する。
When the
After that, the
ここで、Webクライアント10が図1に示す拠点内ネットワーク5(5−1)(拠点内NW「1」)から拠点内ネットワーク5(5−2)(拠点内NW「2」)へ通信接続されるエリアを移動したものとして、以下において説明する。
Here, the
このWebクライアント10は、拠点内NW「1」のWebサーバ20(Webサーバ「1」)と通信接続できなくなったこと等により、再度、DNSサーバ40に対しWebサーバ20のアドレス(IPアドレス)の問合せメッセージ(アドレス問合せメッセージ)を送信する処理を行う(ステップS21)。そして、DNSサーバ40は、Webクライアント10が移動した先の拠点内NW「2」に属するWebサーバ20(Webサーバ「2」)のアドレス(IPアドレス)を、Webサーバアドレス情報DB400を参照して抽出し、Webクライアント10に返信する(ステップS22)。
The
次に、Webクライアント10のアドレス問合せ部112がWebサーバ20(Webサーバ「2」)のIPアドレスを受信すると、セッション情報処理部113は、そのIPアドレスを用いて、Webサーバ20(Webサーバ「2」)に対し、サービス要求メッセージ(ここでは、サービス要求「2」とする。)を送信する(ステップS23)。
Next, when the
サービス要求メッセージ(サービス要求「2」)を受信したWebサーバ20(Webサーバ「2」)のセッション情報受信部212は、そのWebサービスの提供に必要となるセッション情報の送信を指示するセッション情報要求メッセージを、例えばHTMLにより生成し、Webクライアント10に送信する(ステップS24)。
Upon receiving the service request message (service request “2”), the session
続いて、Webクライアント10のセッション情報処理部113は、セッション情報要求メッセージを受信すると、セッション情報記憶部100に記憶された、Webサーバ20(Webサーバ「1」)のアドレスを含む既存のセッション情報(新セッション情報「1」)を抽出し、共通鍵を用いて暗号化した上で、例えば、POSTを使って移動先のWebサーバ20(Webサーバ「2」)に送信する(ステップS25)。
Subsequently, when the session
暗号化された既存のセッション情報(新セッション情報「1」)を受信した移動先のWebサーバ20(Webサーバ「2」)のセッション情報受信部212は、その既存のセッション情報を復号化し、セッション情報生成部213に出力する。セッション情報生成部213は、そのWebサーバ20(Webサーバ「2」)自身のアドレス(IPアドレス)を含む更新したセッション情報(新セッション情報「2」)(第2の新セッション情報)を生成し、不揮発ストレージ200に記憶する(ステップS26)。
また、セッション情報送信部214は、セッション情報生成部213が生成したWebサーバ20(Webサーバ「2」)のアドレスを含む新セッション情報「2」を共通鍵を用いて暗号化し、暗号化した新セッション情報「2」を含むHTMLを、Webクライアント10に送信する(ステップS27)。
Upon receiving the encrypted existing session information (new session information “1”), the session
Further, the session information transmission unit 214 encrypts the new session information “2” including the address of the Web server 20 (Web server “2”) generated by the session
Webクライアント10は、Webサーバ20(Webサーバ「2」)から暗号化された新セッション情報「2」を受信すると、セッション情報処理部113が復号化し、その新セッション情報「2」を既存のセッション情報としてセッション情報記憶部100に記憶する(ステップS28)。
When the
一方、移動先のWebサーバ20(Webサーバ「2」)のセッション情報削除部216は、Webクライアント10から既存のセッション情報(新セッション情報「1」)をセッション情報取得部215が取得した場合に、その既存のセッション情報に付されたアドレス(IPアドレス)(ここでは、Webサーバ「1」のIPアドレス)を参照し、そのIPアドレスのWebサーバ20(ここでは、移動元のWebサーバ「1」)宛てに、当該セッション情報(新セッション情報「1」)の削除指示メッセージを送信する(ステップS29)。
On the other hand, when the session information acquisition unit 215 acquires the existing session information (new session information “1”) from the
新セッション情報「1」の削除指示メッセージを受信した移動元のWebサーバ20(Webサーバ「1」)のセッション情報削除部216は、当該セッション情報を不揮発ストレージ200から削除する(ステップS30)。 The session information deleting unit 216 of the Web server 20 (Web server “1”) of the movement source that has received the deletion instruction message of the new session information “1” deletes the session information from the nonvolatile storage 200 (step S30).
このようにすることで、セッション情報管理システム1では、セッション情報をWebクライアント10に記憶させておき、Webサーバ20をまたがってWebクライアント10が移動した際には、Webクライアント10から移動先のWebサーバ20がセッション情報を取得することができる。よって、Webサーバ20同士でセッション情報を同期させておく必要がない。また、移動元のWebサーバ20に対して、移動先のWebサーバ20が削除指示メッセージを送信することにより、不要となった既存のセッション情報を削除させることができる。
By doing so, in the session
<セッション情報喪失>
図5は、本実施形態係るセッション情報管理システム1において、Webクライアント10が記憶するセッション情報を障害等により喪失した場合の処理を示すシーケンス図である。
ここでは、Webクライアント10において障害等が発生し、セッション情報記憶部100に記憶された既存のセッション情報(新セッション情報)を喪失したものとする。また、その際に、Webクライアント10が図1に示す拠点内ネットワーク5(5−1)(拠点内NW「1」)から拠点内ネットワーク5(5−2)(拠点内NW「2」)へ通信接続されるエリアを移動したものとして、以下において説明する。
なお、図4のステップS1〜S12までの処理が既に実行されたものとして説明する。
<Loss of session information>
FIG. 5 is a sequence diagram showing processing in the session
Here, it is assumed that a failure or the like has occurred in the
It should be noted that the description will be made assuming that the processing of steps S1 to S12 in FIG.
障害等によりセッション情報を喪失すると、セッション情報を喪失したそのWebクライアント10は、自身のセッション情報記憶部100からセッション情報を取得できない。そのため、Webクライアント10は、図4のステップS1〜S6と同様の処理を再度行う。つまり、Webクライアント10は、ユーザ登録サーバ30に対しユーザ登録要求メッセージを送信して初期セッション情報を取得してセッション情報記憶部100に記憶し、DNSサーバ40からWebサーバ20のアドレス(IPアドレス)を取得する処理を行う(ステップS31〜S36)。
この際、DNSサーバ40は、Webクライアント10が移動した先の拠点内ネットワーク5(5−2)(拠点内NW「2」)に属するWebサーバ20(Webサーバ「2」)のアドレス(IPアドレス)を、Webサーバアドレス情報DB400を参照して抽出し、Webクライアント10に送信するものとする(ステップS36)。
その後、図4のステップS7〜S9と同様の処理を行い、Webクライアント10は、サービス要求(ここでは、サービス要求「3」とする。)を移動先のWebサーバ20(Webサーバ「2」)に送信することにより、セッション情報要求メッセージを受信し、初期セッション情報を暗号化してWebサーバ20(Webサーバ「2」)に送信する(ステップS37〜S39)。
When the session information is lost due to a failure or the like, the
At this time, the
After that, the same processing as steps S7 to S9 in FIG. 4 is performed, and the
続いて、暗号化された初期セッション情報を受信したWebサーバ20(Webサーバ「2」)のセッション情報受信部212は、その初期セッション情報を復号化する。そして、その初期セッション情報に基づき、サービス提供部218がWebサービスを継続して提供しようとする。しかしながら、サービス提供部218では、必要なセッション情報が不足しているため当該セッションを継続できないと判定し、その旨の情報を、セッション情報取得部215に出力する。この場合、セッション情報取得部215は、ネットワーク内に存在する各Webサーバ20に向けて、ブロードキャストにより既存セッション情報(新セッション情報「1」)の問合せメッセージの送信を行う(ステップS40)。
Subsequently, the session
ブロードキャストにより既存セッション情報の問合せメッセージを受信したWebサーバ20(ここでは、Webサーバ「1」)のセッション情報取得部215は、自身の不揮発ストレージ200を検索し、該当するWebクライアント10の認証IDが付されたセッション情報(新セッション情報「1」)を記憶していた場合には、その既存のセッション情報(新セッション情報「1」)を、暗号化した上で、既存セッション情報の問合せメッセージを送信してきたWebサーバ20(Webサーバ「2」)に向けて送信する(ステップS41)。
The session information acquisition unit 215 of the Web server 20 (here, Web server “1”) that has received the inquiry message for the existing session information by broadcasting searches its own
暗号化された既存のセッション情報(新セッション情報「1」)を受信したWebサーバ20(Webサーバ「2」)のセッション情報受信部212は、その既存のセッション情報を復号化し、セッション情報生成部213に出力する。セッション情報生成部213は、そのWebサーバ20(Webサーバ「2」)自身のアドレス(IPアドレス)を含む更新したセッション情報(新セッション情報「2」)(第2の新セッション情報)を生成し、不揮発ストレージ200に記憶する(ステップS42)。
The session
その後は、図4のステップS27〜S30と同様に、Webサーバ20(Webサーバ「2」)は、Webサーバ「2」のアドレスを含む新セッション情報「2」をWebクライアント10に送信して記憶させるとともに、Webサーバ「1」に対して、削除指示メッセージを送信して、既存のセッション情報(新セッション情報「1」)を削除させる(ステップS43〜S46)。
After that, similarly to steps S27 to S30 of FIG. 4, the web server 20 (web server “2”) transmits the new session information “2” including the address of the web server “2” to the
なお、ここでは、Webクライアント10がセッション情報を喪失し、かつ、Webサーバ20をまたがって移動した場合について説明した。しかしながら、Webクライアント10がセッション情報を喪失した場合であっても、喪失前と同じWebサーバ20と接続できる場合にあっては、そのWebサーバ20の不揮発ストレージ200(ここでは、Webサーバ「1」の不揮発ストレージ「1」)に記憶された既存のセッション情報を用いて、セッションを継続しWebサービスを提供することができる。
Here, the case where the
このようにすることで、セッション情報管理システム1では、Webクライアント10が障害等によりセッション情報を喪失した場合であっても、Webサーバ20同士でセッション情報を同期させることなく、確実にサービスを継続して提供することが可能となる。
By doing so, in the session
<セッション情報の分配>
次に、Webクライアント10の増加等に伴ってWebサーバ20のスケールアウトを実行しセッション情報を分配する場合について説明する。
図6は、本実施形態に係るセッション情報管理システム1において、Webサーバ20のスケールアウトを実行しセッション情報を分配する場合の処理を示すシーケンス図である。
ここでは、図4のステップS1〜S12が実行され、Webクライアント10とWebサーバ20(Webサーバ「1」)との間で、Webサービスの提供が行われているものとする。
<Distribution of session information>
Next, a case where the scale-out of the
FIG. 6 is a sequence diagram showing processing in the session
Here, it is assumed that steps S1 to S12 of FIG. 4 are executed and the web service is provided between the
この状態において、Webサーバ20(Webサーバ「1」)のサーバ負荷監視部219が、CPU使用率等の負荷情報の値が所定の閾値を超えたと判定したものとする。その場合、サーバ負荷監視部219は、その旨の情報(監視情報)をセッション情報分配部217に出力する。
そして、セッション情報分配部217は、自身のWebサーバ20(Webサーバ「1」)の負荷が所定の閾値を超えたことにより、Webサーバ20を増設すると判定する(ステップS51)。そして、セッション情報分配部217は、ネットワーク管理者(ネットワーク管理装置等)に新たなWebサーバ20の増設を要求する。これにより、新たなWebサーバ20(ここでは、Webサーバ「3」とする。)が増設される。また、Webサーバ「1」は、増設されたWebサーバ20(Webサーバ「3」)のアドレス(IPアドレス)をネットワーク管理装置等から取得する。
In this state, it is assumed that the server
Then, the session
次に、セッション情報分配部217は、新たなWebサーバ20(Webサーバ「3」)が増設されると、自身の不揮発ストレージ200に記憶している既存のセッション情報を、そのまま自身が担当するセッション情報と、新たに増設されたWebサーバ20(Webサーバ「3」)が担当するセッション情報とに分配する(ステップS52)。
なお、ここで、セッション情報分配部217は、増設されたWebサーバ20(Webサーバ「3」)のアドレス(IPアドレス)をDNSサーバ40に登録するため、DNSサーバ40に、Webサーバアドレス情報DB400の更新依頼を送信しておくようにしてもよい。
Next, when a new Web server 20 (Web server “3”) is added, the session
Since the session
続いて、Webクライアント10のセッション情報処理部113が、Webサービスの提供を受けるため、Webサーバ20(Webサーバ「1」)のアドレスを含む既存のセッション情報(新セッション情報「1」)を暗号化した上で、Webサーバ20(Webサーバ「1」)に送信する(ステップS53)。
Subsequently, the session
既存のセッション情報を受信したWebサーバ20(Webサーバ「1」)のセッション情報分配部217は、その既存のセッション情報に付された認証ID等に基づき、当該既存のセッション情報について自身が担当であるか、もしくは、増設した新たなWebサーバ20(Webサーバ「3」)が担当であるかを判定する。そして、セッション情報分配部217は、そのセッション情報が、新たなWebサーバ20(Webサーバ「3」)に分配したセッション情報であると判定した場合に、増設したWebサーバ20(Webサーバ「3」)へのリダイレクト(Redirect)指示メッセージを、増設したWebサーバ20(Webサーバ「3」)のIPアドレスとともに、Webクライアント10へ送信する(ステップS54)。
The session
次に、Webクライアント10のセッション情報処理部113は、リダイレクト指示メッセージに付された増設されたWebサーバ20(Webサーバ「3」)のアドレス(IPアドレス)を用いて、増設されたWebサーバ20(Webサーバ「3」)に、Webサーバ20(Webサーバ「1」)のアドレスを含む既存のセッション情報(新セッション情報「1」)を、暗号化した上で送信する(ステップS55)。
Next, the session
暗号化された既存のセッション情報を受信したWebサーバ20(Webサーバ「3」)のセッション情報受信部212は、その既存のセッション情報(新セッション情報「1」)を復号化し、セッション情報生成部213に出力する。セッション情報生成部213は、そのWebサーバ20(Webサーバ「3」)自身のアドレス(IPアドレス)を含む更新したセッション情報(新セッション情報「3」)(第2の新セッション情報)を生成し、不揮発ストレージ200に記憶する(ステップS56)。
The session
その後は、図4のステップS27〜S30と同様に、Webサーバ20(Webサーバ「3」)は、Webサーバ「3」のアドレスを含む新セッション情報「3」をWebクライアント10に送信して記憶させるとともに、Webサーバ「1」に対して、削除指示メッセージを送信して、既存のセッション情報(新セッション情報「1」)を削除させる(ステップS57〜S60)。
After that, as in steps S27 to S30 of FIG. 4, the web server 20 (web server “3”) transmits new session information “3” including the address of the web server “3” to the
このようにすることで、セッション情報管理システム1では、Webクライアント10の増加等によりWebサーバ20のスケールアウトを実行しセッション情報を分配した場合においても、セッション情報をWebクライアント10が記憶しておくことにより、増設されたWebサーバ20がWebクライアント10からセッション情報を取得することができる。よって、セッション情報の分配に伴う複雑な処理を実行する必要がない。また、分配元のWebサーバ20(Webサーバ「1」)に対して、分配先のWebサーバ20(Webサーバ「3」)が削除指示メッセージを送信することにより、不要となった既存のセッション情報を削除させることができる。
By doing so, in the session
以上説明したように、本実施形態に係るセッション情報管理システム1によれば、複数のWebサーバでの重複したセッション情報の保持をなくし、かつ、Webサーバのスケールアウトや障害復旧を容易に行うことが可能となる。
As described above, according to the session
1 セッション情報管理システム
5 拠点内ネットワーク(NW)
6 拠点間ネットワーク(NW)
10 Webクライアント
11,21 制御部
12,22 入出力部
13,23 メモリ部
14 記憶部
20 Webサーバ
30 ユーザ登録サーバ
40 DNSサーバ
100 セッション情報記憶部(Web Storage)
111 ユーザ登録要求部
112 アドレス問合せ部
113 セッション情報処理部
200 不揮発ストレージ
211 セッション情報制御部
212 セッション情報受信部
213 セッション情報生成部
214 セッション情報送信部
215 セッション情報取得部
216 セッション情報削除部
217 セッション情報分配部
218 サービス提供部
219 サーバ負荷監視部
300 初期セッション情報DB
400 Webサーバアドレス情報DB
1 Session
6 Network between bases (NW)
10
111 user
400 Web server address information DB
Claims (6)
前記Webサーバのそれぞれは、
前記Webサーバそれぞれに1対1で対応する不揮発ストレージと、
前記Webクライアントから前記Webサービスの提供のための初期セッション情報を受信するセッション情報受信部と、
前記受信した初期セッション情報に、当該Webサーバのアドレスを付して更新したセッション情報を示す新セッション情報を生成するとともに、生成した前記新セッション情報を前記不揮発ストレージに記憶するセッション情報生成部と、
前記生成した新セッション情報を前記Webクライアントに送信するセッション情報送信部と、を備え、
前記Webクライアントは、
前記Webサービスの提供を受けるためのセッション情報を記憶するセッション情報記憶部と、
前記初期セッション情報をユーザ登録サーバから取得するユーザ登録要求部と、
前記初期セッション情報を前記Webサーバに送信するとともに、前記Webサーバから受信した前記新セッション情報を前記セッション情報記憶部に記憶するセッション情報処理部と、を備え、
前記新セッション情報が、前記Webサーバの前記不揮発ストレージと、前記Webクライアントの前記セッション情報記憶部との両方に記憶されること
を特徴とするセッション情報管理システム。 A session information management system including a plurality of web servers that provide web services to web clients,
Each of the web servers
A non-volatile storage that corresponds to each of the Web servers on a one-to-one basis;
A session information receiving unit that receives initial session information for providing the Web service from the Web client;
A session information generation unit that generates new session information indicating the updated session information by adding the Web server address to the received initial session information, and stores the generated new session information in the nonvolatile storage.
A session information transmitting unit that transmits the generated new session information to the Web client,
The Web client is
A session information storage unit that stores session information for receiving the provision of the Web service;
A user registration request unit that acquires the initial session information from a user registration server;
A session information processing unit that transmits the initial session information to the Web server and stores the new session information received from the Web server in the session information storage unit ;
A session information management system , wherein the new session information is stored in both the non-volatile storage of the Web server and the session information storage unit of the Web client .
当該Webクライアントが移動することにより、前記新セッション情報を用いた前記Webサーバとの間のWebサービスの提供が受けられない場合に、
前記セッション情報記憶部に記憶された新セッション情報を抽出し、新たにWebサービスの提供先となる他のWebサーバに、抽出した前記新セッション情報を送信すること
を特徴とする請求項1に記載のセッション情報管理システム。 The session information processing unit of the Web client,
When the web client cannot be provided with the web service using the new session information due to the movement of the web client,
The new session information stored in the session information storage unit is extracted, and the extracted new session information is transmitted to another Web server that is a new provision destination of the Web service. Session information management system.
前記セッション情報生成部が、前記Webクライアントから前記新セッション情報を受信した場合に、当該Webサーバのアドレスを付して更新した第2の新セッション情報を生成し、前記不揮発ストレージに記憶し、
前記セッション情報送信部は、生成した前記第2の新セッション情報を前記Webクライアントに送信する処理を行い、
前記セッション情報削除部は、前記新セッション情報に付されたWebサーバのアドレスを抽出し、当該抽出したアドレスのWebサーバに対し、新セッション情報の削除指示を送信し、
前記新セッション情報の削除指示を受信したWebサーバのセッション情報削除部は、自身の前記不揮発ストレージに記憶されている前記新セッション情報を削除すること
を特徴とする請求項2に記載のセッション情報管理システム。 Each of the Web servers further includes a session information deleting unit,
When the session information generation unit receives the new session information from the Web client, the session information generation unit generates second new session information updated with the address of the Web server, and stores the new new session information in the nonvolatile storage,
The session information transmission unit performs a process of transmitting the generated second new session information to the Web client,
The session information deletion unit extracts the address of the Web server attached to the new session information, and transmits a new session information deletion instruction to the Web server having the extracted address,
The session information management unit according to claim 2, wherein the session information deletion unit of the Web server that has received the instruction to delete the new session information deletes the new session information stored in the nonvolatile storage of itself. system.
前記セッション情報取得部は、自身の不揮発ストレージに記憶されたセッション情報では、前記Webクライアントに対するWebサービスの提供ができないと判定した場合に、前記Webサーバのそれぞれに対し、当該Webクライアントに関する前記新セッション情報を問い合わせて取得し、自身のアドレスを付して更新した第2の新セッション情報を生成して、前記不揮発ストレージに記憶し、
前記セッション情報送信部は、生成した前記第2の新セッション情報を前記Webクライアントに送信する処理を行い、
前記セッション情報削除部は、前記新セッション情報に付されたWebサーバのアドレスを抽出し、当該抽出したアドレスのWebサーバに対し、新セッション情報の削除指示を送信し、
前記新セッション情報の削除指示を受信したWebサーバのセッション情報削除部は、自身の前記不揮発ストレージに記憶されている前記新セッション情報を削除すること
を特徴とする請求項1に記載のセッション情報管理システム。 Each of the Web servers further includes a session information acquisition unit and a session information deletion unit,
When the session information acquisition unit determines that the Web service cannot be provided to the Web client based on the session information stored in the non-volatile storage of the session information acquisition unit, the new session related to the Web client is provided to each of the Web servers. Inquiring and acquiring information, generating second new session information updated with its own address, and storing it in the non-volatile storage,
The session information transmission unit performs a process of transmitting the generated second new session information to the Web client,
The session information deletion unit extracts the address of the Web server attached to the new session information, and transmits a new session information deletion instruction to the Web server having the extracted address,
The session information managing unit according to claim 1, wherein the session information deleting unit of the Web server that has received the deletion instruction of the new session information deletes the new session information stored in the nonvolatile storage of itself. system.
前記サーバ負荷監視部は、自身のWebサーバの負荷情報を監視し、当該負荷情報の値が所定の閾値を超えたことを示す監視情報を、前記セッション情報分配部に出力し、
前記セッション情報分配部は、
前記監視情報を取得した場合に、自身の前記不揮発ストレージに記憶しているセッション情報を、自身が担当するセッション情報と、増設されたWebサーバに担当させるセッション情報とに分配し、
前記Webクライアントから、前記増設されたWebサーバに担当させるセッション情報である前記新セッション情報を用いたWebサービスの提供要求を受信すると、前記増設されたWebサーバのアドレスを含むリダイレクト指示を当該Webクライアントに送信し、
前記リダイレクト指示を受信したWebクライアントは、
前記増設されたWebサーバのアドレスを用いて当該Webサーバに前記新セッション情報を送信し、
前記増設されたWebサーバは、
前記セッション情報生成部が、前記Webクライアントから前記新セッション情報を受信し、当該増設されたWebサーバのアドレスを付して更新した第2の新セッション情報を生成し、前記不揮発ストレージに記憶し、
前記セッション情報送信部は、生成した前記第2の新セッション情報を前記Webクライアントに送信する処理を行い、
前記セッション情報削除部は、前記新セッション情報に付されたWebサーバのアドレスを抽出し、当該抽出したアドレスのWebサーバに対し、新セッション情報の削除指示を送信し、
前記新セッション情報の削除指示を受信したWebサーバのセッション情報削除部は、自身の前記不揮発ストレージに記憶されている前記新セッション情報を削除すること
を特徴とする請求項1に記載のセッション情報管理システム。 Each of the Web servers further includes a session information distribution unit, a server load monitoring unit, and a session information deletion unit,
The server load monitoring unit monitors the load information of its own Web server, and outputs monitoring information indicating that the value of the load information exceeds a predetermined threshold value to the session information distribution unit,
The session information distribution unit,
When the monitoring information is acquired, the session information stored in the non-volatile storage of itself is distributed to the session information that the user is in charge of and the session information that the added Web server is in charge of.
When a request for providing a Web service using the new session information, which is the session information to be assigned to the added Web server, is received from the Web client, a redirect instruction including the address of the added Web server is issued to the Web client. Sent to
The Web client that received the redirect instruction
Transmitting the new session information to the Web server using the address of the added Web server,
The added Web server is
The session information generation unit receives the new session information from the Web client, generates second new session information updated with the address of the added Web server, and stores the second new session information in the nonvolatile storage,
The session information transmission unit performs a process of transmitting the generated second new session information to the Web client,
The session information deletion unit extracts the address of the Web server attached to the new session information, and transmits a new session information deletion instruction to the Web server having the extracted address,
The session information managing unit according to claim 1, wherein the session information deleting unit of the Web server that has received the deletion instruction of the new session information deletes the new session information stored in the nonvolatile storage of itself. system.
前記Webサーバのそれぞれは、
前記Webサーバそれぞれに1対1で対応する不揮発ストレージを備え、
前記Webクライアントから前記Webサービスの提供のための初期セッション情報を受信するステップと、
前記受信した初期セッション情報に、当該Webサーバのアドレスを付して更新したセッション情報を示す新セッション情報を生成するとともに、生成した前記新セッション情報を前記不揮発ストレージに記憶するステップと、
前記生成した新セッション情報を前記Webクライアントに送信するステップと、を実行し、
前記Webクライアントは、
前記Webサービスの提供を受けるためのセッション情報を記憶するセッション情報記憶部を備え、
前記初期セッション情報をユーザ登録サーバから取得するステップと、
前記初期セッション情報を前記Webサーバに送信するとともに、前記Webサーバから受信した前記新セッション情報を前記セッション情報記憶部に記憶するステップと、を実行し、
前記新セッション情報が、前記Webサーバの前記不揮発ストレージと、前記Webクライアントの前記セッション情報記憶部との両方に記憶されること
を特徴とするセッション情報管理方法。 A session information management method for a session information management system comprising a plurality of Web servers that provide Web services to Web clients, comprising:
Each of the web servers
A non-volatile storage corresponding to each of the Web servers is provided.
Receiving initial session information for providing the web service from the web client;
Generating new session information indicating the updated session information by adding the address of the Web server to the received initial session information, and storing the generated new session information in the nonvolatile storage;
Transmitting the generated new session information to the Web client,
The Web client is
A session information storage unit that stores session information for receiving the provision of the Web service,
Obtaining the initial session information from a user registration server,
Transmitting the initial session information to the Web server and storing the new session information received from the Web server in the session information storage unit ,
The session information management method , wherein the new session information is stored in both the non-volatile storage of the Web server and the session information storage unit of the Web client .
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2017025649A JP6684030B2 (en) | 2017-02-15 | 2017-02-15 | Session information management system and session information management method |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2017025649A JP6684030B2 (en) | 2017-02-15 | 2017-02-15 | Session information management system and session information management method |
Publications (2)
| Publication Number | Publication Date |
|---|---|
| JP2018132920A JP2018132920A (en) | 2018-08-23 |
| JP6684030B2 true JP6684030B2 (en) | 2020-04-22 |
Family
ID=63249706
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP2017025649A Active JP6684030B2 (en) | 2017-02-15 | 2017-02-15 | Session information management system and session information management method |
Country Status (1)
| Country | Link |
|---|---|
| JP (1) | JP6684030B2 (en) |
Family Cites Families (2)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP4149599B2 (en) * | 1999-02-03 | 2008-09-10 | 株式会社東芝 | Session management apparatus and computer-readable recording medium recording session management program |
| EP2881861B1 (en) * | 2012-08-02 | 2017-05-31 | Murakumo Corporation | Load distribution device, information processing system, method, and program |
-
2017
- 2017-02-15 JP JP2017025649A patent/JP6684030B2/en active Active
Also Published As
| Publication number | Publication date |
|---|---|
| JP2018132920A (en) | 2018-08-23 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| CN112035215B (en) | Node autonomous method, system and device of node cluster and electronic equipment | |
| CN102413185B (en) | Cloud platform automatic updating system based on BT technology | |
| US20150095343A1 (en) | Cloud database connection multiplexing | |
| WO2014101889A1 (en) | Data synchronization method and device | |
| CN107888666B (en) | Cross-region data storage system and data synchronization method and device | |
| JP2018506936A (en) | Method and system for an end-to-end solution for distributing content in a network | |
| CN102761599A (en) | Scalable file distribution method used in distributed system | |
| US8655946B2 (en) | Authenticating method, conversion device, and relay device | |
| JP2016162389A (en) | Thin client system, connection management device, virtual machine operating device, method, and program | |
| EP3101539B1 (en) | Selection of compatible resources after updating web application servers | |
| JP6684030B2 (en) | Session information management system and session information management method | |
| JP5109901B2 (en) | Session data sharing method | |
| US10705978B2 (en) | Asynchronous tracking for high-frequency and high-volume storage | |
| CN117008819A (en) | Cache writing method and device and electronic equipment | |
| JP5470148B2 (en) | Node device and computer program | |
| JP6194387B1 (en) | Transfer device, transfer method, and transfer program | |
| JP7236007B2 (en) | Number management system, number management method, number management device and number management program | |
| JP5960690B2 (en) | Network access system | |
| CN117251872A (en) | Local multi-tenant for database system | |
| JP6712112B2 (en) | Programmable device application authentication system and authentication method | |
| JP2014032530A (en) | Distribution processing system and distribution processing method | |
| KR20190015817A (en) | Method, Apparatus and System for Monitoring Using Middleware | |
| JP5658621B2 (en) | Signal distribution duplication destination determination system, signal distribution duplication destination determination method and program | |
| JP7619993B2 (en) | Native Multitenancy for Database Systems | |
| JP4784909B2 (en) | Transaction accelerator, communication system, communication method, and program |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20181213 |
|
| A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20191029 |
|
| A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20191119 |
|
| A521 | Request for written amendment filed |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20200115 |
|
| 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: 20200324 |
|
| A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20200326 |
|
| R150 | Certificate of patent or registration of utility model |
Ref document number: 6684030 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R150 |
|
| S533 | Written request for registration of change of name |
Free format text: JAPANESE INTERMEDIATE CODE: R313533 |
|
| R350 | Written notification of registration of transfer |
Free format text: JAPANESE INTERMEDIATE CODE: R350 |