JPH08235047A - Exclusive wait reduction control method - Google Patents

Exclusive wait reduction control method

Info

Publication number
JPH08235047A
JPH08235047A JP7059864A JP5986495A JPH08235047A JP H08235047 A JPH08235047 A JP H08235047A JP 7059864 A JP7059864 A JP 7059864A JP 5986495 A JP5986495 A JP 5986495A JP H08235047 A JPH08235047 A JP H08235047A
Authority
JP
Japan
Prior art keywords
transaction
transaction program
program
resource
address
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
JP7059864A
Other languages
Japanese (ja)
Other versions
JP2654612B2 (en
Inventor
Hideki Takeuchi
竹内  秀樹
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
NEC Corp
Original Assignee
NEC Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by NEC Corp filed Critical NEC Corp
Priority to JP7059864A priority Critical patent/JP2654612B2/en
Publication of JPH08235047A publication Critical patent/JPH08235047A/en
Application granted granted Critical
Publication of JP2654612B2 publication Critical patent/JP2654612B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Landscapes

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

PURPOSE: To reduce the exclusive wait when the same resources are updated by plural transaction programs and to attain the multiple run of these programs. CONSTITUTION: When a transaction program TX1 updated the resource R1 and then does not carry out the transaction end processing yet, a transaction program TX2 updates the resource R1. Under such conditions, the program TX2 updates the resource R1 with no exclusive wait and waits for the end of transaction of the program TX1 after the updating processing (exclusive wait). When the program TX1 is committed, the program TX2 is rolled back. Then the program TX2 is committed when the program TX1 is rolled back.

Description

【発明の詳細な説明】Detailed Description of the Invention

【0001】[0001]

【産業上の利用分野】本発明は排他ウエイト削減制御方
法に関し、特に共有資源への同時更新が発生する計算機
システムにおいて処理効率を高めるための排他ウエイト
削減制御方法に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to an exclusive weight reduction control method, and more particularly to an exclusive weight reduction control method for improving processing efficiency in a computer system in which simultaneous updates to shared resources occur.

【0002】[0002]

【従来の技術】従来、この種の共有資源の排他制御方法
では、あるトランザクションプログラムが共有資源を更
新するときには共有資源をロックし、別のトランザクシ
ョンプログラムが同一の資源に更新を試みるときには別
のトランザクションプログラムを排他ウエイト(WAI
T)させることにより共有資源の排他制御を行ってい
た。
2. Description of the Related Art Conventionally, in this kind of exclusive control method of a shared resource, when a certain transaction program updates the shared resource, the shared resource is locked, and when another transaction program tries to update the same resource, another transaction program locks the shared resource. Exclusive weight for program (WAI
The exclusive control of the shared resource is performed by performing T).

【0003】また、トランザクションプログラム処理の
開始に先立って使用する全ての資源のロックを行うこと
により、排他ウエイトの発生を防止する方法もある(例
えば、特開平4−222035号公報参照)。
There is also a method for preventing the occurrence of an exclusive wait by locking all resources to be used prior to the start of a transaction program process (for example, see Japanese Patent Application Laid-Open No. H4-22235).

【0004】[0004]

【発明が解決しようとする課題】上述した従来の共有資
源の排他制御方法では、あるトランザクションプログラ
ムが共有資源を更新するときには共有資源をロックし
て、別のトランザクションプログラムからの更新処理を
排他ウエイトさせることにより共有資源の排他制御を行
っていたので、共有資源を使用するトランザクションプ
ログラムの多重走行ができず、処理効率を向上させるこ
とが難しいという問題点があった。
In the above-mentioned conventional shared resource exclusive control method, when a certain transaction program updates the shared resource, the shared resource is locked and the update processing from another transaction program is placed in an exclusive wait state. Since the exclusive control of the shared resource is performed by this, there is a problem that it is difficult to perform multiple runs of transaction programs that use the shared resource and it is difficult to improve processing efficiency.

【0005】また、トランザクションプログラム処理の
開始に先立って使用する全ての資源のロックを行うこと
により排他ウエイトの発生を防止する方法では、ある資
源を使用する複数のトランザクションプログラムを同時
に起動することができず、処理効率を向上させることが
難しいという問題点があった。
Further, in the method of preventing the generation of the exclusive wait by locking all the resources to be used before starting the transaction program processing, a plurality of transaction programs using a certain resource can be activated at the same time. Therefore, it is difficult to improve the processing efficiency.

【0006】本発明の目的は、上述の点に鑑み、第1の
トランザクションプログラムが資源を更新した後にコミ
ット(COMMIT)またはロールバック(ROLLB
ACK)によるトランザクション終了処理を実施してい
ない状態で、第2のトランザクションプログラムが同一
の資源を更新する場合に第2のトランザクションプログ
ラムが排他ウエイトすることなく資源を更新するように
して、複数のトランザクションプログラムが同一の資源
を更新する際の排他ウエイトを削減するようにした排他
ウエイト削減制御方法を提供することにある。
In view of the above points, an object of the present invention is to commit (COMMIT) or roll back (ROLLB) after the first transaction program updates the resource.
When the second transaction program updates the same resource in a state where the transaction end processing by ACK) is not performed, the second transaction program updates the resource without performing an exclusive wait, so that a plurality of transactions are performed. An object of the present invention is to provide an exclusive weight reduction control method for reducing an exclusive weight when a program updates the same resource.

【0007】[0007]

【課題を解決するための手段】本発明の排他ウエイト削
減制御方法は、第1のトランザクションプログラムが資
源を更新した後、まだコミットまたはロールバックによ
るトランザクション終了処理を実施していない状態で、
第2のトランザクションプログラムが同一の資源を更新
する場合において、前記第2のトランザクションプログ
ラムが前記資源の更新時に排他ウエイトすることなく前
記資源を更新し、前記第2のトランザクションプログラ
ムが前記第1のトランザクションプログラムよりも先行
してトランザクション終了処理を実施する場合には、前
記第1のトランザクションプログラムのトランザクショ
ン終了処理が完了するまで前記第2のトランザクション
プログラムのトランザクション終了処理を待ち合わせ、
前記第1のトランザクションプログラムがコミットした
ときには前記第2のトランザクションプログラムがロー
ルバックし、前記第1のトランザクションプログラムが
ロールバックしたときには前記第2のトランザクション
プログラムがコミットし、前記第1のトランザクション
プログラムが前記第2のトランザクションプログラムよ
り先行してトランザクション終了処理を実施する場合に
は、前記第1のトランザクションプログラムがコミット
したときには前記第2のトランザクションプログラムが
即座にロールバックし、前記第1のトランザクションプ
ログラムがロールバックしたときには前記第2のトラン
ザクションプログラムが処理を継続することにより、同
一資源を更新するトランザクションプログラムの多重走
行を実現することを特徴とする。
According to the exclusive weight reduction control method of the present invention, after the first transaction program has updated resources, the transaction end processing by commit or rollback has not yet been performed.
In a case where the second transaction program updates the same resource, the second transaction program updates the resource without performing an exclusive wait when updating the resource, and the second transaction program executes the first transaction. When the transaction end processing is performed prior to the program, the transaction end processing of the second transaction program is waited until the transaction end processing of the first transaction program is completed,
When the first transaction program commits, the second transaction program rolls back, and when the first transaction program rolls back, the second transaction program commits, and the first transaction program When the transaction end processing is performed prior to the second transaction program, when the first transaction program commits, the second transaction program immediately rolls back, and the first transaction program rolls back. The second transaction program continues processing when it is backed up, thereby realizing multiple runs of the transaction program for updating the same resource. And it features.

【0008】[0008]

【実施例】次に、本発明について図面を参照して詳細に
説明する。
The present invention will be described in detail with reference to the drawings.

【0009】図1は、本発明に係る排他ウエイト削減制
御方法を実現するオペレーティングシステムの構成を示
すブロック図である。このオペレーティングシステム
は、トランザクションディスパッチ手段100と、資源
更新手段200と、トランザクション終了処理手段30
0と、資源コミット手段400と、資源ロールバック手
段500と、トランザクション管理キュー(TCQ)6
00と、トランザクション制御ブロック(TCB)70
0と、資源管理ブロック(RCB)800と、更新状態
管理ブロック(UCB)900と、作業域1000とを
含んで構成されている。
FIG. 1 is a block diagram showing the configuration of an operating system for implementing the exclusive weight reduction control method according to the present invention. The operating system includes a transaction dispatch unit 100, a resource update unit 200, a transaction end processing unit 30
0, a resource commit unit 400, a resource rollback unit 500, and a transaction management queue (TCQ) 6.
00 and a transaction control block (TCB) 70
0, a resource management block (RCB) 800, an update status management block (UCB) 900, and a work area 1000.

