JP5773910B2 - Access control apparatus, access control method and program - Google Patents

Access control apparatus, access control method and program Download PDF

Info

Publication number
JP5773910B2
JP5773910B2 JP2012043936A JP2012043936A JP5773910B2 JP 5773910 B2 JP5773910 B2 JP 5773910B2 JP 2012043936 A JP2012043936 A JP 2012043936A JP 2012043936 A JP2012043936 A JP 2012043936A JP 5773910 B2 JP5773910 B2 JP 5773910B2
Authority
JP
Japan
Prior art keywords
tenant
database
application
user
parameter
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
Application number
JP2012043936A
Other languages
Japanese (ja)
Other versions
JP2013182310A (en
Inventor
優 小杉
優 小杉
康志 小川
康志 小川
経勝 入不二
経勝 入不二
光義 山足
光義 山足
尚彦 勝山
尚彦 勝山
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Mitsubishi Electric Corp
Mitsubishi Electric Information Network Corp
Original Assignee
Mitsubishi Electric Corp
Mitsubishi Electric Information Network Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Mitsubishi Electric Corp, Mitsubishi Electric Information Network Corp filed Critical Mitsubishi Electric Corp
Priority to JP2012043936A priority Critical patent/JP5773910B2/en
Publication of JP2013182310A publication Critical patent/JP2013182310A/en
Application granted granted Critical
Publication of JP5773910B2 publication Critical patent/JP5773910B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Description

本発明は、アクセス制御装置及びアクセス制御方法及びプログラムに関するものである。本発明は、特に、マルチテナント対応のアクセス制御装置、方法、プログラムに関するものである。   The present invention relates to an access control device, an access control method, and a program. The present invention particularly relates to a multi-tenant compatible access control apparatus, method, and program.

クラウドサービスの普及に伴い、単一のアプリケーションを複数の企業(テナント)で共用する「マルチテナント」型のアプリケーションのサービス形態が普及しつつある。   With the spread of cloud services, service forms of “multi-tenant” type applications in which a single application is shared by a plurality of companies (tenants) are becoming widespread.

「マルチテナント」とは、ハードウェアやソフトウェアを複数の企業で共用可能にした形態のことを指す。クラウドサービスを提供する上で重要となるのは、いかにして低価格でサービスを提供するかである。複数の企業に対して同じサービスを提供する場合、同一のアプリケーションを複数企業に対して提供する「マルチテナント技術」を適用することでソフトウェアやハードウェアのリソースを削減できるため、低価格でのサービス提供が可能になる。   “Multi-tenant” refers to a form in which hardware and software can be shared by multiple companies. The key to providing cloud services is how to provide services at low prices. When providing the same service to multiple companies, it is possible to reduce software and hardware resources by applying “multi-tenant technology” that provides the same application to multiple companies. Provision becomes possible.

シングルテナント型からマルチテナント型のアプリケーションへ移行する際には、コンピュータ資源(PC(パーソナルコンピュータ)サーバ、ハードディスク、APP(アプリケーション)サーバソフトウエア、DBMS(データベース管理システム)等)を複数のテナントで共有する必要がある。このときアプリケーションやデータベース側でテナントを識別し、テナント別のデータアクセスを実現する必要がある。既存のシングルテナント型アプリケーションに改修を加える場合、アプリケーションやデータベースの構造に手を加える必要があるため、一般的に改修コストが膨大になる可能性がある。そこで、既存アプリケーションを可能な限り流用したまま、マルチテナント化することの可能なフレームワークが求められている。   When migrating from single-tenant type to multi-tenant type applications, multiple tenants share computer resources (PC (personal computer) server, hard disk, APP (application) server software, DBMS (database management system), etc.)) There is a need to. At this time, it is necessary to identify the tenant on the application or database side and realize data access for each tenant. When renovating an existing single tenant type application, it is necessary to modify the structure of the application or database, so that the renovation cost may generally be enormous. Therefore, there is a need for a framework that can be multi-tenant while diverting existing applications as much as possible.

従来技術では、既存アプリケーションを用いてマルチテナント対応型のデータベースからデータを読み出す場合、セッション情報からテナントID(識別子)、オーナーID、組織名といったテナントを特定するための情報を取得し、取得した情報に基づいて当該テナントに対応するテーブルを特定したり、読み出すデータを当該テナントに係るデータに絞り込んだりしている(例えば、特許文献1〜3参照)。   In the prior art, when data is read from a multi-tenant compatible database using an existing application, information for identifying a tenant such as a tenant ID (identifier), owner ID, and organization name is acquired from the session information, and the acquired information Based on the table, the table corresponding to the tenant is specified, or the data to be read is narrowed down to the data related to the tenant (see, for example, Patent Documents 1 to 3).

特開2010−26653号公報JP 2010-26653 A 特開2011−60174号公報JP 2011-60174 A 特開2011−113103号公報JP 2011-113103 A

マルチテナントアプリケーションでは、データの分離レベルに応じてデータベース分離モデルが以下の通り定義される。
(1)表共有型:1つのテーブル内に複数のテナントの情報が混在する。
(2)スキーマ分離型:テナントごとに専用のスキーマを用意する。
(3)インスタンス分離型:テナントごとに専用のデータベースインスタンスを生成する。
In a multi-tenant application, a database separation model is defined as follows according to the data separation level.
(1) Table sharing type: Information of a plurality of tenants is mixed in one table.
(2) Schema separation type: A dedicated schema is prepared for each tenant.
(3) Instance separation type: A dedicated database instance is generated for each tenant.

従来技術では、表共有モデルのみ、あるいは、スキーマ分離モデルのみを対象としており、「集約度を上げたい」、「独自のスキーマを使いたい」といった利用者の様々なニーズに合わせてモデルを切り替えるような方式を実現できないという課題があった。   In the conventional technology, only the table sharing model or the schema separation model is targeted, and the model is switched according to various needs of users such as “I want to increase the degree of aggregation” or “I want to use my own schema”. There was a problem that it was impossible to realize a simple method.

本発明は、例えば、既存アプリケーションからマルチテナント対応型のデータベースへのアクセスを制御する際に、テナントのニーズ等に合わせてデータベースの種類を切り替えることを目的とする。   An object of the present invention is, for example, to switch the type of database in accordance with the needs of a tenant when controlling access from an existing application to a multi-tenant compatible database.

本発明の一の態様に係るアクセス制御装置は、
ユーザが少なくとも1人ずつ属する複数のテナントによって共用されるアプリケーションから、前記複数のテナントそれぞれの個別のデータを格納するマルチテナント対応型の少なくとも2種類のデータベースへのアクセスを制御するアクセス制御装置であって、
テナントごとに、テナントを一意に識別するテナント識別子と、アクセス対象とするデータベースの種類とを記憶装置により予め記憶するマルチテナント管理データベースと、
前記アプリケーションに入力されると前記アプリケーションが前記少なくとも2種類のデータベースへのアクセス時に出力するパラメータの入力を、前記複数のテナントのいずれかに属するユーザから入力装置により受け付け、当該ユーザが属するテナントのテナント識別子を前記マルチテナント管理データベースから読み出して当該パラメータに埋め込み、当該パラメータを前記アプリケーションに入力するユーザインタフェース接続部と、
前記ユーザインタフェース接続部により入力されたパラメータが前記アプリケーションから出力された場合、当該パラメータに埋め込まれているテナント識別子を取り出し、取り出したテナント識別子に対応するテナントのデータベースの種類を前記マルチテナント管理データベースから読み出し、前記少なくとも2種類のデータベースのうち、読み出した種類のデータベースに格納された当該テナントの個別のデータへのアクセスを前記アプリケーションに行わせるデータベース接続部とを備える。
An access control apparatus according to one aspect of the present invention provides:
An access control device for controlling access to at least two types of multi-tenant-compatible databases that store individual data of each of the plurality of tenants from an application shared by a plurality of tenants to which at least one user belongs. And
For each tenant, a multi-tenant management database that pre-stores a tenant identifier that uniquely identifies a tenant and the type of database to be accessed by a storage device;
When input to the application, the input of parameters that the application outputs when accessing the at least two types of databases is accepted from a user belonging to one of the tenants by the input device, and the tenant of the tenant to which the user belongs An identifier is read from the multi-tenant management database, embedded in the parameter, and a user interface connection unit that inputs the parameter to the application;
When the parameter input by the user interface connection unit is output from the application, the tenant identifier embedded in the parameter is extracted, and the tenant database type corresponding to the extracted tenant identifier is extracted from the multi-tenant management database. And a database connection unit that causes the application to access individual data of the tenant stored in the read type database among the at least two types of databases.

本発明の一の態様において、アクセス制御装置のユーザインタフェース接続部は、ユーザが属するテナントのテナント識別子をパラメータに埋め込み、当該パラメータをアプリケーションに入力する。アクセス制御装置のデータベース接続部は、ユーザインタフェース接続部により入力されたパラメータがアプリケーションから出力された場合、当該パラメータに埋め込まれているテナント識別子を取り出し、取り出したテナント識別子に対応するテナントのアクセス対象として決められた種類のデータベースに格納された当該テナントの個別のデータへのアクセスをアプリケーションに行わせる。そのため、本発明の一の態様によれば、既存アプリケーションからマルチテナント対応型のデータベースへのアクセスを制御する際に、テナントのニーズ等に合わせてデータベースの種類を切り替えることが可能となる。   In one aspect of the present invention, the user interface connection unit of the access control device embeds the tenant identifier of the tenant to which the user belongs in a parameter, and inputs the parameter to the application. When the parameter input by the user interface connection unit is output from the application, the database connection unit of the access control device extracts the tenant identifier embedded in the parameter and sets it as the access target of the tenant corresponding to the extracted tenant identifier. The application is made to access the individual data of the tenant stored in the determined type of database. Therefore, according to one aspect of the present invention, when controlling access from an existing application to a multi-tenant compatible database, the type of database can be switched in accordance with the tenant's needs and the like.

実施の形態1に係るアクセス制御装置の構成を示すブロック図。FIG. 2 is a block diagram showing a configuration of an access control apparatus according to the first embodiment. 実施の形態1に係るアクセス制御装置のハードウェア構成の一例を示す図。2 is a diagram illustrating an example of a hardware configuration of an access control apparatus according to Embodiment 1. FIG. 実施の形態1に係るマルチテナント管理データベースのテナント管理テーブル、テナント情報結合設定テーブル、データベース接続設定テーブルの構成例を示す図。The figure which shows the example of a structure of the tenant management table of the multi-tenant management database which concerns on Embodiment 1, a tenant information joint setting table, and a database connection setting table. 実施の形態1に係る表共有型データベースの構成例を示す図。FIG. 3 is a diagram showing a configuration example of a table sharing database according to the first embodiment. 実施の形態1に係るスキーマ分離型データベースの構成例を示す図。FIG. 3 is a diagram illustrating a configuration example of a schema separation type database according to the first embodiment. 実施の形態1に係るインスタンス分離型データベースの構成例を示す図。FIG. 3 is a diagram illustrating a configuration example of an instance separation type database according to the first embodiment. 実施の形態1に係るアクセス制御装置の動作を示すシーケンス図。FIG. 3 is a sequence diagram showing an operation of the access control apparatus according to the first embodiment. 実施の形態1に係るアクセス制御装置の動作を示すシーケンス図。FIG. 3 is a sequence diagram showing an operation of the access control apparatus according to the first embodiment. 実施の形態1に係るアクセス制御装置の動作を示すシーケンス図。FIG. 3 is a sequence diagram showing an operation of the access control apparatus according to the first embodiment. 実施の形態1に係るアクセス制御装置の動作を示すシーケンス図。FIG. 3 is a sequence diagram showing an operation of the access control apparatus according to the first embodiment. 実施の形態1に係るアクセス制御装置の動作を示すシーケンス図。FIG. 3 is a sequence diagram showing an operation of the access control apparatus according to the first embodiment. 実施の形態2に係るアクセス制御装置の動作を示すシーケンス図。FIG. 10 is a sequence diagram showing an operation of the access control apparatus according to the second embodiment. 実施の形態3に係るアクセス制御装置の構成を示すブロック図。FIG. 4 is a block diagram showing a configuration of an access control apparatus according to a third embodiment. 実施の形態3に係るマルチテナント管理データベースのデータベース接続設定テーブルの構成例を示す図。The figure which shows the structural example of the database connection setting table of the multi-tenant management database concerning Embodiment 3. FIG. 実施の形態3に係るアクセス制御装置の動作を示すシーケンス図。FIG. 10 is a sequence diagram showing an operation of the access control apparatus according to the third embodiment. 実施の形態3に係るデータチェック部の動作例を示す図。FIG. 10 is a diagram illustrating an operation example of a data check unit according to the third embodiment.

以下、本発明の実施の形態について、図を用いて説明する。   Hereinafter, embodiments of the present invention will be described with reference to the drawings.

実施の形態1.
図1は、本実施の形態に係るアクセス制御装置100の構成を示すブロック図である。
Embodiment 1 FIG.
FIG. 1 is a block diagram showing a configuration of access control apparatus 100 according to the present embodiment.

図1において、アクセス制御装置100は、シングルテナントで利用されていた既存アプリケーション500(マルチテナント非対応型のアプリケーション)から、複数のテナントの情報を一元管理しているマルチテナント型データベース400(マルチテナント対応型のデータベース)へのアクセスを制御する。   In FIG. 1, the access control apparatus 100 includes a multi-tenant database 400 (multi-tenant) that centrally manages information on a plurality of tenants from an existing application 500 (non-tenant-compatible application) used in a single tenant. Control access to supported databases).

既存アプリケーション500は、複数のテナントによって共用されるアプリケーションの一例である。各テナントには、ユーザが少なくとも1人ずつ属するものとする。本実施の形態では、既存アプリケーション500が、テナントA、テナントB、テナントC、テナントDのユーザによって利用されるクライアントシステム101と通信を行って各種サービス(例えば、ウェブサービス)を提供する。クライアントシステム101は、テナントごとに設置される。なお、テナントの数は4つに限らず、2つでも、3つでも、5つ以上でも構わない。本実施の形態では、さらに、既存アプリケーション500が、システム管理者によって利用されるクライアントシステム102と通信を行って保守管理用のサービスを提供する。   The existing application 500 is an example of an application shared by a plurality of tenants. It is assumed that at least one user belongs to each tenant. In the present embodiment, the existing application 500 provides various services (for example, web services) by communicating with the client system 101 used by users of the tenant A, tenant B, tenant C, and tenant D. The client system 101 is installed for each tenant. The number of tenants is not limited to four, and may be two, three, or five or more. In this embodiment, the existing application 500 further provides a maintenance management service by communicating with the client system 102 used by the system administrator.