【0010】トランザクションディスパッチ手段100
は、実行中状態,実行可能状態および待ち状態の各トラ
ンザクションプログラムのディスパッチを行う。
Transaction dispatch means 100
Performs the dispatch of each transaction program in the running state, the ready state, and the waiting state.

【0011】資源更新手段200は、図2中に示すよう
に、資源更新機能210および管理情報更新機能220
をトランザクションプログラムに提供する。
As shown in FIG. 2, the resource updating means 200 includes a resource updating function 210 and a management information updating function 220.
To the transaction program.

【0012】トランザクション終了処理手段300は、
図2中に示すように、コミット可否判断機能310をト
ランザクションプログラムに提供する。
The transaction end processing means 300
As shown in FIG. 2, the commitability determination function 310 is provided to the transaction program.

【0013】資源コミット手段400は、図2中に示す
ように、更新資源のコミット機能410および管理情報
更新機能420をトランザクションプログラムに提供す
る。
As shown in FIG. 2, the resource commit unit 400 provides a transaction program with an update resource commit function 410 and a management information update function 420.

【0014】資源ロールバック手段500は、図2中に
示すように、更新資源のロールバック機能510および
管理情報更新機能520を提供する。
The resource rollback means 500 provides an update resource rollback function 510 and a management information update function 520 as shown in FIG.

【0015】トランザクション管理キュー(TCQ)6
00は、トランザクションプログラムの状態(実行中,
実行可,待ち)毎にトランザクションプログラムを管理
するためのキューである。トランザクション管理キュー
(TCQ)600は、図3(a)に示すように、実行中
TCB先頭アドレス611,実行中TCB最終アドレス
612,実行可能TCB先頭アドレス621,実行可能
TCB最終アドレス622,ウエイト中TCB先頭アド
レス631およびウエイト中TCB最終アドレス632
を持つ。
Transaction management queue (TCQ) 6
00 is the status of the transaction program (running,
It is a queue for managing transaction programs for each execution and waiting. As shown in FIG. 3A, the transaction management queue (TCQ) 600 includes a running TCB head address 611, a running TCB last address 612, an executable TCB head address 621, an executable TCB last address 622, and a waiting TCB. Start address 631 and TCB last address during wait 632
have.

【0016】トランザクション制御ブロック(TCB)
700は、トランザクションプログラムの開始時にトラ
ンザクションプログラム毎に作成されるメモリ上の領域
で、トランザクションプログラムの状態管理に使用す
る。トランザクション制御ブロック(TCB)700
は、図3(b)に示すように、次TCBアドレス71
1,前TCBアドレス712,トランザクション(以
下、適宜、TXと略記する)内先頭UCBアドレス72
1,TX内最終UCBアドレス722,ロールバック受
付可否731,ロールバック要求有無732,ロールバ
ック回数上限741,ロールバック回数742,トラン
ザクション終了通知TCBアドレス751を持つ。トラ
ンザクションプログラムがロールバックして再スケジュ
ールされた場合、ロールバック前のトランザクション制
御ブロック(TCB)700を引き続き使用する。
Transaction control block (TCB)
Reference numeral 700 denotes a memory area created for each transaction program at the start of the transaction program, and is used for managing the state of the transaction program. Transaction control block (TCB) 700
Is the next TCB address 71 as shown in FIG.
1, the previous TCB address 712, the leading UCB address 72 in the transaction (hereinafter abbreviated to TX as appropriate)
1, the last UCB address in TX 722, rollback acceptance yes / no 731, rollback request existence 732, rollback number upper limit 741, rollback number 742, transaction end notification TCB address 751. When the transaction program is rolled back and rescheduled, the transaction control block (TCB) 700 before the rollback is continuously used.

【0017】資源管理ブロック(RCB)800は、計
算機システムの起動後の最初の資源更新時に資源の排他
単位に作成されるメモリ上の領域であり、資源の状態管
理に使用される。資源管理ブロック(RCB)800
は、図3(c)に示すように、リソース内先頭UCBア
ドレス811,リソース内最終UCBアドレス812,
管理資源長821,ロールバック回数上限831,ロー
ルバック回数832を持つ。
A resource management block (RCB) 800 is an area in a memory created in an exclusive unit of a resource at the time of the first resource update after the start of the computer system, and is used for resource status management. Resource management block (RCB) 800
Is, as shown in FIG. 3C, the first UCB address in the resource 811, the last UCB address in the resource 812,
The management resource length 821, the rollback count upper limit 831, and the rollback count 832 are included.

【0018】更新状態管理ブロック(UCB)900
は、トランザクションプログラムの資源更新毎に作成さ
れ、各トランザクションプログラムが更新する資源の排
他単位毎の更新状態を管理するための領域である。更新
状態管理ブロック(UCB)900は、図3(d)に示
すように、TCBアドレス911,RCBアドレス92
1,TX内次UCBアドレス931,TX内前UCBア
ドレス932,リソース内次UCBアドレス941,リ
ソース内前UCBアドレス942,作業域アドレス95
1を持つ。
Update state management block (UCB) 900
Is an area for managing the update state of each exclusive unit of the resource updated by each transaction program, which is created each time the resource of the transaction program is updated. The update state management block (UCB) 900 includes a TCB address 911 and an RCB address 92, as shown in FIG.
1, TX next UCB address 931, TX previous UCB address 932, resource next UCB address 941, resource previous UCB address 942, work area address 95
Has 1.

【0019】作業域1000は、図3(e)に示すよう
に、資源の読込みイメージ/更新イメージを格納するた
めに使用され、更新する資源を管理する資源管理ブロッ
ク(RCB)800の管理資源長821で示されるサイ
ズの領域を確保する。
As shown in FIG. 3 (e), the work area 1000 is used to store a read image / update image of a resource, and is a management resource length of a resource management block (RCB) 800 which manages a resource to be updated. An area of the size indicated by 821 is secured.

【0020】次に、このように構成された本発明の排他
ウエイト削減制御方法の処理について説明する。
Next, the processing of the exclusive weight reduction control method of the present invention configured as described above will be described.

【0021】図4(a)は、本発明の第1実施例に係る
排他ウエイト削減制御方法を実現する際の概略動作図で
ある。図4(b)は、第1実施例の排他ウエイト削減制
御方法を実現する際の内部処理概略図である。なお、以
下、トランザクションプログラムをTX1およびTX2
とし、資源をR1とする。また、トランザクション管理
キューをTCQ、トランザクション制御ブロックをTC
B、資源管理ブロックをRCB、更新状態管理ブロック
をUCBと略記するとともに、TCQ,TCB,RC
B,UCBおよび作業域に関係するトランザクションプ
ログラムおよび資源を括弧付きの引数の形で示すことに
する。さらに、トランザクションプログラムTX1およ
びTX2中のTSおよびTEは、トランザクション開始
およびトランザクション終了を意味する。
FIG. 4A is a schematic operation diagram for realizing the exclusive weight reduction control method according to the first embodiment of the present invention. FIG. 4B is a schematic diagram of internal processing when implementing the exclusive weight reduction control method of the first embodiment. Hereinafter, the transaction programs will be referred to as TX1 and TX2.
And the resource is R1. Also, the transaction management queue is TCQ and the transaction control block is TC.
B, the resource management block is abbreviated as RCB, the update state management block is abbreviated as UCB, and TCQ, TCB, RC
The transaction programs and resources associated with B, UCB and the work area will be shown in the form of arguments in parentheses. Further, TS and TE in the transaction programs TX1 and TX2 mean a transaction start and a transaction end.

【0022】トランザクションプログラムTX1が起動
すると、オペレーティングシステムは、TCB(TX
1)700を作成する。トランザクションプログラムT
X1が資源R1を更新すると、資源更新手段200によ
り、UCB(TX1−R1)900および作業域(TX
1−R1)1000が確保され、UCB(TX1−R
1)900のTCBアドレス911にTCB(TX1)
700のアドレス、RCBアドレス921にRCB(R
1)800のアドレス、TX内次UCBアドレス931
およびTX内前UCBアドレス932にNULL、リソ
ース内次UCBアドレス941およびリソース内前UC
Bアドレス942にNULL、作業域アドレス951に
作業域(TX1−R1)1000のアドレスが設定さ
れ、TCB(TX1)700のTX内先頭UCBアドレ
ス721およびTX内最終UCBアドレス722にUC
B(TX1−R1)900のアドレスが設定され、RC
B(R1)800のリソース内先頭UCBアドレス81
1およびリソース内最終UCBアドレス812にUCB
(TX1−R1)900のアドレスが設定される。
When the transaction program TX1 starts, the operating system executes TCB (TX
1) Create 700. Transaction program T
When X1 updates the resource R1, the resource updating means 200 causes the UCB (TX1-R1) 900 and the work area (TX)
1-R1) 1000 is secured and UCB (TX1-R
1) TCB (TX1) at 900 TCB address 911
700, and RCB (R
1) 800 address, TX next UCB address 931
And NULL in the previous UCB address 932 in the TX, the next UCB address 941 in the resource, and the previous UC in the resource
The B address 942 is set to NULL, the work area address 951 is set to the address of the work area (TX1-R1) 1000, and the UC is set to the first UCB address 721 in the TX and the last UCB address 722 in the TX of the TCB (TX1) 700.
B (TX1-R1) 900 is set, and RC
Start UCB address 81 in the resource of B (R1) 800
1 and UCB in the last UCB address 812 in the resource
The address of (TX1-R1) 900 is set.

【0023】また、トランザクションプログラムTX1
の動作とは非同期にトランザクションプログラムTX2
が起動されると、オペレーティングシステムは、TCB
(TX2)700を作成する。トランザクションプログ
ラムTX1が先行して更新している資源R1をトランザ
クションプログラムTX2が更新すると、資源更新手段
200により、UCB(TX2−R1)900および作
業域(TX2−R1)1000が確保され、UCB(T
X2−R1)900のTCBアドレス911にTCB
(TX2)700のアドレス、RCBアドレス921に
RCB(R1)800のアドレス、TX内次UCBアド
レス931およびTX内前UCBアドレス932にNU
LL、リソース内次UCBアドレス941にNULL、
リソース内前UCBアドレス942にUCB(TX1−
R1)900のアドレス、作業域アドレス951に作業
域(TX2−R1)1000のアドレスが設定され、T
CB(TX2)700のTX内先頭UCBアドレス72
1およびTX内最終UCBアドレス722にUCB(T
X2−R1)900のアドレスが設定され、RCB(R
1)800のリソース内最終UCBアドレス812にU
CB(TX2−R1)900のアドレスが設定され、U
CB(TX1−R1)900のリソース内次UCBアド
レス941にUCB(TX2−R1)900のアドレス
が設定される。
The transaction program TX1
Transaction TX2 asynchronously with the operation of
Is started, the operating system
(TX2) 700 is created. When the transaction program TX2 updates the resource R1 previously updated by the transaction program TX1, the resource updating means 200 secures the UCB (TX2-R1) 900 and the work area (TX2-R1) 1000, and the UCB (T
X2-R1) 900 TCB address 911 TCB
(TX2) 700 address, RCB address 921 RCB (R1) 800 address, TX next UCB address 931 and TX previous UCB address 932 NU
LL, NULL in next UCB address 941 in resource,
UCB (TX1-
R1) 900 address and work area address 951 are set to work area (TX2-R1) 1000 address.
First UCB address 72 in TX of CB (TX2) 700
1 and the last UCB address 722 in TX is UCB (T
X2-R1) 900 address is set, and RCB (R
1) U is assigned to the last UCB address 812 in the
The address of CB (TX2-R1) 900 is set, and U
The address of the UCB (TX2-R1) 900 is set to the next UCB address 941 in the resource of the CB (TX1-R1) 900.

【0024】ここで、トランザクションプログラムTX
1のトランザクション終了処理よりも先にトランザクシ
ョンプログラムTX2がトランザクション終了処理を行
う場合、トランザクション終了処理手段300は、UC
B(TX2−R1)900のリソース内前UCBアドレ
ス942がNULLでないことから、先に同一の資源R
1を更新しているトランザクションプログラムTX1の
存在を知り、RCB(R1)800のリソース内先頭U
CBアドレス811のポイントするUCB(TX1−R
1)900のTCBアドレス911がポイントするTC
B(TX1)700のトランザクション終了通知TCB
アドレス751にTCB(TX2)700のアドレスを
設定し、トランザクション終了処理を中断する。
Here, the transaction program TX
When the transaction program TX2 performs the transaction end processing before the transaction end processing of the first transaction, the transaction end processing means 300
B (TX2-R1) 900 because the previous UCB address 942 in the resource is not NULL,
When the existence of the transaction program TX1 updating 1 is known, the first U in the resource of RCB (R1) 800
UCB (TX1-R) pointed to by CB address 811
1) TC pointed to by 900 TCB address 911
B (TX1) 700 transaction end notification TCB
The address of the TCB (TX2) 700 is set to the address 751, and the transaction end processing is interrupted.

【0025】次に、トランザクションプログラムTX1
がトランザクション終了処理手段300によりトランザ
クション終了処理を実施する際、コミット可否判断機能
310によりコミット可否を判断し、コミット可能の場
合には資源コミット手段400のコミット機能410に
より資源R1に対するコミット処理が行われ、管理情報
更新機能420により作業域(TX1−R1)1000
が解放され、RCB(R1)800のリソース内先頭U
CBアドレス811はUCB(TX1−R1)900の
リソース内次UCBアドレス941のポイントするUC
B(TX2−R1)900のアドレスに変更され、UC
B(TX2−R1)900のリソース内前UCBアドレ
ス942はUCB(TX1−R1)900のリソース内
前UCBアドレス942(すなわち、NULL)に変更
され、UCB(TX1−R1)900が解放され、TC
B(TX1)700のトランザクション終了通知TCB
アドレス751のポイントするTCB(TX2)700
に対してロールバックを指示し、トランザクションプロ
グラムTX2はトランザクションディスパッチ手段10
0により再スケジュールされる。
Next, the transaction program TX1
When the transaction end processing means 300 executes the transaction end processing, the commit availability determination function 310 determines whether commit is possible, and if commit is possible, the commit function 410 of the resource commit means 400 performs commit processing for the resource R1. , Work area (TX1-R1) 1000 by the management information update function 420
Is released, and the first U in the resources of the RCB (R1) 800
The CB address 811 is the UC to which the next UCB address 941 in the resource of the UCB (TX1-R1) 900 points.
B (TX2-R1) 900
The prior UCB address 942 in the resource of the B (TX2-R1) 900 is changed to the previous UCB address 942 in the resource of the UCB (TX1-R1) 900 (that is, NULL), the UCB (TX1-R1) 900 is released, and the TC
B (TX1) 700 transaction end notification TCB
TCB (TX2) 700 pointed to by address 751
Is instructed to perform a rollback, and the transaction program TX2
Rescheduled by 0.

【0026】トランザクションプログラムTX1がトラ
ンザクション終了処理手段300によりトランザクショ
ン終了処理を実施しロールバックを行う場合には、資源
ロールバック手段500のロールバック機能510によ
り資源R1に対するロールバック処理が行われ、管理情
報更新機能520により作業域(TX1−R1)100
0が解放され、RCB(R1)800のリソース内先頭
UCBアドレス811はUCB(TX1−R1)900
のリソース内次UCBアドレス941のポイントするU
CB(TX2−R1)900のアドレスに変更され、U
CB(TX2−R1)900のリソース内前UCBアド
レス942はUCB(TX1−R1)900のリソース
内前UCBアドレス942(すなわち、NULL)に変
更され、UCB(TX1−R1)900が解放され、T
CB(TX1)700のトランザクション終了通知TC
Bアドレス751のポイントするTCB(TX2)70
0に対してコミットを指示する。
When the transaction program TX1 performs the transaction end processing by the transaction end processing means 300 and performs rollback, the rollback processing for the resource R1 is performed by the rollback function 510 of the resource rollback means 500, and the management information Work area (TX1-R1) 100 by update function 520
0 is released, and the head UCB address 811 in the resource of the RCB (R1) 800 becomes the UCB (TX1-R1) 900
U to which the next UCB address 941 in the resource of
Changed to the address of CB (TX2-R1) 900, U
The previous UCB address 942 in the resource of the CB (TX2-R1) 900 is changed to the previous UCB address 942 in the resource of the UCB (TX1-R1) 900 (that is, NULL), and the UCB (TX1-R1) 900 is released.
CB (TX1) 700 transaction end notification TC
TCB (TX2) 70 to which B address 751 points
0 is instructed to commit.