マルチテナント型データベース400は、複数のテナントそれぞれの個別のデータを格納する少なくとも2種類のデータベースの一例である。本実施の形態では、マルチテナント型データベース400が、表共有型データベース410とスキーマ分離型データベース420とインスタンス分離型データベース430との3種類のデータベースを組み合わせて構成されている。即ち、マルチテナント型データベース400は、マルチテナント対応のための構成が互いに異なる3種類のデータベースである。なお、マルチテナント型データベース400は、表共有型データベース410とスキーマ分離型データベース420とインスタンス分離型データベース430とのうち、2種類のデータベースのみで構成されていてもよいし、その他の種類のデータベースを含む4種類以上のデータベースで構成されていてもよい。   The multi-tenant database 400 is an example of at least two types of databases that store individual data of a plurality of tenants. In the present embodiment, the multi-tenant database 400 is configured by combining three types of databases: a table sharing database 410, a schema separation database 420, and an instance separation database 430. That is, the multi-tenant database 400 is three types of databases having different configurations for multi-tenancy. The multi-tenant database 400 may be configured with only two types of databases among the table sharing type database 410, the schema separation type database 420, and the instance separation type database 430, or other types of databases may be used. It may be composed of four or more types of databases.

アクセス制御装置100は、既存アプリケーション500をマルチテナント化するためのマルチテナントアプリケーション基盤200と、マルチテナントアプリケーション(マルチテナントアプリケーション基盤200と既存アプリケーション500との組み合わせ)を運用する上で必要な情報を管理するマルチテナント管理データベース300とを備える。   The access control apparatus 100 manages information necessary for operating a multi-tenant application platform 200 for making the existing application 500 multi-tenant and a multi-tenant application (a combination of the multi-tenant application platform 200 and the existing application 500). A multi-tenant management database 300.

マルチテナントアプリケーション基盤200は、UI(ユーザインタフェース)接続部210、マルチテナント制御部220、コネクション保持部230、DB(データベース)接続部240を備える。   The multi-tenant application platform 200 includes a UI (user interface) connection unit 210, a multi-tenant control unit 220, a connection holding unit 230, and a DB (database) connection unit 240.

UI接続部210は、クライアントシステム101からサービスのリクエストを受け付け、そのクライアントシステム101が設置されたテナントのテナントIDを既存パラメータに埋め込む処理を行う。テナントIDとは、テナントを一意に識別するテナント識別子のことである。既存パラメータとは、既存アプリケーション500に入力されると既存アプリケーション500がマルチテナント型データベース400へのアクセス時に出力するパラメータのことである。   The UI connection unit 210 receives a service request from the client system 101, and performs processing for embedding the tenant ID of the tenant in which the client system 101 is installed in an existing parameter. The tenant ID is a tenant identifier that uniquely identifies a tenant. The existing parameter is a parameter output when the existing application 500 accesses the multi-tenant database 400 when input to the existing application 500.

マルチテナント制御部220は、テナントの登録・削除等のテナントの管理を行う。   The multi-tenant control unit 220 manages tenants such as tenant registration / deletion.

コネクション保持部230は、マルチテナントアプリケーションからマルチテナント型データベース400へのアクセス時のコネクションを管理する。   The connection holding unit 230 manages a connection when accessing the multi-tenant database 400 from the multi-tenant application.

DB接続部240は、マルチテナントアプリケーションからマルチテナント型データベース400へのアクセスを制御する。DB接続部240は、テナント分離部241、モデル切替部242、表共有型接続部243、スキーマ分離型接続部244、インスタンス分離型接続部245を有する。テナント分離部241は、既存パラメータからテナントIDを取得する。モデル切替部242は、テナントごとにアクセスするデータベースを切り替える。表共有型接続部243は、表共有型データベース410へのアクセスを実現する。スキーマ分離型接続部244は、スキーマ分離型データベース420へのアクセスを実現する。インスタンス分離型接続部245は、インスタンス分離型データベース430へのアクセスを実現する。   The DB connection unit 240 controls access from the multi-tenant application to the multi-tenant database 400. The DB connection unit 240 includes a tenant separation unit 241, a model switching unit 242, a table sharing type connection unit 243, a schema separation type connection unit 244, and an instance separation type connection unit 245. The tenant separation unit 241 acquires the tenant ID from the existing parameters. The model switching unit 242 switches the database to be accessed for each tenant. The table sharing type connection unit 243 realizes access to the table sharing type database 410. The schema separation type connection unit 244 realizes access to the schema separation type database 420. The instance separation type connection unit 245 realizes access to the instance separation type database 430.

マルチテナント管理データベース300は、テナント管理テーブル310、テナント情報結合設定テーブル320、データベース接続設定テーブル330を有する。テナント管理テーブル310は、マルチテナントアプリケーションを利用するテナントの情報を管理する。テナント情報結合設定テーブル320は、テナントIDを既存アプリケーション500に受け渡す際のルールを管理する。データベース接続設定テーブル330は、テナントごとのデータベースへの接続情報を管理する。   The multi-tenant management database 300 includes a tenant management table 310, a tenant information combination setting table 320, and a database connection setting table 330. The tenant management table 310 manages information on tenants that use the multi-tenant application. The tenant information combination setting table 320 manages rules for transferring the tenant ID to the existing application 500. The database connection setting table 330 manages connection information to the database for each tenant.

図1には示していないが、アクセス制御装置100は、処理装置、記憶装置、入力装置、出力装置等のハードウェアを備える。ハードウェアはアクセス制御装置100の各部によって利用される。例えば、処理装置は、アクセス制御装置100の各部でデータや情報の演算、加工、読み取り、書き込み等を行うために利用される。記憶装置は、そのデータや情報を記憶するために利用される。また、入力装置は、そのデータや情報を入力するために、出力装置は、そのデータや情報を出力するために利用される。   Although not shown in FIG. 1, the access control device 100 includes hardware such as a processing device, a storage device, an input device, and an output device. Hardware is used by each unit of the access control apparatus 100. For example, the processing device is used to perform calculation, processing, reading, writing, and the like of data and information in each unit of the access control device 100. The storage device is used to store the data and information. The input device is used for inputting the data and information, and the output device is used for outputting the data and information.

図2は、アクセス制御装置100のハードウェア構成の一例を示す図である。   FIG. 2 is a diagram illustrating an example of a hardware configuration of the access control apparatus 100.

図2において、アクセス制御装置100は、コンピュータであり、LCD901(Liquid・Crystal・Display)、キーボード902(K/B)、マウス903、FDD904(Flexible・Disk・Drive)、CDD905(Compact・Disc・Drive)、プリンタ906といったハードウェアデバイスを備えている。これらのハードウェアデバイスはケーブルや信号線で接続されている。LCD901の代わりに、CRT(Cathode・Ray・Tube)、あるいは、その他の表示装置が用いられてもよい。マウス903の代わりに、タッチパネル、タッチパッド、トラックボール、ペンタブレット、あるいは、その他のポインティングデバイスが用いられてもよい。   In FIG. 2, an access control apparatus 100 is a computer, and includes an LCD 901 (Liquid / Crystal / Display), a keyboard 902 (K / B), a mouse 903, an FDD 904 (Flexible / Disk / Drive), and a CDD 905 (Compact / Disc / Drive). ) And a hardware device such as a printer 906. These hardware devices are connected by cables and signal lines. Instead of the LCD 901, a CRT (Cathode / Ray / Tube) or other display device may be used. Instead of the mouse 903, a touch panel, a touch pad, a trackball, a pen tablet, or other pointing devices may be used.

アクセス制御装置100は、プログラムを実行するCPU911(Central・Processing・Unit)を備えている。CPU911は、処理装置の一例である。CPU911は、バス912を介してROM913(Read・Only・Memory)、RAM914(Random・Access・Memory)、通信ボード915、LCD901、キーボード902、マウス903、FDD904、CDD905、プリンタ906、HDD920(Hard・Disk・Drive)と接続され、これらのハードウェアデバイスを制御する。HDD920の代わりに、フラッシュメモリ、光ディスク装置、メモリカードリーダライタ、あるいは、その他の記録媒体が用いられてもよい。   The access control apparatus 100 includes a CPU 911 (Central Processing Unit) that executes a program. The CPU 911 is an example of a processing device. The CPU 911 includes a ROM 913 (Read / Only / Memory), a RAM 914 (Random / Access / Memory), a communication board 915, an LCD 901, a keyboard 902, a mouse 903, an FDD 904, a CDD 905, a printer 906, and an HDD 920 (Hard / Disk) via a bus 912. Connected with Drive) to control these hardware devices. Instead of the HDD 920, a flash memory, an optical disk device, a memory card reader / writer, or other recording medium may be used.

RAM914は、揮発性メモリの一例である。ROM913、FDD904、CDD905、HDD920は、不揮発性メモリの一例である。これらは、記憶装置の一例である。通信ボード915、キーボード902、マウス903、FDD904、CDD905は、入力装置の一例である。また、通信ボード915、LCD901、プリンタ906は、出力装置の一例である。   The RAM 914 is an example of a volatile memory. The ROM 913, the FDD 904, the CDD 905, and the HDD 920 are examples of nonvolatile memories. These are examples of the storage device. The communication board 915, the keyboard 902, the mouse 903, the FDD 904, and the CDD 905 are examples of input devices. The communication board 915, the LCD 901, and the printer 906 are examples of output devices.

通信ボード915は、LAN(Local・Area・Network)等に接続されている。通信ボード915は、LANに限らず、IP−VPN(Internet・Protocol・Virtual・Private・Network)、広域LAN、ATM(Asynchronous・Transfer・Mode)ネットワークといったWAN(Wide・Area・Network)、あるいは、インターネットに接続されていても構わない。LAN、WAN、インターネットは、ネットワークの一例である。   The communication board 915 is connected to a LAN (Local / Area / Network) or the like. The communication board 915 is not limited to a LAN, but is an IP-VPN (Internet, Protocol, Private, Network), a wide area LAN, an ATM (Asynchronous / Transfer / Mode) network, a WAN (Wide / Area / Network), or the Internet. It does not matter if it is connected to. LAN, WAN, and the Internet are examples of networks.

HDD920には、オペレーティングシステム921(OS)、ウィンドウシステム922、プログラム群923、ファイル群924が記憶されている。プログラム群923のプログラムは、CPU911、オペレーティングシステム921、ウィンドウシステム922により実行される。プログラム群923には、本実施の形態の説明において「〜部」として説明する機能を実行するプログラムが含まれている。プログラムは、CPU911により読み出され実行される。ファイル群924には、本実施の形態の説明において、「〜データ」、「〜情報」、「〜ID(識別子)」、「〜フラグ」、「〜結果」として説明するデータや情報や信号値や変数値やパラメータが、「〜ファイル」や「〜データベース」や「〜テーブル」の各項目として含まれている。「〜ファイル」や「〜データベース」や「〜テーブル」は、RAM914やHDD920等の記録媒体に記憶される。RAM914やHDD920等の記録媒体に記憶されたデータや情報や信号値や変数値やパラメータは、読み書き回路を介してCPU911によりメインメモリやキャッシュメモリに読み出され、抽出、検索、参照、比較、演算、計算、制御、出力、印刷、表示といったCPU911の処理(動作)に用いられる。抽出、検索、参照、比較、演算、計算、制御、出力、印刷、表示といったCPU911の処理中、データや情報や信号値や変数値やパラメータは、メインメモリやキャッシュメモリやバッファメモリに一時的に記憶される。   The HDD 920 stores an operating system 921 (OS), a window system 922, a program group 923, and a file group 924. The programs in the program group 923 are executed by the CPU 911, the operating system 921, and the window system 922. The program group 923 includes programs that execute the functions described as “˜units” in the description of the present embodiment. The program is read and executed by the CPU 911. The file group 924 includes data, information, and signal values described as “˜data”, “˜information”, “˜ID (identifier)”, “˜flag”, and “˜result” in the description of this embodiment. And variable values and parameters are included as items of “˜file”, “˜database”, and “˜table”. The “˜file”, “˜database”, and “˜table” are stored in a recording medium such as the RAM 914 or the HDD 920. Data, information, signal values, variable values, and parameters stored in a recording medium such as the RAM 914 and the HDD 920 are read out to the main memory and the cache memory by the CPU 911 via a read / write circuit, and extracted, searched, referenced, compared, and calculated. It is used for processing (operation) of the CPU 911 such as calculation, control, output, printing, and display. During the processing of the CPU 911 such as extraction, search, reference, comparison, calculation, calculation, control, output, printing, and display, data, information, signal values, variable values, and parameters are temporarily stored in the main memory, cache memory, and buffer memory. Remembered.

本実施の形態の説明において用いるブロック図やフローチャートの矢印の部分は主としてデータや信号の入出力を示す。データや信号は、RAM914等のメモリ、FDD904のフレキシブルディスク(FD)、CDD905のコンパクトディスク(CD)、HDD920の磁気ディスク、光ディスク、DVD(Digital・Versatile・Disc)、あるいは、その他の記録媒体に記録される。また、データや信号は、バス912、信号線、ケーブル、あるいは、その他の伝送媒体により伝送される。   The arrows in the block diagrams and flowcharts used in the description of this embodiment mainly indicate input / output of data and signals. Data and signals are recorded in memory such as RAM 914, FDD904 flexible disk (FD), CDD905 compact disk (CD), HDD920 magnetic disk, optical disk, DVD (Digital Versatile Disc), or other recording media Is done. Data and signals are transmitted by a bus 912, a signal line, a cable, or other transmission media.