【0027】第1実施例の排他ウエイト削減制御方法に
よれば、トランザクションプログラムTX1が資源R1
を更新した後にコミットまたはロールバックによるトラ
ンザクション終了処理を実施していない状態で、トラン
ザクションプログラムTX2が同一の資源R1を更新す
る場合にトランザクションプログラムTX2が排他ウエ
イトすることなく資源R1を更新するようにして、同一
資源R1を更新するトランザクションプログラムTX1
およびTX2の多重走行を実現することができる。
According to the exclusive weight reduction control method of the first embodiment, the transaction program TX1
When the transaction program TX2 updates the same resource R1 in a state where the transaction end process by commit or rollback is not performed after the update, the transaction program TX2 updates the resource R1 without performing the exclusive wait. , A transaction program TX1 for updating the same resource R1
And TX2.

【0028】ところで、第1実施例の排他ウエイト削減
制御方法では、トランザクションプログラムの優先度に
関して何の制御も行っておらず、同一資源を更新したト
ランザクションプログラムの中で最初にトランザクショ
ン終了処理を実施したトランザクションプログラムは正
常に処理される(コミットできる)可能性が高いが、他
のトランザクションプログラムはロールバックする可能
性が高い。このことは、処理時間の短いトランザクショ
ンプログラムはコミットされる可能性が高く、処理時間
の長いトランザクションプログラムはロールバックされ
る可能性が高い(処理時間の長いトランザクションプロ
グラムはなかなか処理されない)ことを意味する。
By the way, in the exclusive weight reduction control method of the first embodiment, no control is performed regarding the priority of the transaction program, and the transaction end processing is first executed in the transaction programs that have updated the same resource. A transaction program is likely to be successfully processed (can commit), while other transaction programs are likely to roll back. This means that a transaction program with a short processing time is likely to be committed, and a transaction program with a long processing time is likely to be rolled back (a transaction program with a long processing time is difficult to process). .

【0029】図5は、本発明の第2実施例に係る排他ウ
エイト削減制御方法を実現する際の概略動作図である。
第2実施例の排他ウエイト削減制御方法では、第1実施
例の排他ウエイト削減制御方法における処理時間の長い
トランザクションプログラムがなかなか処理されないと
いう弊害を解消するために、第1実施例の排他ウエイト
削減制御方法を実現するための概略動作と比較して次の
動作が異なる。
FIG. 5 is a schematic operation diagram for realizing the exclusive weight reduction control method according to the second embodiment of the present invention.
In the exclusive weight reduction control method of the second embodiment, the exclusive weight reduction control of the first embodiment is carried out in order to solve the problem that the transaction program having a long processing time is difficult to process in the exclusive weight reduction control method of the first embodiment. The following operation differs from the general operation for realizing the method.

【0030】トランザクションプログラムTX2がトラ
ンザクション終了処理を行う場合、トランザクション終
了処理手段300は、UCB(TX2−R1)900の
リソース内前UCBアドレス942がNULLでないこ
とから、先に同一の資源R1を更新しているトランザク
ションプログラムTX1の存在を知り、RCB(R1)
800のリソース内先頭UCBアドレス941からポイ
ントされているUCB(TX1−R1)900のTCB
アドレス911がポイントするTCB(TX1)700
のロールバック受付可否731よりロールバック可能を
知り、TCB(TX2)700のロールバック要求有無
732よりロールバック要求を知る。
When the transaction program TX2 performs the transaction end processing, the transaction end processing means 300 updates the same resource R1 first because the previous UCB address 942 in the resource of the UCB (TX2-R1) 900 is not NULL. RCB (R1) knows the existence of the transaction program TX1
TCB of the UCB (TX1-R1) 900 pointed from the head UCB address 941 in the resource 800
TCB (TX1) 700 to which address 911 points
Of the rollback request 731 of the TCB (TX2) 700 and the rollback request of the TCB (TX2) 700.

【0031】トランザクションプログラムTX2のトラ
ンザクション終了処理でコミットする場合には、資源コ
ミット手段400のコミット機能410により資源R1
に対するコミット処理が行われ、管理情報更新機能42
0により作業域(TX2−R1)1000が解放され、
UCB(TX2−R1)900のリソース内前UCBア
ドレス942のポイントするUCB(TX1−R1)9
00のリソース内次UCBアドレス941をUCB(T
X2−R1)900のリソース内次UCBアドレス94
1の値(すなわち、NULL)に変更し、UCB(TX
2−R1)900のリソース内次UCBアドレス941
の値がNULLであるため、RCB(R1)800のリ
ソース内最終UCBアドレス812をUCB(TX2−
R1)900のリソース内前UCBアドレス942の値
に変更し、UCB(TX2−R1)900が解放され、
RCB(R1)800のリソース内先頭UCBアドレス
811のポイントするUCB(TX1−R1)900の
TCBアドレス911のポイントするTCB(TX1)
700に対してロールバックを指示し、トランザクショ
ンディスパッチ手段100によりトランザクションプロ
グラムTX1を再スケジュールする。
When committing in the transaction end processing of the transaction program TX2, the commit function 410 of the resource commit unit 400
Is performed on the management information update function 42
0 frees the work area (TX2-R1) 1000,
UCB (TX1-R1) 9 in the resource of UCB (TX2-R1) 900 that points to the previous UCB address 942
00 next UCB address 941 in the resource of UCB (T
X2-R1) 900 next UCB address in resource 900
Change it to a value of 1 (that is, NULL), and change UCB (TX
2-R1) Next UCB address 941 in the resource of 900
Is NULL, the last UCB address 812 in the resource of the RCB (R1) 800 is changed to the UCB (TX2-
R1) is changed to the value of the previous UCB address 942 in the resource of 900, and the UCB (TX2-R1) 900 is released,
TCB (TX1) to which the TCB address 911 of the UCB (TX1-R1) 900 to which the head UCB address 811 in the resource of the RCB (R1) 800 points
The rollback is instructed to 700, and the transaction dispatch means 100 reschedules the transaction program TX1.

【0032】トランザクションプログラムTX2のトラ
ンザクション終了処理でロールバックする場合には、資
源ロールバック手段500のロールバック機能510に
より資源R1に対するロールバック処理が行われ、管理
情報更新機能520により作業域(TX2−R1)10
00が解放され、UCB(TX2−R1)900のリソ
ース内前UCBアドレス942のポイントするUCB
(TX1−R1)900のリソース内次UCBアドレス
941をUCB(TX2−R1)900のリソース内次
UCBアドレス941の値(すなわち、NULL)に変
更し、UCB(TX2−R1)900のリソース内次U
CBアドレス941の値がNULLであるため、RCB
(R1)800のリソース内最終UCBアドレス812
をUCB(TX2−R1)900のリソース内前UCB
アドレス942の値に変更し、UCB(TX2−R1)
900が解放される。トランザクションプログラムTX
1は、そのまま処理を継続する。
In the case of rolling back by the transaction end processing of the transaction program TX2, the rollback function 510 of the resource rollback means 500 performs the rollback processing for the resource R1, and the management information updating function 520 performs the work area (TX2- R1) 10
00 is released and the UCB pointed to by the previous UCB address 942 in the resource of the UCB (TX2-R1) 900
The next UCB address 941 in the resource of (TX1-R1) 900 is changed to the value of the next UCB address 941 in the resource of the UCB (TX2-R1) 900 (that is, NULL), and the next UCB address in the resource of the UCB (TX2-R1) 900 is changed. U
Since the value of CB address 941 is NULL, RCB
(R1) Last UCB address 812 in resource of 800
Is the previous UCB in the resource of UCB (TX2-R1) 900
Change to the value of address 942 and UCB (TX2-R1)
900 is released. Transaction program TX
1 continues the processing as it is.