本実施の形態の説明において「〜部」として説明するものは、「〜回路」、「〜装置」、「〜機器」であってもよく、また、「〜ステップ」、「〜工程」、「〜手順」、「〜処理」であってもよい。即ち、「〜部」として説明するものは、ROM913に記憶されたファームウェアで実現されていても構わない。あるいは、「〜部」として説明するものは、ソフトウェアのみ、あるいは、素子、デバイス、基板、配線といったハードウェアのみで実現されていても構わない。あるいは、「〜部」として説明するものは、ソフトウェアとハードウェアとの組み合わせ、あるいは、ソフトウェアとハードウェアとファームウェアとの組み合わせで実現されていても構わない。ファームウェアとソフトウェアは、プログラムとして、フレキシブルディスク、コンパクトディスク、磁気ディスク、光ディスク、DVD等の記録媒体に記憶される。プログラムはCPU911により読み出され、CPU911により実行される。即ち、プログラムは、本実施の形態の説明で述べる「〜部」としてコンピュータを機能させるものである。あるいは、プログラムは、本実施の形態の説明で述べる「〜部」の手順や方法をコンピュータに実行させるものである。   In the description of the present embodiment, what is described as “to part” may be “to circuit”, “to device”, “to device”, and “to step”, “to process”, “to”. ~ Procedure "," ~ process ". That is, what is described as “˜unit” may be realized by firmware stored in the ROM 913. Alternatively, what is described as “˜unit” may be realized only by software, or only by hardware such as an element, a device, a board, and wiring. Alternatively, what is described as “to part” may be realized by a combination of software and hardware, or a combination of software, hardware and firmware. Firmware and software are stored as programs in a recording medium such as a flexible disk, a compact disk, a magnetic disk, an optical disk, and a DVD. The program is read by the CPU 911 and executed by the CPU 911. That is, the program causes the computer to function as “to part” described in the description of the present embodiment. Or a program makes a computer perform the procedure and method of "-part" described by description of this Embodiment.

図3は、マルチテナント管理データベース300のテナント管理テーブル310、テナント情報結合設定テーブル320、データベース接続設定テーブル330の構成例を示す図である。   FIG. 3 is a diagram illustrating a configuration example of the tenant management table 310, the tenant information combination setting table 320, and the database connection setting table 330 of the multi-tenant management database 300.

図3において、テナント管理テーブル310は、テナントID、テナント名のカラムを含む。テナント管理テーブル310は、例えば、テナントID「A」に対応付けて、テナント名「テナントA」を格納している。   In FIG. 3, the tenant management table 310 includes columns of tenant ID and tenant name. For example, the tenant management table 310 stores the tenant name “tenant A” in association with the tenant ID “A”.

テナント情報結合設定テーブル320は、結合元パラメータ、結合先パラメータ、セパレータのカラムを含む。結合先パラメータは、UI接続部210によりテナントIDを埋め込む対象とする既存パラメータを示す。結合元パラメータ及びセパレータは、テナントIDを埋め込んだ後の既存パラメータの形式を示す。本例において、テナント情報結合設定テーブル320は、結合元パラメータ「ユーザID、テナントID」、結合先パラメータ「ユーザID」、セパレータ「−−」を格納している。ユーザIDは、ユーザを一意に識別するユーザ識別子である。例えば、テナントAのユーザがユーザID「USER01」を既存アプリケーション500に入力しようとすると、ユーザIDがUI接続部210により「A−−USER01」に変換されてから既存アプリケーション500に入力されることになる。なお、結合先パラメータとしては、ユーザIDに限らず、ユーザ名、サービスの受付番号、後述する組織ID等、別の既存パラメータを用いても構わない。結合元パラメータ、セパレータについても、上記したものは一例であって、種々の変更が可能である。   The tenant information combination setting table 320 includes a combination source parameter, a combination destination parameter, and a separator column. The combination destination parameter indicates an existing parameter that is a target for embedding the tenant ID by the UI connection unit 210. The combination source parameter and the separator indicate the format of the existing parameter after the tenant ID is embedded. In this example, the tenant information combination setting table 320 stores a combination source parameter “user ID, tenant ID”, a combination destination parameter “user ID”, and a separator “-”. The user ID is a user identifier that uniquely identifies the user. For example, when the user of the tenant A tries to input the user ID “USER01” to the existing application 500, the user ID is converted to “A--USER01” by the UI connection unit 210 and then input to the existing application 500. Become. Note that, as a combination destination parameter, not only the user ID but also other existing parameters such as a user name, a service reception number, and an organization ID described later may be used. Regarding the coupling source parameter and the separator, the above-described ones are merely examples, and various changes can be made.

データベース接続設定テーブル330は、テナントID、接続先DBモデル、プールID、DBチェック情報のカラムを含む。接続先DBモデルは、テナントのアクセス対象として決められたデータベースの種類を示す。プールIDは、データベースのコネクションプール(データベースとの接続)を一意に識別する接続識別子を示す。接続先DBモデルが表共有型データベース410の場合、コネクションプールは各テナントに共通のものが割り当てられる。接続先DBモデルがスキーマ分離型データベース420又はインスタンス分離型データベース430の場合、コネクションプールは各テナントに個別のものが割り当てられる。DBチェック情報は、特定のテーブルに格納されるデータについて設定された条件を示す。この条件は、接続先DBモデルが表共有型データベース410の場合のみ設定される。なお、DBチェック情報は、本実施の形態では使用しないものとする。データベース接続設定テーブル330は、例えば、テナントID「A」に対応付けて、接続先DBモデル「表共有型」(表共有型データベース410を示す)、プールID「poolCommon」(共通のコネクションプールを示す)を格納している。   The database connection setting table 330 includes columns of tenant ID, connection destination DB model, pool ID, and DB check information. The connection destination DB model indicates the type of database determined as the access target of the tenant. The pool ID indicates a connection identifier for uniquely identifying a database connection pool (connection with a database). When the connection destination DB model is the table sharing database 410, a common connection pool is assigned to each tenant. When the connection destination DB model is the schema separation type database 420 or the instance separation type database 430, a separate connection pool is assigned to each tenant. The DB check information indicates conditions set for data stored in a specific table. This condition is set only when the connection destination DB model is the table sharing database 410. The DB check information is not used in the present embodiment. The database connection setting table 330 is associated with the tenant ID “A”, for example, the connection destination DB model “table shared type” (showing the table shared type database 410), and pool ID “poolCommon” (showing a common connection pool). ) Is stored.

上記のように、本実施の形態において、マルチテナント管理データベース300は、テナントごとに、少なくともテナントIDとデータベースの種類(接続先DBモデルやプールIDによって示される)とを記憶装置により予め記憶する。   As described above, in the present embodiment, the multi-tenant management database 300 stores at least a tenant ID and a database type (indicated by a connection destination DB model and a pool ID) in advance by a storage device for each tenant.

図4は、表共有型データベース410の構成例を示す図である。   FIG. 4 is a diagram illustrating a configuration example of the table sharing database 410.

図4において、表共有型データベース410は、複数のテナントそれぞれの個別のデータを、テナントIDのカラムを含む共通のテーブルに格納することによりマルチテナント対応を行う第1種類のデータベースの一例である。表共有型データベース410は、各テナントに共通のテーブルとして、個人情報テーブル(ユーザ一覧)、組織情報テーブル(組織一覧)、配属情報テーブル(配属一覧)、認証情報テーブル(パスワード一覧)を有する。   In FIG. 4, the table sharing database 410 is an example of a first type database that performs multi-tenant correspondence by storing individual data of a plurality of tenants in a common table including a column of tenant IDs. The table sharing database 410 includes a personal information table (user list), an organization information table (organization list), an assignment information table (assignment list), and an authentication information table (password list) as tables common to the tenants.

個人情報テーブル(ユーザ一覧)は、テナントID、ユーザID、ユーザ名のカラムを含む。本例では、ユーザIDが(シングルテナントアプリケーションのように)全テナント間でユーザを一意に識別するものとするが、ユーザが属するテナント内のみでユーザを一意に識別できればよい。個人情報テーブル(ユーザ一覧)は、例えば、テナントID「A」に対応付けて、ユーザID「USER01」、ユーザ名「ユーザ1」を格納している。   The personal information table (user list) includes columns of tenant ID, user ID, and user name. In this example, the user ID uniquely identifies the user among all tenants (as in a single tenant application), but it is sufficient that the user can be uniquely identified only within the tenant to which the user belongs. For example, the personal information table (user list) stores a user ID “USER01” and a user name “user 1” in association with the tenant ID “A”.

組織情報テーブル(組織一覧)は、テナントID、組織ID、組織名のカラムを含む。組織IDは、テナントの組織(部署等)を一意に識別する組織識別子である。組織情報テーブル(組織一覧)は、例えば、テナントID「A」に対応付けて、組織ID「ORG1」、組織名「組織1」を格納している。   The organization information table (organization list) includes columns of tenant ID, organization ID, and organization name. The organization ID is an organization identifier that uniquely identifies a tenant's organization (department or the like). The organization information table (organization list) stores, for example, the organization ID “ORG1” and the organization name “organization 1” in association with the tenant ID “A”.

配属情報テーブル(配属一覧)は、テナントID、配属ID、ユーザID、組織IDのカラムを含む。配属IDは、ユーザと組織との対応付け(即ち、配属)を一意に識別する配属識別子である。配属情報テーブル(配属一覧)は、例えば、テナントID「A」に対応付けて、配属ID「1」、ユーザID「USER01」、組織ID「ORG1」を格納している。   The assignment information table (assignment list) includes columns of tenant ID, assignment ID, user ID, and organization ID. The assignment ID is an assignment identifier that uniquely identifies the association (that is, assignment) between the user and the organization. The assignment information table (assignment list) stores, for example, an assignment ID “1”, a user ID “USER01”, and an organization ID “ORG1” in association with the tenant ID “A”.

認証情報テーブル(パスワード一覧)は、テナントID、ユーザID、パスワードのカラムを含む。認証情報テーブル(パスワード一覧)は、例えば、テナントID「A」に対応付けて、ユーザID「USER01」、パスワード「xxxxxxxx」を格納している。   The authentication information table (password list) includes tenant ID, user ID, and password columns. The authentication information table (password list) stores, for example, a user ID “USER01” and a password “xxxxxxxx” in association with the tenant ID “A”.

図5は、スキーマ分離型データベース420の構成例を示す図である。   FIG. 5 is a diagram illustrating a configuration example of the schema separation type database 420.

図5において、スキーマ分離型データベース420は、テナントごとに、テナントの個別のデータを個別のテーブルに格納することによりマルチテナント対応を行う第2種類のデータベースの一例である。スキーマ分離型データベース420は、各テナントの個別のテーブルとして、個人情報テーブル(テナントA_ユーザ一覧、テナントB_ユーザ一覧)、組織情報テーブル(テナントA_組織一覧、テナントB_組織一覧)、配属情報テーブル(テナントA_配属一覧、テナントB_配属一覧)を有する。図示していないが、スキーマ分離型データベース420は、認証情報テーブル(テナントA_パスワード一覧、テナントB_パスワード一覧)も有する。   In FIG. 5, the schema separation type database 420 is an example of a second type database that performs multi-tenant correspondence by storing individual tenant data in individual tables for each tenant. The schema separation type database 420 includes a personal information table (tenant A_user list, tenant B_user list), an organization information table (tenant A_organization list, tenant B_organization list), and an assignment information table (tenant) as individual tables for each tenant. A_assignment list, tenant B_assignment list). Although not shown, the schema separation type database 420 also has an authentication information table (tenant A_password list, tenant B_password list).

個人情報テーブル(テナントA_ユーザ一覧、テナントB_ユーザ一覧)、組織情報テーブル(テナントA_組織一覧、テナントB_組織一覧)、配属情報テーブル(テナントA_配属一覧、テナントB_配属一覧)、認証情報テーブル(テナントA_パスワード一覧、テナントB_パスワード一覧)の各テーブルは、テナントIDのカラムを含む代わりに、テーブル名にテナント名(テナントIDでもよい)を含んでいる。各テーブルに含まれるカラムについては、図4に示した表共有型データベース410のものと同様である。   Personal information table (tenant A_user list, tenant B_user list), organization information table (tenant A_organization list, tenant B_organization list), assignment information table (tenant A_assignment list, tenant B_assignment list), authentication information table (tenant) Each table of (A_password list, tenant B_password list) includes a tenant name (may be a tenant ID) in the table name instead of including a tenant ID column. The columns included in each table are the same as those in the table sharing database 410 shown in FIG.

図6は、インスタンス分離型データベース430の構成例を示す図である。   FIG. 6 is a diagram illustrating a configuration example of the instance separation type database 430.

図6において、インスタンス分離型データベース430は、テナントごとに、テナントの個別のデータを格納する個別のデータベースインスタンスが存在することによりマルチテナント対応を行う第3種類のデータベースの一例である。インスタンス分離型データベース430のテナントA用インスタンス及びテナントB用インスタンスは、それぞれ個人情報テーブル(ユーザ一覧)、組織情報テーブル(組織一覧)、配属情報テーブル(配属一覧)を有する。図示していないが、テナントA用インスタンス及びテナントB用インスタンスは、それぞれ認証情報テーブル(パスワード一覧)も有する。   In FIG. 6, the instance separation type database 430 is an example of a third type database that performs multi-tenant correspondence because there is an individual database instance that stores individual data of each tenant for each tenant. The tenant A instance and the tenant B instance of the instance separation type database 430 have a personal information table (user list), an organization information table (organization list), and an assignment information table (assignment list), respectively. Although not shown, each of the tenant A instance and the tenant B instance also has an authentication information table (password list).

個人情報テーブル(ユーザ一覧)、組織情報テーブル(組織一覧)、配属情報テーブル(配属一覧)、認証情報テーブル(パスワード一覧)の各テーブルは、テナントIDのカラムを含んだり、テーブル名にテナント名を含んだりする代わりに、テナントごとにデータベースインスタンスが分かれている。各テーブルに含まれるカラムについては、図4に示した表共有型データベース410のものと同様である。   Each table of personal information table (user list), organization information table (organization list), assignment information table (assignment list), and authentication information table (password list) includes a column of tenant ID, or a tenant name in the table name. Instead of including, database instance is divided for each tenant. The columns included in each table are the same as those in the table sharing database 410 shown in FIG.

以下では、図7〜図9を用いて、テナントAのクライアントシステム101からサービスのリクエストが送信されたときのアクセス制御装置100の動作(本実施の形態に係るアクセス制御方法、本実施の形態に係るプログラムの処理手順)について説明する。   Hereinafter, the operation of the access control apparatus 100 when a service request is transmitted from the client system 101 of the tenant A (the access control method according to the present embodiment, the present embodiment will be described with reference to FIGS. 7 to 9). The processing procedure of the program will be described.

図7は、既存アプリケーション500にテナントIDを意識させずに既存アプリケーション500を利用するために、既存パラメータに対するテナントIDの結合及び分離を行う流れを示すシーケンス図である。   FIG. 7 is a sequence diagram showing a flow of combining and separating tenant IDs with respect to existing parameters in order to use the existing application 500 without making the existing application 500 aware of the tenant ID.

S101において、テナントAのクライアントシステム101は、UI接続部210に対し、ログイン要求を出す。このとき、クライアントシステム101は、UI接続部210に対し、テナントID、ユーザID、パスワードを送信するものとする。UI接続部210は、テナントID、ユーザID、パスワードを入力装置により受信する。   In S <b> 101, the client system 101 of the tenant A issues a login request to the UI connection unit 210. At this time, the client system 101 transmits a tenant ID, a user ID, and a password to the UI connection unit 210. The UI connection unit 210 receives the tenant ID, user ID, and password by the input device.

S102において、UI接続部210は、受信したテナントIDが正しいものか、及び、テナントIDをどのように既存パラメータに埋め込むのか(結合ルール)に関する情報を入手するために、マルチテナント制御部220にテナントID確認通知とテナント情報結合情報取得要求を出す。   In S102, the UI connection unit 210 sends the tenant ID to the multi-tenant control unit 220 in order to obtain information on whether the received tenant ID is correct and how the tenant ID is embedded in the existing parameter (combination rule). An ID confirmation notification and a tenant information combination information acquisition request are issued.

S103において、マルチテナント制御部220は、マルチテナント管理データベース300に対し、テナント管理テーブル310にUI接続部210から受け取ったテナントIDが含まれているかどうか問い合わせる。また、テナント情報結合設定テーブル320の結合ルールを問い合わせる。   In S103, the multi-tenant control unit 220 inquires of the multi-tenant management database 300 whether the tenant ID received from the UI connection unit 210 is included in the tenant management table 310. Also inquires about the combination rule of the tenant information combination setting table 320.

S104において、マルチテナント管理データベース300は、マルチテナント制御部220の問い合わせに対し、テナント管理テーブル310、テナント情報結合設定テーブル320を検索し、結果を返す。   In S104, the multi-tenant management database 300 searches the tenant management table 310 and the tenant information combination setting table 320 in response to the inquiry from the multi-tenant control unit 220, and returns the result.

S105において、マルチテナント制御部220は、UI接続部210に対し、検索結果を返す。   In S <b> 105, the multi-tenant control unit 220 returns a search result to the UI connection unit 210.

S106において、UI接続部210は、マルチテナント制御部220経由で取得した結合ルールを基に、既存パラメータに対し、テナントIDを処理装置により埋め込む。本例では、図3に示したように、結合ルールとして、結合元パラメータ「ユーザID、テナントID」、結合先パラメータ「ユーザID」、セパレータ「−−」が設定されているものとする。そのため、テナントIDが「A」、ユーザIDが「USER01」のユーザの場合、既存パラメータのユーザIDは「A−−USER01」となる。テナントIDを埋め込んだ後に、UI接続部210は、既存アプリケーション500に対し、ユーザIDを「A−−USER01」とした上でリクエストを送信する。   In S <b> 106, the UI connection unit 210 embeds a tenant ID in the existing parameter by the processing device based on the combination rule acquired via the multi-tenant control unit 220. In this example, as illustrated in FIG. 3, it is assumed that a combination source parameter “user ID, tenant ID”, a combination destination parameter “user ID”, and a separator “-” are set as a combination rule. Therefore, when the tenant ID is “A” and the user ID is “USER01”, the existing parameter user ID is “A--USER01”. After embedding the tenant ID, the UI connection unit 210 transmits a request to the existing application 500 with the user ID set to “A--USER01”.

S107において、既存アプリケーション500は、シングルテナントの場合と同様の処理を実施する。具体的には、既存アプリケーション500は、マルチテナント型データベース400に対するクエリ(第1のクエリ)を発行する。   In S107, the existing application 500 performs the same processing as in the case of a single tenant. Specifically, the existing application 500 issues a query (first query) to the multi-tenant database 400.

S108において、既存アプリケーション500は、DB接続部240のテナント分離部241に対してデータベース接続要求を出す。データベース接続要求には、パラメータとしてユーザIDが含まれている。   In S <b> 108, the existing application 500 issues a database connection request to the tenant separation unit 241 of the DB connection unit 240. The database connection request includes a user ID as a parameter.

S109において、テナント分離部241は、既存アプリケーション500から受け取ったデータベース接続要求のパラメータからテナントIDを抽出するための情報を取得するために、マルチテナント制御部220に対し、テナント情報結合情報取得要求を出す。   In S109, the tenant separation unit 241 sends a tenant information combination information acquisition request to the multi-tenant control unit 220 in order to acquire information for extracting the tenant ID from the parameters of the database connection request received from the existing application 500. put out.

S110において、マルチテナント制御部220は、テナント分離部241から受け取ったテナント情報結合情報取得要求を基に、マルチテナント管理データベース300に対して、結合ルールを問い合わせる。   In S110, the multi-tenant control unit 220 inquires of the multi-tenant management database 300 about a combination rule based on the tenant information combination information acquisition request received from the tenant separation unit 241.

S111において、マルチテナント管理データベース300は、マルチテナント制御部220の問い合わせに対し、テナント情報結合設定テーブル320を検索し、結果を返す。   In S111, the multi-tenant management database 300 searches the tenant information combination setting table 320 in response to the inquiry from the multi-tenant control unit 220, and returns the result.

S112において、マルチテナント制御部220は、テナント分離部241に対し、検索結果を返す。   In S112, the multi-tenant control unit 220 returns a search result to the tenant separation unit 241.

S113において、テナント分離部241は、結合ルールを基に、既存パラメータからテナントIDを処理装置により取得する。本例では、ユーザIDからテナントIDを取得する。   In S113, the tenant separation unit 241 acquires the tenant ID from the existing parameters by the processing device based on the combination rule. In this example, the tenant ID is acquired from the user ID.

S114において、テナント分離部241は、DB接続部240のモデル切替部242に対し、既存アプリケーション500から受け取ったデータベース接続要求を、テナントIDを付与した状態で渡す。モデル切替部242は、データベース接続要求を受け取る。   In S114, the tenant separation unit 241 passes the database connection request received from the existing application 500 to the model switching unit 242 of the DB connection unit 240 with the tenant ID assigned. The model switching unit 242 receives a database connection request.

上記のように、本実施の形態において、UI接続部210は、既存パラメータの入力を、複数のテナントのいずれかに属するユーザから入力装置により受け付ける。UI接続部210は、当該ユーザが属するテナントのテナントIDをマルチテナント管理データベース300から読み出して、当該ユーザから入力された既存パラメータに処理装置により埋め込む。そして、UI接続部210は、テナントIDを埋め込んだ既存パラメータを既存アプリケーション500に入力する。本例において、UI接続部210は、当該ユーザから、既存パラメータとして、当該ユーザのユーザIDの入力を受け付け、当該ユーザが属するテナントのテナントIDを、当該ユーザから入力されたユーザIDに連結することにより、テナントIDを既存パラメータに埋め込む。   As described above, in the present embodiment, the UI connection unit 210 receives an input of an existing parameter from a user belonging to one of a plurality of tenants using an input device. The UI connection unit 210 reads the tenant ID of the tenant to which the user belongs from the multi-tenant management database 300 and embeds the tenant ID in the existing parameter input by the user by the processing device. Then, the UI connection unit 210 inputs the existing parameter in which the tenant ID is embedded into the existing application 500. In this example, the UI connection unit 210 receives an input of the user ID of the user as an existing parameter from the user, and connects the tenant ID of the tenant to which the user belongs to the user ID input by the user. Thus, the tenant ID is embedded in the existing parameter.

また、本実施の形態において、DB接続部240は、UI接続部210により入力された既存パラメータが既存アプリケーション500から出力された場合、出力された既存パラメータに埋め込まれているテナントIDを処理装置により取り出す。   Further, in this embodiment, when the existing parameter input by the UI connection unit 210 is output from the existing application 500, the DB connection unit 240 uses the processing device to input the tenant ID embedded in the output existing parameter. Take out.

図8は、表共有型データベース410へのアクセスの流れを示すシーケンス図である。   FIG. 8 is a sequence diagram showing a flow of access to the table sharing database 410.

S201において、モデル切替部242は、受け取ったデータベース接続要求からテナントIDを取得し、どのようにデータベースへアクセスするのかに関する情報を取得するため、取得したテナントIDをマルチテナント制御部220に通知する。   In S201, the model switching unit 242 acquires the tenant ID from the received database connection request and notifies the multi-tenant control unit 220 of the acquired tenant ID in order to acquire information on how to access the database.

S202において、マルチテナント制御部220は、通知されたテナントIDのテナントがどのようにデータベースにアクセスするのかをマルチテナント管理データベース300に対して問い合わせる。   In S202, the multi-tenant control unit 220 inquires of the multi-tenant management database 300 how the tenant with the notified tenant ID accesses the database.

S203において、マルチテナント管理データベース300は、マルチテナント制御部220の問い合わせに対し、データベース接続設定テーブル330を検索し、結果を返す。この結果には、プールIDが含まれている。   In S203, the multi-tenant management database 300 searches the database connection setting table 330 in response to the inquiry from the multi-tenant control unit 220, and returns the result. This result includes the pool ID.

S204において、マルチテナント制御部220は、マルチテナント管理データベース300より取得したプールIDを基に、コネクション保持部230に対し、コネクションプールの取得を要求する。このとき、マルチテナント制御部220は、コネクション保持部230に対し、プールIDを送信するものとする。   In S204, the multi-tenant control unit 220 requests the connection holding unit 230 to acquire a connection pool based on the pool ID acquired from the multi-tenant management database 300. At this time, the multi-tenant control unit 220 transmits the pool ID to the connection holding unit 230.

S205において、コネクション保持部230は、受け取ったプールIDのコネクションプールを返す。   In S205, the connection holding unit 230 returns the connection pool of the received pool ID.

S206において、マルチテナント制御部220は、モデル切替部242より受け取ったテナントIDのテナントが使用するデータベースのコネクションプールをモデル切替部242に返す。   In S206, the multi-tenant control unit 220 returns the connection pool of the database used by the tenant with the tenant ID received from the model switching unit 242 to the model switching unit 242.

S207において、モデル切替部242は、マルチテナント制御部220から受け取ったコネクションプール(接続先情報)を基に、接続先を切り替える。本例では、図3に示したように、テナントAの接続先DBモデルとして、表共有型データベース410が設定されているものとする。そのため、モデル切替部242は、表共有型接続部243に接続する。   In S207, the model switching unit 242 switches the connection destination based on the connection pool (connection destination information) received from the multi-tenant control unit 220. In this example, as shown in FIG. 3, it is assumed that the table sharing database 410 is set as the connection destination DB model of the tenant A. Therefore, the model switching unit 242 connects to the table sharing type connection unit 243.

S208において、表共有型接続部243は、コネクション保持部230より取得したコネクションプールを用いてマルチテナント型データベース400の表共有型データベース410に接続し、検索要求を出す。具体的には、表共有型接続部243は、既存アプリケーション500により発行されたクエリ(例えば、SQLのSELECT文)に、アクセス対象となるテーブルのテナントIDとモデル切替部242が取得したテナントIDとが一致することを条件(例えば、WHERE句)として追加した上で、そのクエリを表共有型データベース410に対して発行する。   In S208, the table sharing type connection unit 243 connects to the table sharing type database 410 of the multi-tenant database 400 using the connection pool acquired from the connection holding unit 230, and issues a search request. Specifically, the table sharing type connection unit 243 adds the tenant ID of the table to be accessed and the tenant ID acquired by the model switching unit 242 to the query issued by the existing application 500 (for example, the SQL SELECT statement). Is added as a condition (for example, a WHERE clause), and the query is issued to the table sharing database 410.

S209において、表共有型データベース410は、検索結果(具体的には、クエリの結果)を表共有型接続部243へ返す。   In S209, the table sharing type database 410 returns the search result (specifically, the result of the query) to the table sharing type connection unit 243.

S210において、表共有型接続部243は、表共有型データベース410から返ってきた検索結果をモデル切替部242へ返す。モデル切替部242は、検索結果を受信する。   In S210, the table sharing type connection unit 243 returns the search result returned from the table sharing type database 410 to the model switching unit 242. The model switching unit 242 receives the search result.

上記のように、本実施の形態において、DB接続部240は、既存アプリケーション500から出力された既存パラメータに埋め込まれているテナントIDを取り出した後、取り出したテナントIDに対応するテナントのデータベースの種類をマルチテナント管理データベース300から読み出す。そして、DB接続部240は、マルチテナント型データベース400を構成する3種類のデータベースのうち、読み出した種類のデータベースに格納された当該テナントの個別のデータへのアクセスを既存アプリケーション500に行わせる。   As described above, in this embodiment, the DB connection unit 240 extracts the tenant ID embedded in the existing parameter output from the existing application 500, and then the type of the tenant database corresponding to the extracted tenant ID. Are read from the multi-tenant management database 300. Then, the DB connection unit 240 causes the existing application 500 to access individual data of the tenant stored in the read type database among the three types of databases constituting the multi-tenant database 400.

図9は、マルチテナント型データベース400の検索結果をクライアントシステム101へ返す処理の流れを示すシーケンス図である。   FIG. 9 is a sequence diagram showing a flow of processing for returning the search result of the multi-tenant database 400 to the client system 101.

S301において、モデル切替部242は、受信したマルチテナント型データベース400の検索結果をテナント分離部241へ渡す。   In S301, the model switching unit 242 passes the received search result of the multi-tenant database 400 to the tenant separation unit 241.

S302において、テナント分離部241は、既存アプリケーション500へモデル切替部242から取得したマルチテナント型データベース400の検索結果を渡す。   In S <b> 302, the tenant separation unit 241 passes the search result of the multi-tenant database 400 acquired from the model switching unit 242 to the existing application 500.

S303において、既存アプリケーション500は、受け取ったマルチテナント型データベース400の検索結果を基に、シングルテナントの場合と同様の処理を実施する。具体的には、既存アプリケーション500は、マルチテナント型データベース400に対するクエリの結果に基づいて、所定の処理(例えば、ウェブサービスのための処理)を実行する。   In S303, the existing application 500 performs the same processing as in the case of a single tenant based on the received search result of the multi-tenant database 400. Specifically, the existing application 500 executes a predetermined process (for example, a process for a web service) based on a query result for the multi-tenant database 400.