【0033】第2実施例の排他ウエイト削減制御方法に
よれば、処理時間の長いためにロールバックされる可能
性の高いトランザクションプログラムTX1においてロ
ールバック受付可否731にロールバック受付不可を設
定しておけば、そのトランザクションプログラムTX1
が更新した資源R1と同一の資源R1を更新しようとす
る他のトランザクションプログラムTX2(処理時間が
短い)が先行してトランザクション終了処理を実施して
も、トランザクションプログラムTX1はロールバック
されずに処理できるという利点がある。また、他のトラ
ンザクションプログラムTX1をロールバックしてまで
も自分のトランザクションプログラムTX2を優先して
実施する必要のない場合には、ロールバック要求有無7
32にロールバック要求無を設定しておけば、他のトラ
ンザクションプログラムTX1の処理を停滞させること
がなくなるという利点がある。
According to the exclusive weight reduction control method of the second embodiment, in the transaction program TX1 which is likely to be rolled back due to the long processing time, it is possible to set the rollback acceptance not possible 731 to the rollback acceptance not possible. If so, the transaction program TX1
, Even if another transaction program TX2 (short processing time) that attempts to update the same resource R1 as the updated resource R1 executes the transaction end processing in advance, the transaction program TX1 can be processed without being rolled back. There is an advantage. If it is not necessary to give priority to the own transaction program TX2 even after rolling back the other transaction program TX1, a rollback request existence 7
If no rollback request is set in 32, there is an advantage that the processing of another transaction program TX1 does not stagnate.

【0034】図6は、本発明の第3実施例に係る排他ウ
エイト削減制御方法を実現する際の概略動作図である。
第3実施例の排他ウエイト削減制御方法では、第2実施
例の排他ウエイト削減制御方法を実現するための概略動
作と比較して次の動作が異なる。
FIG. 6 is a schematic operation diagram for implementing the exclusive weight reduction control method according to the third embodiment of the present invention.
In the exclusive weight reduction control method of the third embodiment, the following operation is different from the schematic operation for realizing the exclusive weight reduction control method of the second embodiment.

【0035】TCB700の作成時に、TCB700の
ロールバック回数上限741には利用者により規定され
た上限値、ロールバック回数742には0が設定され
る。また、トランザクションプログラムがロールバック
されるたびに、TCB700のロールバック回数742
がカウントアップされる。
When the TCB 700 is created, the rollback number upper limit 741 of the TCB 700 is set to an upper limit value defined by the user, and the rollback number 742 is set to 0. Also, each time the transaction program is rolled back, the TCB 700 rolls back 742 times.
Is counted up.

【0036】トランザクションプログラムTX2がトラ
ンザクション終了処理を行う際、トランザクション終了
処理手段300が、TCB(TX2)700のトランザ
クション内先頭UCBアドレス721以降にキューされ
ているトランザクションプログラムTX2が作成した全
てのUCB(TX2−R1)900のリソース内前UC
Bアドレス942のポイントするUCB(TX1−R
1)900のTCBアドレス911のポイントするTC
B(TX1)700のロールバック回数上限741とロ
ールバック回数742とを比較し、ロールバック回数7
42がロールバック回数上限741以上のときにはトラ
ンザクションプログラムTX2はロールバック処理を行
い、トランザクションプログラムTX1は処理を継続
し、トランザクションプログラムTX2はトランザクシ
ョンディスパッチ手段100により再スケジュールされ
る。
When the transaction program TX2 carries out the transaction end processing, the transaction end processing means 300 creates all UCBs (TX2) created by the transaction program TX2 queued after the first UCB address 721 in the transaction of the TCB (TX2) 700. -R1) Previous UC within 900 resources
UCB (TX1-R) pointed to by B address 942
1) TC pointed to by 900 TCB address 911
B (TX1) 700 is compared with rollback frequency upper limit 741 and rollback frequency 742, and rollback frequency 7
When 42 is equal to or greater than the rollback count upper limit 741, the transaction program TX2 performs rollback processing, the transaction program TX1 continues processing, and the transaction program TX2 is rescheduled by the transaction dispatching means 100.

【0037】第3実施例の排他ウエイト削減制御方法に
よれば、トランザクションプログラムTX2がコミット
する際にトランザクションプログラムTX1のロールバ
ック回数742がロールバック回数上限741に達して
いるときには、トランザクションプログラムTX2をロ
ールバックして、トランザクションプログラムTX1の
処理の停滞を防止することができる。
According to the exclusive weight reduction control method of the third embodiment, when the rollback number 742 of the transaction program TX1 reaches the rollback number upper limit 741 when the transaction program TX2 commits, the transaction program TX2 is rolled. By backing up, it is possible to prevent the processing of the transaction program TX1 from becoming stagnant.

【0038】図7は、本発明の第4実施例に係る排他ウ
エイト削減制御方法を実現する際の概略動作図である。
第4実施例の排他ウエイト削減制御方法では、第3実施
例の排他ウエイト削減制御方法を実現するための概略動
作と比較して次の動作が異なる。
FIG. 7 is a schematic operation diagram for implementing the exclusive weight reduction control method according to the fourth embodiment of the present invention.
In the exclusive weight reduction control method of the fourth embodiment, the following operation is different from the schematic operation for realizing the exclusive weight reduction control method of the third embodiment.

【0039】トランザクションプログラムTX2が資源
R1の更新を行う際、資源更新手段200が、更新する
資源R1を管理するRCB(R1)800のリソース内
先頭UCBアドレス811以降にキューされているUC
B(TX1−R1)900のTCBアドレス911のポ
イントするTCB(TX1)700のロールバック回数
上限741とロールバック回数742とを比較し、ロー
ルバック回数742がロールバック回数上限741以上
のときにはトランザクションプログラムTX2はロール
バック処理を行い、トランザクションプログラムTX1
は処理を継続し、トランザクションプログラムTX2は
トランザクションディスパッチ手段100により再スケ
ジュールされる。
When the transaction program TX2 updates the resource R1, the resource updating means 200 transmits the UC queued to the RCB (R1) 800 that manages the resource R1 to be updated after the head UCB address 811 in the resource.
The rollback number upper limit 741 of the TCB (TX1) 700 pointed to by the TCB address 911 of the B (TX1-R1) 900 and the rollback number 742 are compared. When the rollback number 742 is equal to or more than the rollback number upper limit 741, a transaction program TX2 performs rollback processing, and transaction program TX1
Continues the processing, and the transaction dispatcher 100 reschedules the transaction program TX2.

【0040】第4実施例の排他ウエイト削減制御方法に
よれば、第3実施例の排他ウエイト削減制御方法の利点
に加えて、トランザクションプログラムTX2が処理を
継続してもロールバックすることをトランザクション終
了処理を実施する以前の資源R1の更新時に判断するこ
とにより、不要な処理を削減することができる。
According to the exclusive weight reduction control method of the fourth embodiment, in addition to the advantage of the exclusive weight reduction control method of the third embodiment, it is possible to terminate the transaction even if the transaction program TX2 continues processing. Unnecessary processing can be reduced by making a determination at the time of updating the resource R1 before performing the processing.

【0041】図8は、本発明の第5実施例に係る排他ウ
エイト削減制御方法を実現する際の概略動作図である。
第5実施例の排他ウエイト削減制御方法では、第4実施
例の排他ウエイト削減制御方法を実現するための概略動
作と比較して次の動作が異なる。
FIG. 8 is a schematic operation diagram for implementing an exclusive weight reduction control method according to a fifth embodiment of the present invention.
In the exclusive weight reduction control method according to the fifth embodiment, the following operation is different from the general operation for realizing the exclusive weight reduction control method according to the fourth embodiment.

【0042】トランザクションプログラムTX2が資源
R1の更新を行う際、資源更新手段200が、更新する
資源R1を管理するRCB(R1)800のリソース内
先頭UCBアドレス811以降にキューされているUC
B(TX1−R1)900のTCBアドレス911のポ
イントするTCB(TX1)700のロールバック回数
上限741とロールバック回数742とを比較し、ロー
ルバック回数742がロールバック回数上限741以上
のときにはUCB(TX1−R1)900のTCBアド
レス911のポイントするTCB(TX1)700のト
ランザクション終了通知TCBアドレス751にTCB
(TX2)700のアドレスを設定し、トランザクショ
ンプログラムTX2はロールバック処理を行い、トラン
ザクションプログラムTX1は処理を継続し、この時点
ではトランザクションプログラムTX2は再スケジュー
ルされない。
When the transaction program TX2 updates the resource R1, the resource updating means 200 sets the UC queued after the first UCB address 811 in the resource of the RCB (R1) 800 managing the resource R1 to be updated.
The rollback number upper limit 741 of the TCB (TX1) 700 pointed to by the TCB address 911 of the B (TX1-R1) 900 and the rollback number 742 are compared, and when the rollback number 742 is equal to or more than the rollback number upper limit 741, Transaction end notification of TCB (TX1) 700 pointed to by TCB address 911 of TX1-R1) 900 TCB at TCB address 751
(TX2) The address of 700 is set, the transaction program TX2 performs rollback processing, the transaction program TX1 continues processing, and the transaction program TX2 is not rescheduled at this time.

【0043】次に、トランザクションプログラムTX1
がトランザクション終了処理を行う際、トランザクショ
ン終了処理手段300が、TCB(TX1)700のト
ランザクション終了通知TCBアドレス751のポイン
トするTCB(TX2)700のアドレスをトランザク
ションディスパッチ手段100に通知することによりト
ランザクションプログラムTX2を再スケジュールす
る。
Next, the transaction program TX1
When the transaction termination processing is performed by the transaction termination processing means 300, the transaction termination processing means 300 notifies the transaction dispatch means 100 of the address of the TCB (TX2) 700 pointed to by the transaction termination notification TCB address 751 of the TCB (TX1) 700. To reschedule.

【0044】第5実施例の排他ウエイト削減制御方法に
よれば、トランザクションプログラムTX2が再びトラ
ンザクションプログラムTX1のロールバック回数上限
741のためにロールバックするような不要な処理を削
減することができる。
According to the exclusive weight reduction control method of the fifth embodiment, unnecessary processing in which the transaction program TX2 rolls back again due to the rollback frequency upper limit 741 of the transaction program TX1 can be reduced.

【0045】図9は、本発明の第6実施例に係る排他ウ
エイト削減制御方法を実現する際の概略動作図である。
第6実施例の排他ウエイト削減制御方法では、第2実施
例の排他ウエイト削減制御方法を実現するための概略動
作と比較して次の動作が異なる。
FIG. 9 is a schematic operation diagram for realizing the exclusive weight reduction control method according to the sixth embodiment of the present invention.
In the exclusive weight reduction control method of the sixth embodiment, the following operation is different from the general operation for realizing the exclusive weight reduction control method of the second embodiment.

【0046】RCB800の作成時に、RCB800の
ロールバック回数上限831には利用者が規定した上限
値が設定され、ロールバック回数832には0が設定さ
れ、トランザクションプログラムTX1がロールバック
される際には、ロールバック原因である資源R1を管理
するRCB800のロールバック回数832がカウント
アップされ、オペレーティングシステムは単位時間毎に
起動されるタイマタスクを用意し、タイマタスクはメモ
リ上に存在する全てのRCB800のロールバック回数
832を0クリアする。
When the RCB 800 is created, an upper limit specified by the user is set in the rollback frequency upper limit 831 of the RCB800, 0 is set in the rollback frequency 832, and when the transaction program TX1 is rolled back. The number of rollbacks 832 of the RCB 800 that manages the resource R1 that is the cause of the rollback is counted up, and the operating system prepares a timer task that is activated every unit time. The rollback count 832 is cleared to zero.

【0047】トランザクションプログラムTX2は、資
源R1を更新する際に、資源更新手段200によりRC
B(R1)800のロールバック回数上限831とロー
ルバック回数832とを比較し、ロールバック回数83
2がロールバック回数上限831以上のときにはUCB
(TX2−R1)900を作成せず、RCB(R1)8
00のリソース内先頭UCBアドレス811のポイント
するUCB(TX1−R1)900のTCBアドレス9
11がポイントするTCB(TX1)700のトランザ
クション終了通知TCBアドレス751にTCB(TX
2)700のアドレスを設定した後、トランザクション
ディスパッチ手段100によりトランザクションプログ
ラムTX2を排他ウエイトさせる。
When updating the resource R1, the transaction program TX2 uses RC by the resource updating means 200.
The rollback number upper limit 831 of B (R1) 800 and the rollback number 832 are compared, and the rollback number 83
UCB when 2 is equal to or greater than the upper limit of rollback times 831
Without creating (TX2-R1) 900, RCB (R1) 8
TCB address 9 of UCB (TX1-R1) 900 pointed to by the first UCB address 811 in the resource 00
The transaction end notification TCB address 751 of the TCB (TX1) 700 to which
2) After setting the address of 700, the transaction dispatch means 100 causes the transaction program TX2 to have an exclusive wait.

【0048】トランザクションプログラムTX1は、ト
ランザクション終了処理手段300により、TCB(T
X1)700のトランザクション終了通知TCBアドレ
ス751のポイントするTCB(TX2)700のアド
レスをトランザクションディスパッチ手段100に通知
することによりトランザクションプログラムTX2の排
他ウエイトを解除し処理を再開させる。
The transaction program TX1 is transmitted by the transaction end processing means 300 to TCB (T
X1) Notifying the transaction dispatching means 100 of the address of the TCB (TX2) 700 to which the transaction end notification TCB address 751 of the transaction 700 points, releases the exclusive wait of the transaction program TX2 and restarts the processing.

【0049】第6実施例の排他ウエイト削減制御方法に
よれば、資源R1の同時更新の発生時に単位時間あたり
のロールバック回数832がロールバック回数上限83
1に達しているときには、後から資源R1を更新するト
ランザクションプログラムTX2を排他ウエイトさせる
ことにより、トランザクションプログラムTX1の処理
の停滞を防止することができる。
According to the exclusive weight reduction control method of the sixth embodiment, the number of rollbacks 832 per unit time is 8
When the number reaches 1, the transaction program TX2, which updates the resource R1 later, is placed in an exclusive wait state, whereby the processing delay of the transaction program TX1 can be prevented.

【0050】[0050]

【発明の効果】以上説明したように本発明は、第1のト
ランザクションプログラムが資源を更新した後にトラン
ザクション終了処理を実施していない状態で、第2のト
ランザクションプログラムが同一の資源を更新する場合
に第2のトランザクションプログラムが排他ウエイトす
ることなく資源を更新するようにしたことにより、複数
のトランザクションプログラムが同一の資源に更新する
際の排他ウエイトを削減することができ、トランザクシ
ョンプログラムの処理効率を向上させることができると
いう効果がある。
As described above, according to the present invention, when the second transaction program updates the same resource in a state where the transaction termination processing is not executed after the first transaction program updates the resource. Since the second transaction program updates the resource without performing the exclusive weight, it is possible to reduce the exclusive weight when a plurality of transaction programs update the same resource, and improve the processing efficiency of the transaction program. The effect is that it can be done.

【図面の簡単な説明】[Brief description of drawings]

【図1】本発明に係る排他ウエイト削減制御方法を実現
するオペレーティングシステムの構成を示すブロック図
である。
FIG. 1 is a block diagram showing a configuration of an operating system for realizing an exclusive weight reduction control method according to the present invention.

【図2】本発明の排他ウエイト削減制御方法の実現手段
の構成図である。
FIG. 2 is a configuration diagram of a means for realizing the exclusive weight reduction control method of the present invention.

【図3】本発明の排他ウエイト削減制御方法で用いられ
る管理情報の構成を示す図であり、(a)はトランザク
ション管理キュー、(b)はトランザクション制御ブロ
ック、(c)は資源管理ブロック、(d)は更新状態管
理ブロックの内容をそれぞれ示す。
FIG. 3 is a diagram showing a configuration of management information used in the exclusive weight reduction control method of the present invention, where (a) is a transaction management queue, (b) is a transaction control block, and (c) is a resource management block. Each of d) shows the contents of the update state management block.