S304において、既存アプリケーション500は、処理の実施結果をUI接続部210に返す。   In S <b> 304, the existing application 500 returns the execution result of the processing to the UI connection unit 210.

S305において、UI接続部210は、処理の実施結果をテナントAのクライアントシステム101に返す。   In step S <b> 305, the UI connection unit 210 returns the processing execution result to the client system 101 of the tenant A.

以上説明した動作により、マルチテナントアプリケーションからテナントAのユーザへのサービス提供が行われる。テナントBのクライアントシステム101からサービスのリクエストが送信されたときにも、同様の動作により、マルチテナントアプリケーションからテナントBのユーザへのサービス提供が行われる。   With the operation described above, the service is provided from the multi-tenant application to the user of the tenant A. When a service request is transmitted from the client system 101 of the tenant B, the service is provided from the multi-tenant application to the user of the tenant B by the same operation.

以下では、図10を用いて、テナントCのクライアントシステム101からサービスのリクエストが送信されたときのアクセス制御装置100の動作(本実施の形態に係るアクセス制御方法、本実施の形態に係るプログラムの処理手順)について説明する。   Hereinafter, the operation of the access control apparatus 100 when a service request is transmitted from the client system 101 of the tenant C (the access control method according to the present embodiment, the program according to the present embodiment, and the like) will be described with reference to FIG. Processing procedure) will be described.

既存アプリケーション500にテナントIDを意識させずに既存アプリケーション500を利用するために、既存パラメータに対するテナントIDの結合及び分離を行う流れは、図7に示したものと同様である。   In order to use the existing application 500 without making the existing application 500 aware of the tenant ID, the flow of combining and separating the tenant ID with respect to the existing parameter is the same as that shown in FIG.

図10は、スキーマ分離型データベース420へのアクセスの流れを示すシーケンス図である。   FIG. 10 is a sequence diagram showing a flow of access to the schema separation type database 420.

S401〜S406の処理については、図8に示したS201〜S206の処理と同様である。   The processing of S401 to S406 is the same as the processing of S201 to S206 shown in FIG.

S407において、モデル切替部242は、マルチテナント制御部220から受け取ったコネクションプール(接続先情報)を基に、接続先を切り替える。本例では、図3に示したように、テナントCの接続先DBモデルとして、スキーマ分離型データベース420が設定されているものとする。そのため、モデル切替部242は、スキーマ分離型接続部244に接続する。   In S407, the model switching unit 242 switches the connection destination based on the connection pool (connection destination information) received from the multi-tenant control unit 220. In this example, as shown in FIG. 3, it is assumed that a schema separation type database 420 is set as a connection destination DB model of the tenant C. Therefore, the model switching unit 242 is connected to the schema separation type connection unit 244.

S408において、スキーマ分離型接続部244は、コネクション保持部230より取得したコネクションプールを用いてマルチテナント型データベース400のスキーマ分離型データベース420に接続し、検索要求を出す。具体的には、スキーマ分離型接続部244は、既存アプリケーション500により発行されたクエリ(例えば、SQLのSELECT文)でアクセス対象として指定されたテーブルのテーブル名に、モデル切替部242が取得したテナントIDに対応するテナント名(テナントIDそのものでもよい)を所定の形式で追加(連結)した上で、そのクエリをスキーマ分離型データベース420に対して発行する。   In step S <b> 408, the schema separation type connection unit 244 connects to the schema separation type database 420 of the multi-tenant database 400 using the connection pool acquired from the connection holding unit 230 and issues a search request. Specifically, the schema separation type connection unit 244 displays the tenant acquired by the model switching unit 242 in the table name of the table specified as the access target in the query (for example, the SQL SELECT statement) issued by the existing application 500. After adding (concatenating) a tenant name (may be the tenant ID itself) corresponding to the ID in a predetermined format, the query is issued to the schema separation type database 420.

S209において、スキーマ分離型データベース420は、検索結果(具体的には、クエリの結果)をスキーマ分離型接続部244へ返す。   In S209, the schema separation type database 420 returns the search result (specifically, the result of the query) to the schema separation type connection unit 244.

S210において、スキーマ分離型接続部244は、スキーマ分離型データベース420から返ってきた検索結果をモデル切替部242へ返す。モデル切替部242は、検索結果を受信する。   In S 210, the schema separation type connection unit 244 returns the search result returned from the schema separation type database 420 to the model switching unit 242. The model switching unit 242 receives the search result.

マルチテナント型データベース400の検索結果をクライアントシステム101へ返す処理の流れは、図9に示したものと同様である。   The flow of processing for returning the search result of the multi-tenant database 400 to the client system 101 is the same as that shown in FIG.

以下では、図11を用いて、テナントDのクライアントシステム101からサービスのリクエストが送信されたときのアクセス制御装置100の動作(本実施の形態に係るアクセス制御方法、本実施の形態に係るプログラムの処理手順)について説明する。   Hereinafter, the operation of the access control apparatus 100 when a service request is transmitted from the client system 101 of the tenant D (the access control method according to the present embodiment, the program according to the present embodiment, and the like) will be described with reference to FIG. Processing procedure) will be described.

既存アプリケーション500にテナントIDを意識させずに既存アプリケーション500を利用するために、既存パラメータに対するテナントIDの結合及び分離を行う流れは、図7に示したものと同様である。   In order to use the existing application 500 without making the existing application 500 aware of the tenant ID, the flow of combining and separating the tenant ID with respect to the existing parameter is the same as that shown in FIG.

図11は、インスタンス分離型データベース430へのアクセスの流れを示すシーケンス図である。   FIG. 11 is a sequence diagram showing a flow of access to the instance separation type database 430.

S501〜S506の処理については、図8に示したS201〜S206の処理と同様である。   The processing of S501 to S506 is the same as the processing of S201 to S206 shown in FIG.

S507において、モデル切替部242は、マルチテナント制御部220から受け取ったコネクションプール(接続先情報)を基に、接続先を切り替える。本例では、図3に示したように、テナントDの接続先DBモデルとして、インスタンス分離型データベース430が設定されているものとする。そのため、モデル切替部242は、インスタンス分離型接続部245に接続する。   In S507, the model switching unit 242 switches the connection destination based on the connection pool (connection destination information) received from the multi-tenant control unit 220. In this example, as illustrated in FIG. 3, it is assumed that the instance separation type database 430 is set as the connection destination DB model of the tenant D. Therefore, the model switching unit 242 is connected to the instance separation type connection unit 245.

S508において、インスタンス分離型接続部245は、コネクション保持部230より取得したコネクションプールを用いてマルチテナント型データベース400のインスタンス分離型データベース430に接続し、検索要求を出す。具体的には、インスタンス分離型接続部245は、既存アプリケーション500により発行されたクエリ(例えば、SQLのSELECT文)を、インスタンス分離型データベース430のテナントA用インスタンスに対して発行する。   In S508, the instance separation type connection unit 245 connects to the instance separation type database 430 of the multi-tenant database 400 using the connection pool acquired from the connection holding unit 230, and issues a search request. Specifically, the instance separation type connection unit 245 issues a query (for example, a SQL SELECT statement) issued by the existing application 500 to the instance for the tenant A in the instance separation type database 430.

S509において、インスタンス分離型データベース430は、検索結果(具体的には、クエリの結果)をインスタンス分離型接続部245へ返す。   In S509, the instance separation type database 430 returns the search result (specifically, the result of the query) to the instance separation type connection unit 245.

S510において、インスタンス分離型接続部245は、インスタンス分離型データベース430から返ってきた検索結果をモデル切替部242へ返す。モデル切替部242は、検索結果を受信する。   In S510, the instance separation type connection unit 245 returns the search result returned from the instance separation type database 430 to the model switching unit 242. The model switching unit 242 receives the search result.

マルチテナント型データベース400の検索結果をクライアントシステム101へ返す処理の流れは、図9に示したものと同様である。   The flow of processing for returning the search result of the multi-tenant database 400 to the client system 101 is the same as that shown in FIG.

以上説明したように、本実施の形態では、既存アプリケーション500を可能な限り流用した状態でマルチテナント化するために、既存アプリケーション500の前後のインタフェース部分でテナントID(テナントごとに一意に割り振られる識別子)の埋め込み/取り出しを行う。   As described above, in the present embodiment, in order to make a multi-tenant in a state where the existing application 500 is diverted as much as possible, tenant IDs (identifiers that are uniquely allocated for each tenant) in the interface part before and after the existing application 500 are used. ) Is embedded / removed.

マルチテナント対応でない既存アプリケーション500ではテナントIDを扱うことができない。そこで、既存アプリケーション500で利用しているパラメータ(例えば、ユーザID)にテナントIDを結合する。例えば、結合元パラメータ「ユーザID、テナントID」、結合先パラメータ「ユーザID」、セパレータ「−−」のように設定された結合ルールでテナントIDが「A」、ユーザIDが「USER01」のユーザの場合、既存パラメータのユーザIDは「A−−USER01」となる。このとき結合ルールを固定とするのではなく、柔軟に設定可能とすることで、例えば既存アプリケーション500のユーザIDの文字数に制限がある場合は、ユーザ名のパラメータを結合先にするといったことが可能となる。また、マルチテナント化する既存アプリケーション500が複数あり、既存アプリケーション500の利用しているパラメータが異なる場合でも、既存アプリケーション500ごとにルールを設定することで対応可能となる。   The existing application 500 that does not support multi-tenant cannot handle the tenant ID. Therefore, the tenant ID is combined with the parameter (for example, user ID) used in the existing application 500. For example, a user whose tenant ID is “A” and whose user ID is “USER01” in the combination rule set as a combination source parameter “user ID, tenant ID”, combination destination parameter “user ID”, separator “-” In this case, the user ID of the existing parameter is “A--USER01”. At this time, the combination rule is not fixed, but can be set flexibly. For example, when the number of characters of the user ID of the existing application 500 is limited, the parameter of the user name can be set as the combination destination. It becomes. Further, even when there are a plurality of existing applications 500 to be multi-tenanted and the parameters used by the existing applications 500 are different, it is possible to cope by setting a rule for each existing application 500.

本実施の形態に係るアクセス制御装置100は、マルチテナントアプリケーションを実現するためのソフトウェア及びそれを格納・実行するハードウェアからなり、UI接続部210、DB接続部240、テナント情報結合設定テーブル320を備える。UI接続部210は、ユーザの所属するテナントのテナントIDを、テナント情報結合設定を基に、既存アプリケーション500で使用されているパラメータに埋め込む。DB接続部240は、データベースのアクセスに必要なテナントIDを、テナント情報結合設定を基に、パラメータから取り出す。テナント情報結合設定テーブル320は、テナント情報結合設定として、テナントIDを埋め込むパラメータや、埋め込むための条件を管理する。   The access control apparatus 100 according to the present embodiment includes software for realizing a multi-tenant application and hardware for storing and executing the software, and includes a UI connection unit 210, a DB connection unit 240, and a tenant information combination setting table 320. Prepare. The UI connection unit 210 embeds the tenant ID of the tenant to which the user belongs in the parameter used in the existing application 500 based on the tenant information combination setting. The DB connection unit 240 extracts the tenant ID necessary for accessing the database from the parameters based on the tenant information combination setting. The tenant information combination setting table 320 manages parameters for embedding a tenant ID and conditions for embedding as tenant information combination settings.

従来技術では、既存アプリケーション500を用いてデータベースからデータを読み出す場合、セッション情報からテナントID等を取得していたため、既存アプリケーション500を通したデータとテナントIDとの対応付けがうまくいかない可能性がある。既存アプリケーション500とデータベースとの間でセッションIDを取得できないと、テナントIDを取得することはできない。これに対し、本実施の形態では、UI接続部210からDB接続部240にセッション情報(セッションID)を渡していない状態であっても、既存アプリケーション500がテナントIDを意識する必要なく、DB接続部240にてテナントIDを取得することが可能である。   In the prior art, when data is read from the database using the existing application 500, the tenant ID or the like is acquired from the session information. Therefore, there is a possibility that the association between the data and the tenant ID through the existing application 500 may not be successful. If the session ID cannot be acquired between the existing application 500 and the database, the tenant ID cannot be acquired. On the other hand, in this embodiment, even if the session information (session ID) is not passed from the UI connection unit 210 to the DB connection unit 240, the existing application 500 does not need to be aware of the tenant ID, and the DB connection The tenant ID can be acquired by the unit 240.

また、本実施の形態では、データベースのモデルとして、表共有型、スキーマ分離型、インスタンス分離型が混在しているマルチテナント型データベース400を利用する。   In this embodiment, a multi-tenant database 400 in which a table sharing type, a schema separation type, and an instance separation type are mixed is used as a database model.

複数テナントの情報を持つデータベースのモデルは、データベースの表の構成やインスタンスの構成によって、表共有型、スキーマ分離型、インスタンス分離型に分けられる。既存アプリケーション500をマルチテナント化するにあたって、複数テナントのそれぞれが利用しているデータベースの形式はテナントによって異なる可能性が高く、対応可能なモデルが1つの場合は、データベースを移行する手間がかかってしまう。また、「集約度を上げたい」、「独自のスキーマを使いたい」といった利用者の様々なニーズに合わせてモデルを切り替えるような方式を実現できない。これに対し、本実施の形態では、データベース接続設定テーブル330でテナントごとに利用するデータベースのモデルが何かを管理し、マルチテナント型データベース400へ接続する際にモデルを切り替える。モデルの切替時には、予めテナントごとに利用可能なデータベースへのコネクションを保持するコネクションプールを用意し、マルチテナント型データベース400への接続時にはテナントに割り当てられたコネクションを選択することで、モデルの切替が可能となる。   Database models having information on multiple tenants are classified into a table sharing type, a schema separation type, and an instance separation type depending on the structure of the database table and the structure of the instance. When converting an existing application 500 into a multi-tenant, the format of the database used by each of the multiple tenants is likely to differ depending on the tenant. If there is one model that can be handled, it will take time to migrate the database. . Also, it is not possible to realize a method of switching models according to various needs of users such as “I want to increase the degree of aggregation” and “I want to use a unique schema”. In contrast, in this embodiment, the database connection setting table 330 manages what database model is used for each tenant, and switches the model when connecting to the multi-tenant database 400. When switching models, prepare a connection pool that holds connections to databases that can be used for each tenant in advance. When connecting to the multi-tenant database 400, select the connection assigned to the tenant to switch the model. It becomes possible.