【図4】(a)は第1実施例に係る排他ウエイト削減制
御方法を実現する際の概略動作図、(b)は第1実施例
の排他ウエイト削減制御方法を実現する際の内部処理概
略図である。
FIG. 4A is a schematic operation diagram when the exclusive weight reduction control method according to the first embodiment is realized, and FIG. 4B is a schematic internal process when the exclusive weight reduction control method according to the first embodiment is realized. FIG.

【図5】本発明の第2実施例に係る排他ウエイト削減制
御方法を実現する際の概略動作図である。
FIG. 5 is a schematic operation diagram when realizing the exclusive weight reduction control method according to the second embodiment of the present invention.

【図6】本発明の第3実施例に係る排他ウエイト削減制
御方法を実現する際の概略動作図である。
FIG. 6 is a schematic operation diagram when implementing an exclusive weight reduction control method according to a third embodiment of the present invention.

【図7】本発明の第4実施例に係る排他ウエイト削減制
御方法を実現する際の概略動作図である。
FIG. 7 is a schematic operation diagram when implementing an exclusive weight reduction control method according to a fourth embodiment of the present invention.

【図8】本発明の第5実施例に係る排他ウエイト削減制
御方法を実現する際の概略動作図である。
FIG. 8 is a schematic operation diagram when implementing an exclusive weight reduction control method according to a fifth embodiment of the present invention.

【図9】本発明の第6実施例に係る排他ウエイト削減制
御方法を実現する際の概略動作図である。
FIG. 9 is a schematic operation diagram when implementing an exclusive weight reduction control method according to a sixth embodiment of the present invention.

【符号の説明】[Explanation of symbols]

100 トランザクションディスパッチ手段 200 資源更新手段 210 資源更新機能 220 管理情報更新機能 300 トランザクション終了処理手段 310 コミット可否判断機能 400 資源コミット手段 410 コミット機能 420 管理情報更新機能 500 資源ロールバック手段 510 ロールバック機能 520 管理情報更新機能 600 トランザクション管理キュー(TCQ) 611 実行中TCB先頭アドレス 612 実行中TCB最終アドレス 621 実行可能TCB先頭アドレス 622 実行可能TCB最終アドレス 631 ウエイト中TCB先頭アドレス 632 ウエイト中TCB最終アドレス 700 トランザクション制御ブロック(TCB) 711 次TCBアドレス 712 前TCBアドレス 721 TX内先頭UCBアドレス 722 TX内最終UCBアドレス 731 ロールバック受付可否 732 ロールバック要求有無 741 ロールバック回数上限 742 ロールバック回数 751 トランザクション終了通知TCBアドレス 800 資源管理ブロック(RCB) 811 リソース内先頭UCBアドレス 812 リソース内最終UCBアドレス 821 管理資源長 831 ロールバック回数上限 832 ロールバック回数 900 更新状態管理ブロック(UCB) 911 TCBアドレス 921 RCBアドレス 931 TX内次UCBアドレス 932 TX内前UCBアドレス 941 リソース内次UCBアドレス 942 リソース内前UCBアドレス 951 作業域アドレス 1000 作業域 REFERENCE SIGNS LIST 100 transaction dispatch means 200 resource update means 210 resource update function 220 management information update function 300 transaction end processing means 310 commit possibility determination function 400 resource commit means 410 commit function 420 management information update function 500 resource rollback means 510 rollback function 520 management Information update function 600 Transaction management queue (TCQ) 611 TCB start address during execution 612 TCB end address during execution 621 Executable TCB start address 622 Executable TCB end address 631 TCB start address during wait 632 TCB last address during wait 700 Transaction control block (TCB) 711 Next TCB address 712 Previous TCB address 721 First UCB address in TX 722 The last UCB address in TX 731 Rollback acceptability 732 Rollback request availability 741 Rollback count upper limit 742 Rollback count 751 Transaction end notification TCB address 800 Resource management block (RCB) 811 First UCB address in resource 812 Last UCB in resource Address 821 Management resource length 831 Rollback count upper limit 832 Rollback count 900 Update state management block (UCB) 911 TCB address 921 RCB address 931 TX next UCB address 932 TX previous UCB address 941 Resource next UCB address 942 Resource previous UCB address 951 Work area address 1000 Work area

Claims (6)

【特許請求の範囲】[Claims] 【請求項1】 第1のトランザクションプログラムが資
源を更新した後、まだコミットまたはロールバックによ
るトランザクション終了処理を実施していない状態で、
第2のトランザクションプログラムが同一の資源を更新
する場合において、 前記第2のトランザクションプログラムが前記資源の更
新時に排他ウエイトすることなく前記資源を更新し、 前記第2のトランザクションプログラムが前記第1のト
ランザクションプログラムよりも先行してトランザクシ
ョン終了処理を実施する場合には、前記第1のトランザ
クションプログラムのトランザクション終了処理が完了
するまで前記第2のトランザクションプログラムのトラ
ンザクション終了処理を待ち合わせ、前記第1のトラン
ザクションプログラムがコミットしたときには前記第2
のトランザクションプログラムがロールバックし、前記
第1のトランザクションプログラムがロールバックした
ときには前記第2のトランザクションプログラムがコミ
ットし、 前記第1のトランザクションプログラムが前記第2のト
ランザクションプログラムより先行してトランザクショ
ン終了処理を実施する場合には、前記第1のトランザク
ションプログラムがコミットしたときには前記第2のト
ランザクションプログラムが即座にロールバックし、前
記第1のトランザクションプログラムがロールバックし
たときには前記第2のトランザクションプログラムが処
理を継続することにより、 同一資源を更新するトランザクションプログラムの多重
走行を実現することを特徴とする排他ウエイト削減制御
方法。
1. After the first transaction program has updated the resource, the transaction end processing by commit or rollback has not been executed yet,
When the second transaction program updates the same resource, the second transaction program updates the resource without exclusive wait when updating the resource, and the second transaction program updates the first transaction. When the transaction end processing is executed prior to the program, the transaction end processing of the second transaction program is waited until the transaction end processing of the first transaction program is completed, and the first transaction program When you commit, the second
When the first transaction program rolls back and the first transaction program rolls back, the second transaction program commits, and the first transaction program performs a transaction end process prior to the second transaction program. In the case of execution, when the first transaction program commits, the second transaction program immediately rolls back, and when the first transaction program rolls back, the second transaction program continues processing. The exclusive weight reduction control method is characterized by realizing multiple runs of a transaction program that updates the same resource by performing the same.
【請求項2】 前記第2のトランザクションプログラム
が前記第1のトランザクションプログラムよりも先行し
てトランザクション終了処理を実施する場合において、
利用者がトランザクションプログラム毎にロールバック
受付可否とロールバック要求有無とを規定することによ
り、ロールバック要求有りの前記第2のトランザクショ
ンプログラムがロールバック受付可能の前記第1のトラ
ンザクションプログラムのトランザクション終了処理ま
で待ち合わせずにトランザクション終了処理を実施し、
前記第2のトランザクションプログラムがコミットした
ときには前記第1のトランザクションプログラムが即座
にロールバックし、前記第2のトランザクションプログ
ラムがロールバックしたときには前記第1のトランザク
ションプログラムが処理を継続することにより、同一資
源に更新するトランザクションプログラムの多重走行を
実現する請求項1記載の排他ウエイト削減制御方法。
2. In a case where the second transaction program performs a transaction end process prior to the first transaction program,
The user defines whether rollback can be accepted and whether or not there is a rollback request for each transaction program, so that the second transaction program with a rollback request can execute the rollback transaction with the first transaction program. Perform the transaction end processing without waiting until
When the second transaction program commits, the first transaction program immediately rolls back, and when the second transaction program rolls back, the first transaction program continues processing. 2. The exclusive weight reduction control method according to claim 1, wherein multiple running of a transaction program to be updated is realized.
【請求項3】 前記第2のトランザクションプログラム
のコミットにより前記第1のトランザクションプログラ
ムがロールバックする場合のロールバック回数の上限を
利用者がトランザクションプログラム毎に規定するとと
もに前記第1のトランザクションプログラムの起動後に
ロールバックした回数をカウントし、前記第2のトラン
ザクションプログラムがコミットする際に前記第1のト
ランザクションプログラムのロールバック回数がトラン
ザクションプログラム毎に規定された上限に達している
ときには前記第2のトランザクションプログラムをロー
ルバックして、前記第1のトランザクションプログラム
の処理の停滞を防止する請求項2記載の排他ウエイト削
減制御方法。
3. The user defines an upper limit of the number of rollbacks for each transaction program when the first transaction program rolls back by committing the second transaction program, and activates the first transaction program. The number of rollbacks is counted later, and when the number of rollbacks of the first transaction program reaches an upper limit defined for each transaction program when the second transaction program commits, the second transaction program 3. The exclusive weight reduction control method according to claim 2, wherein the first transaction program is rolled back to prevent stagnation of the processing of the first transaction program.
【請求項4】 前記第2のトランザクションプログラム
が前記資源を更新する際に前記第1のトランザクション
プログラムのロールバック回数がトランザクションプロ
グラム毎に規定された上限に達している場合には前記第
2のトランザクションプログラムをロールバックして前
記第1のトランザクションプログラムの処理の停滞を防
止することに加えて、前記第2のトランザクションプロ
グラムが処理を継続してもロールバックすることをトラ
ンザクション終了処理を実施する以前の資源の更新時に
判断することにより不要な処理を削減することを特徴と
する請求項3記載の排他ウエイト削減制御方法。
4. The second transaction when the number of rollbacks of the first transaction program reaches the upper limit specified for each transaction program when the second transaction program updates the resource. In addition to rolling back the program to prevent stagnation of the processing of the first transaction program, rolling back even if the second transaction program continues processing is performed before performing the transaction end processing. 4. The exclusive weight reduction control method according to claim 3, wherein unnecessary processing is reduced by making a determination when updating resources.
【請求項5】 前記第1のトランザクションプログラム
のロールバック回数が上限に達しているためにロールバ
ックした前記第2のトランザクションプログラムをロー
ルバック直後に再スケジュールせず、前記第1のトラン
ザクションプログラムがトランザクション終了処理を実
施するまで前記第2のトランザクションプログラムの再
スケジュールを保留することにより、前記第2のトラン
ザクションプログラムが再び前記第1のトランザクショ
ンプログラムのロールバック回数の上限のためにロール
バックするような不要な処理を削減することを特徴とす
る請求項3または4記載の排他ウエイト削減制御方法。
5. The rescheduling of the second transaction program, which has been rolled back because the number of rollbacks of the first transaction program has reached the upper limit, is not performed immediately after the rollback. By suspending the rescheduling of the second transaction program until the end processing is performed, there is no need for the second transaction program to roll back again due to the upper limit of the number of rollbacks of the first transaction program. The exclusive weight reduction control method according to claim 3 or 4, wherein a complicated process is reduced.
【請求項6】 単位時間あたりのロールバック回数の上
限を利用者が規定するとともに、排他単位毎に単位時間
あたりの当該資源の同時更新に起因するロールバック回
数をカウントし、同時更新の発生時に単位時間あたりの
ロールバック回数が上限に達しているときには、後から
資源を更新する前記第2のトランザクションプログラム
を排他ウエイトさせることにより、前記第1のトランザ
クションプログラムの処理の停滞を防止する請求項1ま
たは2記載の排他ウエイト削減制御方法。
6. The user defines the upper limit of the number of rollbacks per unit time, counts the number of rollbacks caused by the simultaneous update of the resource per unit time for each exclusion unit, and when the simultaneous update occurs, When the number of rollbacks per unit time has reached the upper limit, exclusive waiting of the second transaction program that updates the resource later prevents the stagnation of the processing of the first transaction program. Alternatively, the exclusive weight reduction control method described in 2.
JP7059864A 1995-02-23 1995-02-23 Exclusive weight reduction control method Expired - Fee Related JP2654612B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP7059864A JP2654612B2 (en) 1995-02-23 1995-02-23 Exclusive weight reduction control method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP7059864A JP2654612B2 (en) 1995-02-23 1995-02-23 Exclusive weight reduction control method