実施の形態2.
本実施の形態について、主に実施の形態1との差異を説明する。
Embodiment 2. FIG.
In the present embodiment, differences from the first embodiment will be mainly described.

本実施の形態に係るアクセス制御装置100の構成は、図1に示した実施の形態1のものと同様である。   The configuration of access control apparatus 100 according to the present embodiment is the same as that of the first embodiment shown in FIG.

以下では、図12を用いて、マルチテナントアプリケーションを利用するテナントを追加する際のアクセス制御装置100の動作(本実施の形態に係るアクセス制御方法、本実施の形態に係るプログラムの処理手順)について説明する。   Hereinafter, with reference to FIG. 12, the operation of the access control apparatus 100 when adding a tenant that uses a multi-tenant application (the access control method according to the present embodiment, the processing procedure of the program according to the present embodiment) explain.

図12は、システム管理者のクライアントシステム102から新規にテナントを追加する処理の流れを示すシーケンス図である。   FIG. 12 is a sequence diagram showing a flow of processing for newly adding a tenant from the client system 102 of the system administrator.

S601において、システム管理者のクライアントシステム102は、マルチテナント制御部220に対し、テナントの登録要求を出す。このとき、テナント名及びテナントの利用するデータベースのモデルについてマルチテナント制御部220に通知する。   In step S <b> 601, the system administrator's client system 102 issues a tenant registration request to the multi-tenant control unit 220. At this time, the multi-tenant control unit 220 is notified of the tenant name and the database model used by the tenant.

S602において、マルチテナント制御部220は、マルチテナント管理データベース300に対し、テナント管理テーブル310にテナント名を登録し、テナントIDを発行するよう要求する。   In S602, the multi-tenant control unit 220 requests the multi-tenant management database 300 to register a tenant name in the tenant management table 310 and issue a tenant ID.

S603において、マルチテナント管理データベース300は、テナントを登録し、発行したテナントIDを返す。   In S603, the multi-tenant management database 300 registers the tenant and returns the issued tenant ID.

S604において、マルチテナント制御部220は、コネクション保持部230に対し、追加したテナント用のコネクションプールを発行するように要求する。   In S604, the multi-tenant control unit 220 requests the connection holding unit 230 to issue the added tenant connection pool.

S605において、コネクション保持部230は、新規テナント用のコネクションプールを生成し、プールIDを返す。ただし、テナントの利用するデータベースのモデルが表共有型データベース410だった場合、コネクション保持部230は、新規コネクションプールを生成せず、表共有型データベース410の共通のコネクションプールに対応するプールIDを返す。   In S605, the connection holding unit 230 generates a connection pool for a new tenant and returns a pool ID. However, when the database model used by the tenant is the table shared database 410, the connection holding unit 230 does not generate a new connection pool, but returns a pool ID corresponding to the common connection pool of the table shared database 410. .

S606において、マルチテナント制御部220は、マルチテナント管理データベース300に対し、データベース接続設定テーブル330に新規テナントのテナントID、接続先DBモデル、プールIDを追加する更新を要求する。   In step S <b> 606, the multi-tenant control unit 220 requests the multi-tenant management database 300 to update the database connection setting table 330 to add the tenant ID, connection destination DB model, and pool ID of the new tenant.

S607において、マルチテナント管理データベース300は、データベース接続設定テーブル330の更新を行い、結果を返す。   In S607, the multi-tenant management database 300 updates the database connection setting table 330 and returns the result.

S608において、マルチテナント制御部220は、マルチテナント型データベース400に対し、新規テナント用のデータ領域を追加するよう要求する。   In S608, the multi-tenant control unit 220 requests the multi-tenant database 400 to add a data area for a new tenant.

S609において、マルチテナント型データベース400は、新規テナントのデータ領域を追加し、成否をマルチテナント制御部220に通知する。   In S609, the multi-tenant database 400 adds a new tenant data area and notifies the multi-tenant control unit 220 of success or failure.

S610において、マルチテナント制御部220は、システム管理者のクライアントシステム102に対し、登録の成否を通知する。   In S610, the multi-tenant control unit 220 notifies the client system 102 of the system administrator of the success or failure of registration.

以上の動作により、マルチテナントアプリケーションを利用したいという新規テナントに対して、即時でアプリケーションの利用を開放することが可能となる。   With the above operation, it becomes possible to immediately release the use of the application to a new tenant who wants to use the multi-tenant application.

以上説明したように、本実施の形態では、マルチテナントサービスを提供する上で、マルチテナントアプリケーションを利用していなかったテナントが利用を希望する場合に、既存アプリケーション500の改修なく、テナントの追加が可能である。そのために、本実施の形態では、マルチテナントアプリケーションのシステム管理者が管理用アプリケーションでテナントを登録した場合、マルチテナント制御部220によって新規テナントが利用するのに必要な設定を自動で行う。具体的には、マルチテナント型データベース400に新規テナント用のデータ領域を確保し、データベースアクセス用のコネクションの設定を用意する。   As described above, in this embodiment, when a tenant who has not used a multi-tenant application desires to use a multi-tenant service, the tenant can be added without renovation of the existing application 500. Is possible. Therefore, in this embodiment, when a system administrator of a multi-tenant application registers a tenant with a management application, the multi-tenant control unit 220 automatically performs settings necessary for the new tenant to use. Specifically, a data area for a new tenant is secured in the multi-tenant database 400 and a connection setting for database access is prepared.

実施の形態3.
本実施の形態について、主に実施の形態1との差異を説明する。
Embodiment 3 FIG.
In the present embodiment, differences from the first embodiment will be mainly described.

図13は、本実施の形態に係るアクセス制御装置100の構成を示すブロック図である。   FIG. 13 is a block diagram showing a configuration of access control apparatus 100 according to the present embodiment.

図13において、アクセス制御装置100は、DB接続部240の表共有型接続部243に、表共有型データベース410から受信した結果の整合性を確認するためのデータチェック部246を備える。その他の構成は、図1に示した実施の形態1のものと同様である。   In FIG. 13, the access control apparatus 100 includes a data check unit 246 for confirming the consistency of the result received from the table sharing type database 410 in the table sharing type connection unit 243 of the DB connection unit 240. Other configurations are the same as those of the first embodiment shown in FIG.

図14は、マルチテナント管理データベース300のデータベース接続設定テーブル330の構成例を示す図である。   FIG. 14 is a diagram illustrating a configuration example of the database connection setting table 330 of the multi-tenant management database 300.

図14において、データベース接続設定テーブル330は、図3に示した実施の形態1のものと同様に、テナントID、接続先DBモデル、プールID、DBチェック情報のカラムを含む。DBチェック情報は、前述したように、特定のテーブルに格納されるデータについて設定された条件を示す。この条件は、接続先DBモデルが表共有型データベース410の場合のみ設定される。本例において、データベース接続設定テーブル330は、テナントID「A」に対応付けて、テナントAのデータについてのチェック条件をDBチェック情報として格納している。また、データベース接続設定テーブル330は、テナントID「B」に対応付けて、テナントBのデータについてのチェック条件をDBチェック情報として格納している。   In FIG. 14, the database connection setting table 330 includes columns of tenant ID, connection destination DB model, pool ID, and DB check information, as in the first embodiment shown in FIG. As described above, the DB check information indicates a condition set for data stored in a specific table. This condition is set only when the connection destination DB model is the table sharing database 410. In this example, the database connection setting table 330 stores check conditions for the data of the tenant A as DB check information in association with the tenant ID “A”. Further, the database connection setting table 330 stores check conditions for the data of the tenant B as DB check information in association with the tenant ID “B”.

上記のように、本実施の形態において、マルチテナント管理データベース300は、表共有型データベース410をアクセス対象とするテナントごとに、各テナントに共通のテーブルに格納されるデータについて設定された条件を記憶装置により予め記憶する。   As described above, in the present embodiment, the multi-tenant management database 300 stores conditions set for data stored in a table common to each tenant for each tenant whose access target is the table sharing database 410. Pre-stored by the device.

以下では、図15を用いて、テナントAのクライアントシステム101からサービスのリクエストが送信されたときのアクセス制御装置100の動作(本実施の形態に係るアクセス制御方法、本実施の形態に係るプログラムの処理手順)について説明する。   Hereinafter, the operation of the access control device 100 when a service request is transmitted from the client system 101 of the tenant A (the access control method according to the present embodiment, the program according to the present embodiment, and the like) will be described with reference to FIG. Processing procedure) will be described.

既存アプリケーション500にテナントIDを意識させずに既存アプリケーション500を利用するために、既存パラメータに対するテナントIDの結合及び分離を行う流れは、図7に示した実施の形態1のものと同様である。   In order to use the existing application 500 without making the existing application 500 aware of the tenant ID, the flow of combining and separating the tenant ID with respect to the existing parameter is the same as that of the first embodiment shown in FIG.

図15は、表共有型データベース410へのアクセスの流れを示すシーケンス図である。   FIG. 15 is a sequence diagram showing a flow of access to the table sharing database 410.

S701〜S709の処理については、図8に示したS201〜S209の処理と同様である。   The processing of S701 to S709 is the same as the processing of S201 to S209 shown in FIG.

S710において、表共有型接続部243は、表共有型データベース410からの検索結果に対し、データチェック部246を用いて他のテナントの情報が混ざっていないかどうか確認する。   In step S <b> 710, the table sharing type connection unit 243 uses the data check unit 246 to check whether the search results from the table sharing type database 410 are mixed.

S711において、データチェック部246は、データベース接続設定テーブル330のDBチェック情報を基に、表共有型データベース410からの検索結果に対し、他のテナントの情報がないかどうかを処理装置により確認する。データチェック部246は、他のテナントの情報が混ざっていることを検知した場合、その情報を削除するか、あるいは、エラーを通知する。   In step S <b> 711, the data check unit 246 uses the processing device to check whether there is any other tenant information for the search result from the table sharing database 410 based on the DB check information in the database connection setting table 330. When the data check unit 246 detects that other tenant information is mixed, the data check unit 246 deletes the information or notifies an error.

S712の処理については、図8に示したS210の処理と同様である。なお、S711でデータチェック部246がエラーを通知した場合は、検索結果としてエラーをモデル切替部242へ通知する。   The process of S712 is the same as the process of S210 illustrated in FIG. If the data check unit 246 notifies an error in S711, the error is notified to the model switching unit 242 as a search result.

マルチテナント型データベース400の検索結果をクライアントシステム101へ返す処理の流れは、図9に示したものと同様である。   The flow of processing for returning the search result of the multi-tenant database 400 to the client system 101 is the same as that shown in FIG.

以上説明した動作により、マルチテナントアプリケーションからテナントAのユーザへのサービス提供が行われる。テナントBのクライアントシステム101からサービスのリクエストが送信されたときにも、同様の動作により、マルチテナントアプリケーションからテナントBのユーザへのサービス提供が行われる。   With the operation described above, the service is provided from the multi-tenant application to the user of the tenant A. When a service request is transmitted from the client system 101 of the tenant B, the service is provided from the multi-tenant application to the user of the tenant B by the same operation.

図16は、S711におけるデータチェック部246の動作例を示す図である。   FIG. 16 is a diagram illustrating an operation example of the data check unit 246 in S711.

図16において、データチェック部246は、既存パラメータから取り出されたテナントIDに対応するDBチェック情報により設定された条件を含むクエリ(第2のクエリ)を表共有型データベース410に対して発行する。データチェック部246は、発行したクエリ(第2のクエリ)の結果と、S708で表共有型接続部243を介して既存アプリケーション500により発行されたクエリ(第1のクエリ)の結果とを比較する。そして、データチェック部246は、比較の結果に基づいて、S708で表共有型接続部243を介して既存アプリケーション500により発行されたクエリ(第1のクエリ)の結果の正否を処理装置により判定する。   In FIG. 16, the data check unit 246 issues a query (second query) including a condition set by the DB check information corresponding to the tenant ID extracted from the existing parameter to the table sharing database 410. The data check unit 246 compares the result of the issued query (second query) with the result of the query (first query) issued by the existing application 500 via the table sharing type connection unit 243 in S708. . Then, the data check unit 246 determines, based on the comparison result, whether the result of the query (first query) issued by the existing application 500 via the table sharing type connection unit 243 in S708 is correct or not. .

ここで、第1例として、データベース接続設定テーブル330において、テナントAのDBチェック情報により、クエリのアクセス対象とするテーブル全てのテナントIDが「A」であることがチェック条件として設定されているとする。そして、既存アプリケーション500が、個人情報テーブル(ユーザ一覧)、組織情報テーブル(組織一覧)、配属情報テーブル(配属一覧)をアクセス対象として指定して、テナントID、ユーザ名、組織名を抽出する第1クエリを発行したとする。この場合、S708において、表共有型接続部243は、既存アプリケーション500により発行された第1クエリ(例えば、SQLのSELECT文)に、個人情報テーブル(ユーザ一覧)、組織情報テーブル(組織一覧)、配属情報テーブル(配属一覧)のテナントIDが「A」であることを条件(例えば、WHERE句)として追加した上で、その第1クエリを表共有型データベース410に対して発行する。S711において、データチェック部246は、データベース接続設定テーブル330のDBチェック情報に基づき、個人情報テーブル(ユーザ一覧)、組織情報テーブル(組織一覧)、配属情報テーブル(配属一覧)のテナントIDが「A」であることを条件として含み、第1クエリと同様に、個人情報テーブル(ユーザ一覧)、組織情報テーブル(組織一覧)、配属情報テーブル(配属一覧)をアクセス対象として指定して、テナントID、ユーザ名、組織名を抽出する第2のクエリを表共有型データベース410に対して発行する(この第1例では、第2クエリは、表共有型接続部243により発行される第1クエリと同一のクエリとなる)。データチェック部246は、第2のクエリの結果と第1のクエリの結果とを比較する。第2のクエリの結果と第1のクエリの結果とは一致するため、データチェック部246は、第1のクエリの結果が正しいと判定する。   Here, as a first example, in the database connection setting table 330, it is set as a check condition that tenant IDs of all the tables to be accessed by the query are “A” based on the DB check information of the tenant A. To do. Then, the existing application 500 designates the personal information table (user list), organization information table (organization list), and assignment information table (assignment list) as access targets, and extracts the tenant ID, user name, and organization name. Assume that one query is issued. In this case, in S708, the table sharing type connection unit 243 adds a personal information table (user list), an organization information table (organization list), a first query issued by the existing application 500 (for example, an SQL SELECT statement), After adding as a condition (for example, WHERE clause) that the tenant ID of the assignment information table (assignment list) is “A”, the first query is issued to the table sharing database 410. In step S <b> 711, the data check unit 246 determines that the tenant ID of the personal information table (user list), organization information table (organization list), and allocation information table (allocation list) is “A” based on the DB check information in the database connection setting table 330. As a condition, and in the same way as the first query, the personal information table (user list), organization information table (organization list), and assignment information table (assignment list) are designated as access targets, and the tenant ID, A second query for extracting a user name and an organization name is issued to the table sharing type database 410 (in this first example, the second query is the same as the first query issued by the table sharing type connection unit 243). Query). The data check unit 246 compares the result of the second query with the result of the first query. Since the result of the second query matches the result of the first query, the data check unit 246 determines that the result of the first query is correct.

また、第2例として、データベース接続設定テーブル330において、テナントAのDBチェック情報により、ユーザIDが「USER01」又は「USER02」であることがチェック条件として設定されているとする。そして、既存アプリケーション500が、上記第1例と同じ第1クエリを発行したとする。この場合、S708において、表共有型接続部243は、既存アプリケーション500により発行された第1クエリ(例えば、SQLのSELECT文)に、上記第1例と同じ条件を追加した上で、その第1クエリを表共有型データベース410に対して発行する。S711において、データチェック部246は、データベース接続設定テーブル330のDBチェック情報に基づき、個人情報テーブル(ユーザ一覧)、配属情報テーブル(配属一覧)のユーザIDが「USER01」又は「USER02」であることを条件として含み、第1クエリと同様に、個人情報テーブル(ユーザ一覧)、組織情報テーブル(組織一覧)、配属情報テーブル(配属一覧)をアクセス対象として指定して、テナントID、ユーザ名、組織名を抽出する第2のクエリを表共有型データベース410に対して発行する。データチェック部246は、第2のクエリの結果と第1のクエリの結果とを比較する。第2のクエリの結果と第1のクエリの結果とは一致するため、データチェック部246は、第1のクエリの結果が正しいと判定する。   As a second example, in the database connection setting table 330, it is assumed that the user ID is “USER01” or “USER02” is set as a check condition by the DB check information of the tenant A. Assume that the existing application 500 issues the same first query as in the first example. In this case, in S708, the table sharing type connection unit 243 adds the same condition as in the first example to the first query issued by the existing application 500 (for example, the SQL SELECT statement), and then adds the first condition. A query is issued to the table sharing database 410. In S711, based on the DB check information in the database connection setting table 330, the data check unit 246 indicates that the user ID of the personal information table (user list) and the assignment information table (assignment list) is “USER01” or “USER02”. As a first query, a personal information table (user list), an organization information table (organization list), and an assignment information table (assignment list) are designated as access targets, and the tenant ID, user name, organization A second query for extracting a name is issued to the table sharing database 410. The data check unit 246 compares the result of the second query with the result of the first query. Since the result of the second query matches the result of the first query, the data check unit 246 determines that the result of the first query is correct.

以上説明したように、本実施の形態では、表共有型データベース410へアクセスする際に検索結果に他のテナントの情報が混ざることなく、対象のテナントの情報のみを確実に取得するためのチェック機能を実現する。   As described above, in the present embodiment, when accessing the table sharing database 410, a check function for reliably acquiring only the information of the target tenant without mixing other tenant information in the search result Is realized.

マルチテナントアプリケーションのデータベースが表共有型モデルの場合、データベースのテーブル上では複数のテナントの情報が混在しているため、検索のSQLでWHERE句により別のテナントが混ざらないようにする必要がある。しかしながら、検索のSQLが複雑になってくる場合、単純にWHERE句にテナント条件を追加するだけではテナントの情報を分離しきれないケースも考えられる。例えば、検索の際に複数のテーブルをJOIN句により結合したSQLを用いる場合、他のテナントの情報が紛れ込んでしまう可能性がある。これに対し、本実施の形態では、データベースの検索結果に対し、テナントごとの条件をWHERE句に記述したSQLで再度検索をかけることにより、別のテナントの情報が含まれるのを防ぐことが可能になる。   When the database of the multi-tenant application is a table sharing type model, since information on a plurality of tenants is mixed on the database table, it is necessary to prevent another tenant from being mixed by the WHERE clause in the search SQL. However, when the search SQL becomes complicated, there may be a case where tenant information cannot be separated simply by adding tenant conditions to the WHERE clause. For example, in the case of using SQL in which a plurality of tables are joined by a JOIN clause at the time of search, information on other tenants may be mixed in. On the other hand, in this embodiment, it is possible to prevent another tenant's information from being included by performing a search again using the SQL described in the WHERE clause for the search result of the database. become.

以上、本発明の実施の形態について説明したが、これらの実施の形態のうち、2つ以上を組み合わせて実施しても構わない。あるいは、これらの実施の形態のうち、1つを部分的に実施しても構わない。あるいは、これらの実施の形態のうち、2つ以上を部分的に組み合わせて実施しても構わない。なお、本発明は、これらの実施の形態に限定されるものではなく、必要に応じて種々の変更が可能である。   As mentioned above, although embodiment of this invention was described, you may implement in combination of 2 or more among these embodiment. Alternatively, one of these embodiments may be partially implemented. Alternatively, two or more of these embodiments may be partially combined. In addition, this invention is not limited to these embodiment, A various change is possible as needed.

100 アクセス制御装置、101,102 クライアントシステム、200 マルチテナントアプリケーション基盤、210 UI接続部、220 マルチテナント制御部、230 コネクション保持部、240 DB接続部、241 テナント分離部、242 モデル切替部、243 表共有型接続部、244 スキーマ分離型接続部、245 インスタンス分離型接続部、246 データチェック部、300 マルチテナント管理データベース、310 テナント管理テーブル、320 テナント情報結合設定テーブル、330 データベース接続設定テーブル、400 マルチテナント型データベース、410 表共有型データベース、420 スキーマ分離型データベース、430 インスタンス分離型データベース、500 既存アプリケーション、901 LCD、902 キーボード、903 マウス、904 FDD、905 CDD、906 プリンタ、911 CPU、912 バス、913 ROM、914 RAM、915 通信ボード、920 HDD、921 オペレーティングシステム、922 ウィンドウシステム、923 プログラム群、924 ファイル群。   100 access control device, 101, 102 client system, 200 multi-tenant application platform, 210 UI connection unit, 220 multi-tenant control unit, 230 connection holding unit, 240 DB connection unit, 241 tenant separation unit, 242 model switching unit, 243 table Shared connection unit, 244 Schema separation type connection unit, 245 Instance separation type connection unit, 246 Data check unit, 300 Multi-tenant management database, 310 Tenant management table, 320 Tenant information combination setting table, 330 Database connection setting table, 400 multi Tenant type database, 410 Table shared type database, 420 Schema separated type database, 430 Instance separated type database, 500 Existing application 901 LCD, 902 keyboard, 903 mouse, 904 FDD, 905 CDD, 906 printer, 911 CPU, 912 bus, 913 ROM, 914 RAM, 915 communication board, 920 HDD, 921 operating system, 922 window system, 923 program group 924 file group.

Claims (7)

ユーザが少なくとも1人ずつ属する複数のテナントによって共用されるアプリケーションから、前記複数のテナントそれぞれの個別のデータを格納するマルチテナント対応型の少なくとも2種類のデータベースへのアクセスを制御するアクセス制御装置であって、
テナントごとに、テナントを一意に識別するテナント識別子と、アクセス対象とするデータベースの種類とを記憶装置により予め記憶するマルチテナント管理データベースと、
前記アプリケーションに入力されると前記アプリケーションが前記少なくとも2種類のデータベースへのアクセス時に出力するパラメータの入力を、前記複数のテナントのいずれかに属するユーザから入力装置により受け付け、当該ユーザが属するテナントのテナント識別子を前記マルチテナント管理データベースから読み出して当該パラメータに埋め込み、当該パラメータを前記アプリケーションに入力するユーザインタフェース接続部と、
前記ユーザインタフェース接続部により入力されたパラメータが前記アプリケーションから出力された場合、当該パラメータに埋め込まれているテナント識別子を取り出し、取り出したテナント識別子に対応するテナントのデータベースの種類を前記マルチテナント管理データベースから読み出し、前記少なくとも2種類のデータベースのうち、読み出した種類のデータベースに格納された当該テナントの個別のデータへのアクセスを前記アプリケーションに行わせるデータベース接続部と
を備えることを特徴とするアクセス制御装置。
An access control device for controlling access to at least two types of multi-tenant-compatible databases that store individual data of each of the plurality of tenants from an application shared by a plurality of tenants to which at least one user belongs. And
For each tenant, a multi-tenant management database that pre-stores a tenant identifier that uniquely identifies a tenant and the type of database to be accessed by a storage device;
When input to the application, the input of parameters that the application outputs when accessing the at least two types of databases is accepted from a user belonging to one of the tenants by the input device, and the tenant of the tenant to which the user belongs An identifier is read from the multi-tenant management database, embedded in the parameter, and a user interface connection unit that inputs the parameter to the application;
When the parameter input by the user interface connection unit is output from the application, the tenant identifier embedded in the parameter is extracted, and the tenant database type corresponding to the extracted tenant identifier is extracted from the multi-tenant management database. An access control apparatus comprising: a database connection unit that reads and causes the application to access individual data of the tenant stored in the read type database among the at least two types of databases.
前記少なくとも2種類のデータベースは、マルチテナント対応のための構成が互いに異なる複数種類のデータベースからなることを特徴とする請求項1のアクセス制御装置。   The access control apparatus according to claim 1, wherein the at least two types of databases include a plurality of types of databases having different configurations for multi-tenancy. 前記複数種類のデータベースは、前記複数のテナントそれぞれの個別のデータを、テナント識別子のカラムを含む共通のテーブルに格納することによりマルチテナント対応を行う第1種類のデータベースと、テナントごとに、テナントの個別のデータを個別のテーブルに格納することによりマルチテナント対応を行う第2種類のデータベースと、テナントごとに、テナントの個別のデータを格納する個別のデータベースインスタンスが存在することによりマルチテナント対応を行う第3種類のデータベースとであることを特徴とする請求項2のアクセス制御装置。   The plurality of types of databases include a first type database that performs multi-tenant correspondence by storing individual data of each of the plurality of tenants in a common table including a column of tenant identifiers, Multi-tenant support is provided by the existence of a second type of database that supports multi-tenant by storing individual data in separate tables and a separate database instance that stores individual tenant data for each tenant. 3. The access control apparatus according to claim 2, wherein the access control apparatus is a third type database. 前記アプリケーションは、前記複数種類のデータベースに対して第1のクエリを発行することにより前記複数種類のデータベースへのアクセスを行うアプリケーションであり、
前記マルチテナント管理データベースは、前記第1種類のデータベースをアクセス対象とするテナントごとに、前記共通のテーブルに格納されるデータについて設定された条件を予め記憶し、
前記データベース接続部は、前記マルチテナント管理データベースから読み出したデータベースの種類が前記第1種類のデータベースである場合、前記パラメータから取り出したテナント識別子に対応するテナントの条件を前記マルチテナント管理データベースから読み出し、前記第1種類のデータベースに対して当該条件を含む第2のクエリを発行し、前記アプリケーションにより発行された第1のクエリの結果と当該第2のクエリの結果とを比較し、比較した結果に基づいて当該第1のクエリの結果の正否を処理装置により判定することを特徴とする請求項3のアクセス制御装置。
The application is an application that accesses the plurality of types of databases by issuing a first query to the plurality of types of databases,
The multi-tenant management database stores in advance conditions set for data stored in the common table for each tenant whose access target is the first type database,
When the database type read from the multi-tenant management database is the first type database, the database connection unit reads the tenant condition corresponding to the tenant identifier extracted from the parameter from the multi-tenant management database, Issuing a second query including the condition to the first type database, comparing the result of the first query issued by the application with the result of the second query, and comparing the result 4. The access control apparatus according to claim 3, wherein whether or not the result of the first query is correct is determined by a processing apparatus based on the determination result.
前記ユーザインタフェース接続部は、前記複数のテナントのいずれかに属するユーザから、前記パラメータとして、当該ユーザを一意に識別するユーザ識別子の入力を受け付け、当該ユーザが属するテナントのテナント識別子を前記マルチテナント管理データベースから読み出して当該ユーザ識別子に連結することにより、当該テナント識別子を前記パラメータに埋め込むことを特徴とする請求項1から4のいずれかのアクセス制御装置。   The user interface connection unit receives an input of a user identifier uniquely identifying the user as a parameter from a user belonging to any of the plurality of tenants, and the tenant identifier of the tenant to which the user belongs is managed in the multi-tenant management 5. The access control apparatus according to claim 1, wherein the tenant identifier is embedded in the parameter by reading from the database and connecting to the user identifier. ユーザが少なくとも1人ずつ属する複数のテナントによって共用されるアプリケーションから、前記複数のテナントそれぞれの個別のデータを格納するマルチテナント対応型の少なくとも2種類のデータベースへのアクセスを制御するアクセス制御方法であって、
テナントごとに、テナントを一意に識別するテナント識別子と、アクセス対象とするデータベースの種類とを記憶装置により予め記憶するマルチテナント管理データベースを備えるコンピュータが、前記アプリケーションに入力されると前記アプリケーションが前記少なくとも2種類のデータベースへのアクセス時に出力するパラメータの入力を、前記複数のテナントのいずれかに属するユーザから入力装置により受け付け、当該ユーザが属するテナントのテナント識別子を前記マルチテナント管理データベースから読み出して当該パラメータに埋め込み、当該パラメータを前記アプリケーションに入力し、
前記コンピュータが、入力したパラメータが前記アプリケーションから出力された場合、当該パラメータに埋め込まれているテナント識別子を取り出し、取り出したテナント識別子に対応するテナントのデータベースの種類を前記マルチテナント管理データベースから読み出し、前記少なくとも2種類のデータベースのうち、読み出した種類のデータベースに格納された当該テナントの個別のデータへのアクセスを前記アプリケーションに行わせることを特徴とするアクセス制御方法。
An access control method for controlling access to at least two types of multi-tenant-compatible databases storing individual data of each of the plurality of tenants from an application shared by a plurality of tenants to which at least one user belongs. And
For each tenant, when a computer including a multi-tenant management database that pre-stores a tenant identifier that uniquely identifies a tenant and a type of database to be accessed by a storage device is input to the application, the application Input of parameters to be output when accessing two types of databases is received by an input device from a user belonging to one of the plurality of tenants, the tenant identifier of the tenant to which the user belongs is read from the multi-tenant management database, and the parameter And enter the parameters into the application,
When the input parameter is output from the application, the computer extracts the tenant identifier embedded in the parameter, reads out the tenant database type corresponding to the extracted tenant identifier from the multi-tenant management database, An access control method that causes the application to access individual data of the tenant stored in a read type database among at least two types of databases.
ユーザが少なくとも1人ずつ属する複数のテナントによって共用されるアプリケーションから、前記複数のテナントそれぞれの個別のデータを格納するマルチテナント対応型の少なくとも2種類のデータベースへのアクセスを制御するプログラムであって、
テナントごとに、テナントを一意に識別するテナント識別子と、アクセス対象とするデータベースの種類とを記憶装置により予め記憶するマルチテナント管理データベースを備えるコンピュータを、
前記アプリケーションに入力されると前記アプリケーションが前記少なくとも2種類のデータベースへのアクセス時に出力するパラメータの入力を、前記複数のテナントのいずれかに属するユーザから入力装置により受け付け、当該ユーザが属するテナントのテナント識別子を前記マルチテナント管理データベースから読み出して当該パラメータに埋め込み、当該パラメータを前記アプリケーションに入力するユーザインタフェース接続部と、
前記ユーザインタフェース接続部により入力されたパラメータが前記アプリケーションから出力された場合、当該パラメータに埋め込まれているテナント識別子を取り出し、取り出したテナント識別子に対応するテナントのデータベースの種類を前記マルチテナント管理データベースから読み出し、前記少なくとも2種類のデータベースのうち、読み出した種類のデータベースに格納された当該テナントの個別のデータへのアクセスを前記アプリケーションに行わせるデータベース接続部
として機能させるためのプログラム。
A program for controlling access to at least two types of multitenant-compatible databases that store individual data of each of the plurality of tenants from an application shared by a plurality of tenants to which at least one user belongs,
For each tenant, a computer having a multi-tenant management database that pre-stores a tenant identifier for uniquely identifying a tenant and a type of database to be accessed by a storage device,
When input to the application, the input of parameters that the application outputs when accessing the at least two types of databases is accepted from a user belonging to one of the tenants by the input device, and the tenant of the tenant to which the user belongs An identifier is read from the multi-tenant management database, embedded in the parameter, and a user interface connection unit that inputs the parameter to the application;
When the parameter input by the user interface connection unit is output from the application, the tenant identifier embedded in the parameter is extracted, and the tenant database type corresponding to the extracted tenant identifier is extracted from the multi-tenant management database. A program for reading and functioning as a database connection unit that causes the application to access individual data of the tenant stored in the read type database among the at least two types of databases.
JP2012043936A 2012-02-29 2012-02-29 Access control apparatus, access control method and program Active JP5773910B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2012043936A JP5773910B2 (en) 2012-02-29 2012-02-29 Access control apparatus, access control method and program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2012043936A JP5773910B2 (en) 2012-02-29 2012-02-29 Access control apparatus, access control method and program