Publications (2)

Publication Number Publication Date
JPH08235047A true JPH08235047A (en) 1996-09-13
JP2654612B2 JP2654612B2 (en) 1997-09-17

Family

ID=13125477

Family Applications (1)

Application Number Title Priority Date Filing Date
JP7059864A Expired - Fee Related JP2654612B2 (en) 1995-02-23 1995-02-23 Exclusive weight reduction control method

Country Status (1)

Country Link
JP (1) JP2654612B2 (en)

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2000284978A (en) * 1999-03-25 2000-10-13 Internatl Business Mach Corp <Ibm> Interface system for asynchronously updating common resource and method for the same
JP2002521766A (en) * 1998-07-30 2002-07-16 テルコーディア テクノロジーズ インコーポレイテッド Method and system for arbitrating streams of concurrent transactions in a database
US6502122B1 (en) 1997-09-04 2002-12-31 Nec Corporation Method and apparatus for executing transaction programs in parallel
WO2004109503A3 (en) * 2003-06-04 2006-03-30 Sap Ag System and method for asynchronous resource management
JP2015118431A (en) * 2013-12-17 2015-06-25 日本電気株式会社 Transaction processing system
JP2018522347A (en) * 2015-07-10 2018-08-09 アビニシオ テクノロジー エルエルシー Method and architecture for providing database access control in a network using a distributed database system

Cited By (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6502122B1 (en) 1997-09-04 2002-12-31 Nec Corporation Method and apparatus for executing transaction programs in parallel
JP2002521766A (en) * 1998-07-30 2002-07-16 テルコーディア テクノロジーズ インコーポレイテッド Method and system for arbitrating streams of concurrent transactions in a database
JP2000284978A (en) * 1999-03-25 2000-10-13 Internatl Business Mach Corp <Ibm> Interface system for asynchronously updating common resource and method for the same
WO2004109503A3 (en) * 2003-06-04 2006-03-30 Sap Ag System and method for asynchronous resource management
JP2015118431A (en) * 2013-12-17 2015-06-25 日本電気株式会社 Transaction processing system
JP2018522347A (en) * 2015-07-10 2018-08-09 アビニシオ テクノロジー エルエルシー Method and architecture for providing database access control in a network using a distributed database system
US10489362B2 (en) 2015-07-10 2019-11-26 Ab Initio Technology Llc Distributed database system
US10671576B2 (en) 2015-07-10 2020-06-02 Ab Initio Technology Llc Distributed database system

Also Published As

Publication number Publication date
JP2654612B2 (en) 1997-09-17

Similar Documents

Publication Publication Date Title
US6006247A (en) Method and system for scheduling threads and handling exceptions within a multiprocessor data processing system
US5390329A (en) Responding to service requests using minimal system-side context in a multiprocessor environment
US8200765B2 (en) Preserving message order using a message ordering manager
JPH1185544A (en) Transaction program parallel execution method and system therefor
CN111651865B (en) Event centralized emission type simulation execution method and system for parallel discrete events
KR20130041540A (en) Method and apparatus for providing remote procedure call service using coroutine
JPH08235047A (en) Exclusive wait reduction control method
US9367326B2 (en) Multiprocessor system and task allocation method
JP2636722B2 (en) Multitask execution management method
JPH07141208A (en) Multitask processor
JP3027526B2 (en) Job scheduling method
US7240349B2 (en) Persistent messaging in a transaction processing environment
JP2001282560A (en) Virtual computer control method, its performing device and recording medium recording its processing program
JP3123714B2 (en) Task scheduling method and recording medium
JP2002259143A (en) Device and method for automatically controlling number of task, on-like transaction processing system and program
JPH08314740A (en) Process dispatch method
JPH0594313A (en) Timer control system
JPH07191864A (en) Scheduling method for server process or thread
JPS62226236A (en) Intermission and restart processing system for state waiting resources in transaction processing system
JPH05257792A (en) Method and device for accessing common data
JPH03182937A (en) Task control device for multi-task system
JPS62113260A (en) Timer monitor control system for multi-cpu system
JPH0877029A (en) Processing request execution order control system based upon load rate
JPH0736754A (en) Dynamic transaction resource update system
JPS6125249A (en) Exclusive control system

Legal Events

Date Code Title Description
LAPS Cancellation because of no payment of annual fees