Publications (2)

Publication Number Publication Date
JP2013182310A JP2013182310A (en) 2013-09-12
JP5773910B2 true JP5773910B2 (en) 2015-09-02

Family

ID=49272939

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2012043936A Active JP5773910B2 (en) 2012-02-29 2012-02-29 Access control apparatus, access control method and program

Country Status (1)

Country Link
JP (1) JP5773910B2 (en)

Families Citing this family (58)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2017090142A1 (en) * 2015-11-26 2017-06-01 株式会社野村総合研究所 Service-providing system
US10341410B2 (en) 2016-05-11 2019-07-02 Oracle International Corporation Security tokens for a multi-tenant identity and data security management cloud service
KR101871902B1 (en) * 2016-05-11 2018-06-27 오라클 인터내셔날 코포레이션 Multi-tenant identity and data security management cloud services
US9838377B1 (en) 2016-05-11 2017-12-05 Oracle International Corporation Task segregation in a multi-tenant identity and data security management cloud service
US9781122B1 (en) 2016-05-11 2017-10-03 Oracle International Corporation Multi-tenant identity and data security management cloud service
US10425386B2 (en) 2016-05-11 2019-09-24 Oracle International Corporation Policy enforcement point for a multi-tenant identity and data security management cloud service
US10878079B2 (en) 2016-05-11 2020-12-29 Oracle International Corporation Identity cloud service authorization model with dynamic roles and scopes
US10454940B2 (en) 2016-05-11 2019-10-22 Oracle International Corporation Identity cloud service authorization model
US9838376B1 (en) 2016-05-11 2017-12-05 Oracle International Corporation Microservices based multi-tenant identity and data security management cloud service
US10581820B2 (en) 2016-05-11 2020-03-03 Oracle International Corporation Key generation and rollover
US10530578B2 (en) 2016-08-05 2020-01-07 Oracle International Corporation Key store service
US10263947B2 (en) 2016-08-05 2019-04-16 Oracle International Corporation LDAP to SCIM proxy service
US10505941B2 (en) 2016-08-05 2019-12-10 Oracle International Corporation Virtual directory system for LDAP to SCIM proxy service
US10585682B2 (en) 2016-08-05 2020-03-10 Oracle International Corporation Tenant self-service troubleshooting for a multi-tenant identity and data security management cloud service
US10516672B2 (en) 2016-08-05 2019-12-24 Oracle International Corporation Service discovery for a multi-tenant identity and data security management cloud service
US10255061B2 (en) 2016-08-05 2019-04-09 Oracle International Corporation Zero down time upgrade for a multi-tenant identity and data security management cloud service
US10735394B2 (en) 2016-08-05 2020-08-04 Oracle International Corporation Caching framework for a multi-tenant identity and data security management cloud service
US10484382B2 (en) 2016-08-31 2019-11-19 Oracle International Corporation Data management for a multi-tenant identity cloud service
US10511589B2 (en) 2016-09-14 2019-12-17 Oracle International Corporation Single logout functionality for a multi-tenant identity and data security management cloud service
US10846390B2 (en) 2016-09-14 2020-11-24 Oracle International Corporation Single sign-on functionality for a multi-tenant identity and data security management cloud service
US10594684B2 (en) 2016-09-14 2020-03-17 Oracle International Corporation Generating derived credentials for a multi-tenant identity cloud service
US10567364B2 (en) 2016-09-16 2020-02-18 Oracle International Corporation Preserving LDAP hierarchy in a SCIM directory using special marker groups
US10791087B2 (en) 2016-09-16 2020-09-29 Oracle International Corporation SCIM to LDAP mapping using subtype attributes
JP7018437B2 (en) 2016-09-16 2022-02-10 オラクル・インターナショナル・コーポレイション Multi-tenant identity and data security management Tenant and service management for cloud services
US10484243B2 (en) 2016-09-16 2019-11-19 Oracle International Corporation Application management for a multi-tenant identity cloud service
US10445395B2 (en) 2016-09-16 2019-10-15 Oracle International Corporation Cookie based state propagation for a multi-tenant identity cloud service
US10341354B2 (en) 2016-09-16 2019-07-02 Oracle International Corporation Distributed high availability agent architecture
US10904074B2 (en) 2016-09-17 2021-01-26 Oracle International Corporation Composite event handler for a multi-tenant identity cloud service
US10261836B2 (en) 2017-03-21 2019-04-16 Oracle International Corporation Dynamic dispatching of workloads spanning heterogeneous services
CN106960348B (en) * 2017-03-24 2020-07-03 泰华智慧产业集团股份有限公司 Payment docking method and payment docking system
US10454915B2 (en) 2017-05-18 2019-10-22 Oracle International Corporation User authentication using kerberos with identity cloud service
US10348858B2 (en) 2017-09-15 2019-07-09 Oracle International Corporation Dynamic message queues for a microservice based cloud service
US11308132B2 (en) 2017-09-27 2022-04-19 Oracle International Corporation Reference attributes for related stored objects in a multi-tenant cloud service
US10834137B2 (en) 2017-09-28 2020-11-10 Oracle International Corporation Rest-based declarative policy management
US11271969B2 (en) 2017-09-28 2022-03-08 Oracle International Corporation Rest-based declarative policy management
US10705823B2 (en) 2017-09-29 2020-07-07 Oracle International Corporation Application templates and upgrade framework for a multi-tenant identity cloud service
JP2019087176A (en) * 2017-11-10 2019-06-06 株式会社明電舎 Monitoring system, monitoring method, and monitoring system program
US10715564B2 (en) 2018-01-29 2020-07-14 Oracle International Corporation Dynamic client registration for an identity cloud service
US10931656B2 (en) 2018-03-27 2021-02-23 Oracle International Corporation Cross-region trust for a multi-tenant identity cloud service
US10798165B2 (en) 2018-04-02 2020-10-06 Oracle International Corporation Tenant data comparison for a multi-tenant identity cloud service
US11165634B2 (en) 2018-04-02 2021-11-02 Oracle International Corporation Data replication conflict detection and resolution for a multi-tenant identity cloud service
US11258775B2 (en) 2018-04-04 2022-02-22 Oracle International Corporation Local write for a multi-tenant identity cloud service
CN110019244A (en) * 2018-05-14 2019-07-16 网联清算有限公司 Data processing method, device and computer readable storage medium
US11012444B2 (en) 2018-06-25 2021-05-18 Oracle International Corporation Declarative third party identity provider integration for a multi-tenant identity cloud service
US10764273B2 (en) 2018-06-28 2020-09-01 Oracle International Corporation Session synchronization across multiple devices in an identity cloud service
US11693835B2 (en) 2018-10-17 2023-07-04 Oracle International Corporation Dynamic database schema allocation on tenant onboarding for a multi-tenant identity cloud service
US11321187B2 (en) 2018-10-19 2022-05-03 Oracle International Corporation Assured lazy rollback for a multi-tenant identity cloud service
US11651357B2 (en) 2019-02-01 2023-05-16 Oracle International Corporation Multifactor authentication without a user footprint
US11061929B2 (en) 2019-02-08 2021-07-13 Oracle International Corporation Replication of resource type and schema metadata for a multi-tenant identity cloud service
US11321343B2 (en) 2019-02-19 2022-05-03 Oracle International Corporation Tenant replication bootstrap for a multi-tenant identity cloud service
US11669321B2 (en) 2019-02-20 2023-06-06 Oracle International Corporation Automated database upgrade for a multi-tenant identity cloud service
US11792226B2 (en) 2019-02-25 2023-10-17 Oracle International Corporation Automatic api document generation from scim metadata
US11423111B2 (en) 2019-02-25 2022-08-23 Oracle International Corporation Client API for rest based endpoints for a multi-tenant identify cloud service
US11870770B2 (en) 2019-09-13 2024-01-09 Oracle International Corporation Multi-tenant identity cloud service with on-premise authentication integration
US11687378B2 (en) 2019-09-13 2023-06-27 Oracle International Corporation Multi-tenant identity cloud service with on-premise authentication integration and bridge high availability
US11611548B2 (en) 2019-11-22 2023-03-21 Oracle International Corporation Bulk multifactor authentication enrollment
US20230394126A1 (en) * 2021-01-22 2023-12-07 Rakuten Mobile, Inc Computer system and user management method
CN115118765B (en) * 2022-06-20 2024-04-05 北京京东乾石科技有限公司 Service processing method, device, electronic equipment and storage medium

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7779039B2 (en) * 2004-04-02 2010-08-17 Salesforce.Com, Inc. Custom entities and fields in a multi-tenant database system
JP4778500B2 (en) * 2007-12-11 2011-09-21 株式会社日立情報システムズ DATABASE SYSTEM AND DATABASE SYSTEM CONTROL METHOD
JP5358981B2 (en) * 2008-03-07 2013-12-04 日本電気株式会社 Information processing apparatus, information processing apparatus control method, and information processing apparatus control program

Also Published As

Publication number Publication date
JP2013182310A (en) 2013-09-12

Similar Documents

Publication Publication Date Title
JP5773910B2 (en) Access control apparatus, access control method and program
US9294485B2 (en) Controlling access to shared content in an online content management system
RU2598324C2 (en) Means of controlling access to online service using conventional catalogue features
WO2016199232A1 (en) Storage management computer and management method for storage device
WO2021197432A1 (en) Routing method and apparatus for database cluster
US8275962B2 (en) User roles controlling execution of operations on copy pair volumes
KR20120062514A (en) Authorization apparatus and method under software as a service platform
CN110678845A (en) Multi-tenant data services in a distributed file system for big data analytics
JP4912996B2 (en) Information processing apparatus and computer system
KR101714412B1 (en) Method and apparatus for organizing database system in cloud environment
TW201512990A (en) Method for managing topology of virtual machines and management system using for the same
JP6889372B2 (en) Log management equipment, information processing systems and programs
US11048543B2 (en) Computer system and resource access control method for securely controlling access using roles with a plurality of users
CN109729071A (en) A kind of vmware multi-tenant management method suitable for cloudy management
JP6012504B2 (en) Workflow management system, workflow management method and program
JP2020119147A (en) System, tenant moving method, information processing apparatus and control method thereof, authorization server and control method thereof, and program
JP2004303023A (en) Access managing method
JP7354620B2 (en) Service system, information registration method
JP2018022336A (en) Information processing system, information processing device, and program
JP6716929B2 (en) Information processing apparatus and information processing program
WO2014147811A1 (en) File storage system and user data management method
JP2015103827A (en) Management device, method, and program
JP2015132972A (en) Data relocation system
US11709845B2 (en) Federation of data during query time in computing systems
JP2014035610A (en) Authentication system and authentication method

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20141003

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20150520

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: 20150602

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20150630

R150 Certificate of patent or registration of utility model

Ref document number: 5773910

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250