JP2016081126A - Job control language automatic generation program - Google Patents
Job control language automatic generation program Download PDFInfo
- Publication number
- JP2016081126A JP2016081126A JP2014209141A JP2014209141A JP2016081126A JP 2016081126 A JP2016081126 A JP 2016081126A JP 2014209141 A JP2014209141 A JP 2014209141A JP 2014209141 A JP2014209141 A JP 2014209141A JP 2016081126 A JP2016081126 A JP 2016081126A
- Authority
- JP
- Japan
- Prior art keywords
- job
- job flow
- output
- file
- control language
- 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.)
- Pending
Links
Images
Landscapes
- Stored Programmes (AREA)
Abstract
Description
本発明は、汎用機が使用するジョブ制御言語を自動生成する技術に関する。 The present invention relates to a technique for automatically generating a job control language used by a general-purpose machine.
ジョブ制御言語(JCL)は、汎用機(メインフレーム)において、ジョブの内容や使用する装置の名称などをコンピュータに対して指定する、ジョブ制御用のスクリプト言語である。ジョブ制御言語は、マニュアル作業によって記述することもできるし、専用の編集ソフトウェアなどを用いて作成することもできる。 The job control language (JCL) is a script language for job control that specifies, for a computer, the contents of a job and the name of a device to be used in a general purpose machine (mainframe). The job control language can be described manually or can be created using dedicated editing software.
下記特許文献1は、ジョブフローおよびJCLを作成する技術について記載している。同文献においては、画面上でジョブフロー部品を接続し、ジョブ属性などを入力することにより、その入力に準じたJCLを生成している。
The following
上記特許文献1記載の技術においては、画面上で作成したジョブフロー図にしたがってJCLを作成している(例えば同文献の図12)。しかしこのとき生成されるJCLは、ジョブフロー図の内容については反映されていると考えられるものの、個々の具体的な制御文については何らかの規則にしたがって固定的に作成されるものであると思われる。
In the technique described in
したがって同文献においては、生成されたJCLの個々の制御文が例えば実環境におけるパラメータなどに合致していない場合は、生成されたJCLを開発者がマニュアル作業により修正しなければならないと考えられる。具体的には、汎用機の機種が変更されるとJCL上の様々なパラメータをこれに併せて変更する必要があるが、引用文献1記載の技術はそのような変更に対して柔軟に対処することは困難である。
Therefore, in this document, when individual control statements of the generated JCL do not match, for example, parameters in the real environment, it is considered that the generated JCL must be corrected manually by the developer. Specifically, when the model of the general-purpose machine is changed, it is necessary to change various parameters on the JCL along with this, but the technique described in the cited
本発明は、上記のような課題に鑑みてなされたものであり、JCLを生成する作業負担を軽減しつつ、生成するJCLを柔軟に調整することができる技術を提供することを目的とする。 The present invention has been made in view of the above problems, and an object of the present invention is to provide a technique capable of flexibly adjusting the generated JCL while reducing the work load of generating the JCL.
本発明に係るジョブ制御言語自動生成プログラムは、JCLのテンプレートをジョブフロー部品毎に記述したルールファイルを読み込み、ジョブフロー図に対してそのテンプレートを適用することにより、JCLを自動生成する。 The job control language automatic generation program according to the present invention automatically generates JCL by reading a rule file in which a JCL template is described for each job flow component and applying the template to a job flow diagram.
本発明に係るジョブ制御言語自動生成プログラムによれば、自動生成するJCLを柔軟にカスタマイズすることができる。 According to the job control language automatic generation program according to the present invention, the automatically generated JCL can be flexibly customized.
<実施の形態1>
図1は、本発明の実施形態1に係るジョブ制御言語(JCL)自動生成プログラム120を実行するコンピュータ100の構成図である。コンピュータ100は、JCLを自動生成する処理を実行するコンピュータであり、CPU(Central Processing Unit)110、JCL自動生成プログラム120、記憶部130を備える。
<
FIG. 1 is a configuration diagram of a
CPU110は、プログラムを実行するプロセッサである。以下では記載の便宜上、プログラムを動作主体として説明する場合があるが、実際にプログラムを実行するのはCPU110である。
The
JCL自動生成プログラム120は、ジョブフローファイル131とルールファイル132を入力として読み込み、ジョブ制御ファイル133を出力として生成する。JCL自動生成プログラム120の具体的な動作については後述する。
The JCL
記憶部130は、ハードディスク装置などの記憶装置である。JCL自動生成プログラム120は、記憶部130に格納することもできるしその他適当な記憶装置に格納することもできる。
The
記憶部130は、ジョブフローファイル131、ルールファイル132、ジョブ制御ファイル133を格納する。これらファイルの具体例については後述する。
The
図2Aは、ジョブフローファイル131が記述しているジョブフロー図(前半部分)の例である。ジョブフローファイル131は、適当な図面作成ソフトウェアによって作成した図面データファイルであり、図2Aに例示するようなジョブフロー図を記述している。ジョブフロー図は、ジョブフロー部品を矢印で接続することによって記述することができる。各ジョブフロー部品の中には、後述する属性値が記述されている。
FIG. 2A is an example of a job flow diagram (first half) described by the
ジョブフローは、プロセス、プロセスに対する入力、およびプロセスからの出力によって構成されるステップを組み合わせることにより形成することができる。説明の便宜上、図2Aに示すジョブフローを、2つのステップSTEP0010とSTEP0020に分けて示した。各ステップは、それぞれ上記構成を有する。 A job flow can be formed by combining steps composed of a process, inputs to the process, and outputs from the process. For convenience of explanation, the job flow shown in FIG. 2A is divided into two steps STEP0010 and STEP0020. Each step has the above-described configuration.
STEP0010において、プロセスSORT53は入力されたデータをソートするプロセスであり、2つのデータセットAA001(0)とSORT.AA001を入力として受け取り、処理結果として1つのデータセット&&AA001を出力する。 In STEP0010, a process SORT 53 is a process for sorting input data, and two data sets AA001 (0) and SORT. AA001 is received as an input, and one data set && AA001 is output as a processing result.
各データセットを表すジョブフロー部品内には、そのデータセットの属性を記述することができる。 An attribute of the data set can be described in the job flow component representing each data set.
データセットAA001(0)は、レコード長500BYTEであり、最大レコード件数は200000件であり、DD名はSORTINである。なお括弧()内の数字は世代番号であり、当該データセットが世代管理される(すなわちデータを更新するときは新たな世代番号が割り振られる)ことを示している。データセットSORT.AA001は、SYSINデータセットである。 Data set AA001 (0) has a record length of 500 BYTE, the maximum number of records is 200000, and the DD name is SORTIN. The numbers in parentheses () are generation numbers, which indicate that the data set is generation-managed (that is, a new generation number is assigned when data is updated). Data set SORT. AA001 is a SYSIN data set.
データセット&&AA001は、DD名がSORTOUTであり、レコード長と最大レコード件数はデータセットAA001(0)と同じである。アスタリスク*は、当該データセットが別のプロセスの入力として引き渡されることを示している。*の次のHEB5401Iは、次のプロセスがデータセット&&AA001を入力として受け取るとき用いるDD名である。 Data set && AA001 has the DD name SORTOUT, and the record length and the maximum number of records are the same as data set AA001 (0). An asterisk * indicates that the data set is delivered as input for another process. The HEB 5401I next to * is a DD name used when the next process receives the data set && AA001 as an input.
STEP0020において、プロセスMEBPC30はバッチプロセス(SORT以外の一般的なプログラム)であり、プロセスSORT53の出力とともに、データセットBB001を入力として受け取る。データセットBB001は、プロセスから出力されたものではなく、記憶装置上に格納されている既存データファイルである。データセットBB001のDD名は、*HEB5402Iである。プロセスMEBPC30は出力として、2つのデータセット&&BB0011と&&BB0012を出力する。各データセットの属性は図2A記載の通りである。 In STEP0020, the process MEBPC 30 is a batch process (a general program other than SORT), and receives the data set BB001 as an input together with the output of the process SORT 53. Data set BB001 is not an output from the process but an existing data file stored on the storage device. The DD name of the data set BB001 is * HEB5401I. The process MEBPC 30 outputs two data sets && BB0011 and && BB0012 as outputs. The attributes of each data set are as described in FIG. 2A.
図2A末尾に配置されている結合子1と2は、その先のジョブフローが同じ番号の結合子に続いていることを示す。
The
図2Bは、ジョブフローファイル131が記述しているジョブフロー図(後半部分)の例である。図2Bは、図2Aに示すジョブフローの続きを示す。図2Aと同様に、プロセスとその入出力をセットにして、2つのステップSTEP0030とSTEP0040に分けて示した。
FIG. 2B is an example of a job flow diagram (second half) described by the
STEP0030内のプロセスMEBPC35は、結合子1から続くデータセット&&BB0011を入力として受け取る。STEP0040内のプロセスMEBPC40は、プロセスMEBPC35が出力するデータセット&&BB0013と、結合子2から続くデータセット&&BB0012とを入力として受け取り、2つのデータセットAA001(+1)とBB003を出力する。
The process MEBPC 35 in STEP0030 receives the data set && BB0011 from the
データセットAA001(+1)の括弧()内に記述している+1は、データセットAA001の世代番号を1つ増やすことを示している。なおOR記号類似のジョブフロー部品はハードディスクを表し、円の右下に引き出しが付与されたジョブフロー部品はテープデバイスを表している。 +1 described in parentheses () of data set AA001 (+1) indicates that the generation number of data set AA001 is incremented by one. A job flow component similar to the OR symbol represents a hard disk, and a job flow component with a drawer attached to the lower right of the circle represents a tape device.
図3Aは、図2A〜図2Bで説明したジョブフローを記述したジョブ制御言語の開始部分を示す図である。以下図3Aの各部について説明する。 FIG. 3A is a diagram showing a start portion of a job control language describing the job flow described in FIGS. 2A to 2B. Hereinafter, each part of FIG. 3A will be described.
JCLは、冒頭に開始宣言を記述する必要がある。開始宣言において、ジョブ名(JEBMP99)、クラス名(C)、ユーザ名(USER00)を記述する必要がある。これらについては後述のルールファイル132の説明において改めて述べる。
JCL needs to describe the start declaration at the beginning. In the start declaration, it is necessary to describe the job name (JEBMP99), class name (C), and user name (USER00). These will be described again in the description of the
汎用機においては、プロセスから出力されるデータファイルが既に記憶装置上に存在している場合、プロセスがエラー終了する(ただし汎用機の仕様に依拠する)。そこでジョブフローが最終的に出力するデータセットは、当該ジョブフローを開始する前に削除しておく必要がある。この処理を事前削除などと呼ぶ。図2Bで説明したジョブフローにおいては、データセットAA001()は世代管理ファイルであるため事前削除する必要はないが、データセットBB003は事前削除する必要がある。したがってDELETE文によりデータセットBB003を削除している。 In a general-purpose machine, if the data file output from the process already exists on the storage device, the process ends in error (however, depending on the specifications of the general-purpose machine). Therefore, it is necessary to delete the data set that the job flow finally outputs before starting the job flow. This process is called advance deletion. In the job flow described with reference to FIG. 2B, since the data set AA001 () is a generation management file, it is not necessary to delete in advance, but the data set BB003 needs to be deleted in advance. Therefore, the data set BB003 is deleted by the DELETE statement.
図3Bは、図2Aで説明したジョブフローを記述したジョブ制御言語を示す図である。STEP0010は、プロセスSORT53を実行し、データセットAA001(0)を入力するとともにデータセット&&AA001を出力している。SYSINデータセット(SORT.AA001)はソート時のパラメータ(例:ソート対象フィールド)を指定するデータセットであるため、別途定義している。 FIG. 3B is a diagram showing a job control language describing the job flow described in FIG. 2A. STEP0010 executes the process SORT 53, inputs the data set AA001 (0), and outputs the data set && AA001. The SYSIN data set (SORT.AA001) is a data set that specifies parameters for sorting (eg, a field to be sorted), and is therefore defined separately.
入力データセットを定義する箇所(DD名:SORTINおよびDD名:SYSIN)において、パラメータDISP(DISPosition)=SHRを指定している。これは、共有データファイル(すなわち他のプロセスによって同時にアクセスされる可能性があるデータファイル)に対して共有アクセスする旨を指定している。 The parameter DISP (DISPosition) = SHR is specified at the location (DD name: SORTIN and DD name: SYSIN) where the input data set is defined. This specifies that a shared data file (that is, a data file that may be accessed simultaneously by another process) is shared.
出力データセットを定義する箇所(DD名:SORTOUT)において、パラメータDISP=(NEW,PASS)を指定している。これは、新たなデータファイルを作成するとともに、そのデータファイルを別のプロセスへ引き渡す旨を指定している。UNITパラメータは、記憶装置の種別(ハードディスク:SYSDAまたはテープデバイス:VTS)を指定する。SPACEパラメータは記憶装置上に確保する記憶容量を指定するものであり、1トラックサイズとデータセットの最大サイズから計算することができる。RLSE指定は、レコード件数が最大件数に満たなかった場合、余分な記憶領域を解放する旨を指定している。 The parameter DISP = (NEW, PASS) is specified at the location (DD name: SORTOUT) where the output data set is defined. This designates that a new data file is created and the data file is transferred to another process. The UNIT parameter specifies the type of storage device (hard disk: SYSDA or tape device: VTS). The SPACE parameter specifies the storage capacity to be secured on the storage device, and can be calculated from one track size and the maximum size of the data set. The RLSE designation designates that an extra storage area is released when the number of records is less than the maximum number.
STEP0020は、プロセスFHDBAT1を実行するとともに、そのなかでプロセスMEBPC30を実行することを指定している。バッチ処理においてはデータベースにアクセスする場合があるため、データベースアクセス処理については共通のプロセス内にあらかじめ定義しておき、そのなかでジョブフロー上のプロセスを呼び出す。STEP0020の冒頭部分はその旨を記述している。後述するSTEP0030とSTEP0040についても同様である。 STEP0020 specifies that the process FHDBAT1 is executed and the process MEBPC30 is executed in the process FHDBAT1. Since the database may be accessed in batch processing, the database access processing is defined in advance in a common process, and a process on the job flow is called in that. The beginning part of STEP0020 describes that. The same applies to STEP0030 and STEP0040 described later.
プロセスMEBPC30の1つ目の入力はデータセット&&AA001であり、そのDD名はHEB5401Iである。データセット&&AA001はプロセス間でデータを授受するために一時的に作成されるデータファイルであるため、DISPパラメータは既存ファイルを示すOLDを指定するとともに、引き渡しが完了したら当該データセットを削除する旨を指示するDELETEを指定している。 The first input of the process MEBPC 30 is Data Set && AA001, and its DD name is HEB5401I. Since the data set && AA001 is a data file temporarily created to exchange data between processes, the DISP parameter specifies an OLD indicating an existing file and indicates that the data set is deleted when the delivery is completed. DELETE to be specified is specified.
プロセスMEBPC30の2つ目の入力はデータセットBB001であり、これは既存のデータファイルであって他プロセスが同時にアクセスする可能性があるので、DISPパラメータとして共有アクセスを示すSHRを指定している。 The second input of the process MEBPC 30 is a data set BB001, which is an existing data file and may be accessed simultaneously by other processes. Therefore, SHR indicating shared access is designated as a DISP parameter.
プロセスMEBPC30の2つの出力は、STEP0010の出力と同様の記述ルールにしたがって、図2Aで説明した通り指定されている。また各データセットのレコード長も併せて図2A記載の通り指定されている。 The two outputs of the process MEBPC 30 are specified as described with reference to FIG. 2A according to the same description rule as the output of STEP0010. The record length of each data set is also specified as shown in FIG. 2A.
図3Cは、図2Bで説明したジョブフローを記述したジョブ制御言語を示す図である。以下各ステップについて説明する。 FIG. 3C is a diagram showing a job control language describing the job flow described in FIG. 2B. Each step will be described below.
STEP0030において、プロセスFHDBAT1のなかでプロセスMEBPC35を実行する。入力は、結合子1から続く&&BB0011である。プロセス間でデータを授受するために一時的に作成されるデータファイルであるので、MEBPC30の入力と同様にDISPパラメータとしてOLDとDELETEが指定されている。出力は&&BB0013であり、DISPパラメータ、SPACEパラメータ、UNITパラメータはプロセスMEBPC30と同様に指定されている。レコード長も併せて図2B記載の通り指定されている。
In STEP0030, the process MEBPC 35 is executed in the process FHDBAT1. The input is && BB0011, which continues from
STEP0040において、プロセスFHDBAT1のなかでプロセスMEBPC40を実行する。入力は、結合子2から続く&&BB0012とプロセスMEBPC0035が出力する&&BB0013である。プロセス間でデータを授受するために一時的に作成されるデータファイルであるので、MEBPC30の入力と同様にDISPパラメータとしてOLDとDELETEが指定されている。
In STEP0040, the process MEBPC 40 is executed in the process FHDBAT1. The inputs are && BB0012 and && BB0013 output from the process MEBPC0035 following the
プロセスMEBPC40の1つ目の出力は、AA001(+1)である。このデータセットは最終アウトプットとして記憶装置に格納されるため、DISPパラメータとしてCATLGが指定されている。UNITパラメータ、SPACEパラメータ、レコード長については先行する各プロセスと同様である。 The first output of the process MEBPC 40 is AA001 (+1). Since this data set is stored in the storage device as the final output, CATLG is specified as the DISP parameter. The UNIT parameter, SPACE parameter, and record length are the same as in the preceding processes.
プロセスMEBPC40の2つ目の出力は、BB003である。同様にDISPパラメータとしてCATLGが指定されている。BB003はテープデバイスに対して書き込まれるので、UNITパラメータとしてVTSが指定されている。レコード長については先行する各プロセスと同様である。テープデバイスについてはSPACEパラメータは、不要である為省略されている。 The second output of the process MEBPC 40 is BB003. Similarly, CATLG is specified as the DISP parameter. Since BB003 is written to the tape device, VTS is specified as the UNIT parameter. The record length is the same as each preceding process. For tape devices, the SPACE parameter is omitted because it is unnecessary.
各STEPが終了すると、JCLの最後に終了宣言が記述される。この終了宣言は固定的なものである。 When each STEP ends, an end declaration is described at the end of the JCL. This end declaration is fixed.
<実施の形態1:ルールファイル132について>
JCL自動生成プログラム120は、図2A〜図2Bで説明したジョブフロー図にしたがって、図3A〜図3Cで説明したJCLを自動生成する。このときJCL自動生成プログラム120は、ルールファイル132が記述しているJCLテンプレートを用いる。このJCLテンプレートは、開発者がジョブフローファイル131内に記述すべきパラメータをできる限り少なくするとともに、テンプレートの汎用性を高める観点から、以下の点に配慮して定義されている。
<Embodiment 1: About
The JCL
(ルールファイル132の特徴その1)
同じタイプの入出力データセットを複数用いる場合は、その部分を定義するテンプレートは繰り返し再利用できるように定義されている。例えばあるプロセスに対して複数のデータセットが入力される場合、入力を定義する部分のテンプレートは1つのみであり、JCL自動生成プログラム120はその単一のテンプレートを繰り返し使用する。出力データセットについても同様である。これにより、テンプレートの汎用性を高めるとともに、ルールファイル132の記述を簡易化することができる。詳細は後述の図4Aにおけるサブブロックに関する説明箇所で改めて述べる。
(
When multiple input / output data sets of the same type are used, the template that defines the part is defined so that it can be reused repeatedly. For example, when a plurality of data sets are input for a certain process, there is only one template that defines the input, and the JCL
(ルールファイル132の特徴その2)
ルールファイル132は、図3Aにおいて説明した事前削除を指示するテンプレートを記述している。事前削除は固定的な処理であるため、テンプレートによって定義するのに適している。詳細は後述の図4Aで改めて述べる。
(
The
(ルールファイル132の特徴その3)
ジョブフロー内におけるデータセット名、プロセス名、DD名などの名称は可変であるため、ジョブフロー図内に記載することが望ましいと思われる。したがってこれら名称については、テンプレート上において可変パラメータとして定義することとした。
(
Since data set names, process names, DD names, etc. in the job flow are variable, it is desirable to describe them in the job flow diagram. Therefore, these names are defined as variable parameters on the template.
(ルールファイル132の特徴その4)
プロセス間で授受するデータセットは、一時的に作成されるものであり、授受が完了した後は削除すべきものである。これに対し、当該ジョブフローとは別に記憶装置上に作成されたデータセットは、他のジョブフローやプロセスがアクセスする可能性があるため、共有アクセスすべきものである。一方、プロセスが出力するデータセットは常に新規作成するものであり、次のプロセスに引き渡すのかそれとも最終出力であるのかはジョブフローに依拠する。これらデータ特性は、ジョブフローが定義するデータセットとプロセスとの間の入出力関係に応じて定まるので、ジョブフロー図から導き出すことができる。したがって、これらデータアクセス特性を指定するDISPパラメータは、ジョブフロー図から取得するパラメータとして定義することとした。
(
Data sets exchanged between processes are created temporarily, and should be deleted after the exchange is completed. On the other hand, a data set created on the storage device separately from the job flow is likely to be accessed by other job flows or processes, and should be shared. On the other hand, a data set output by a process is always created anew, and whether it is handed over to the next process or the final output depends on the job flow. Since these data characteristics are determined according to the input / output relationship between the data set defined by the job flow and the process, they can be derived from the job flow diagram. Therefore, the DISP parameters for specifying these data access characteristics are defined as parameters acquired from the job flow diagram.
(ルールファイル132の特徴その5)
プロセスがハードディスク上にデータセットを書き出す場合、確保する記憶容量を指定する必要がある。確保すべき記憶容量は、レコード長、最大レコード件数、記憶装置の1トラック当たりのサイズ、によって計算することができる。前者2つはアプリケーションの仕様と密接に関わるため、ジョブフロー図に記載すべきパラメータとして定義することとした。1トラックサイズは比較的固定されているパラメータであるため、テンプレート内に定義することとした。
(
When a process writes a data set to the hard disk, it is necessary to specify the storage capacity to be secured. The storage capacity to be secured can be calculated from the record length, the maximum number of records, and the size of the storage device per track. Since the former two are closely related to the application specifications, they are defined as parameters to be described in the job flow diagram. Since one track size is a relatively fixed parameter, it is defined in the template.
図4Aは、ルールファイル132の開始部分を示す図である。[]はテンプレートのセクション名を示す。両端を%で囲んだ文字列は可変パラメータである。CNTパラメータは、当該セクションが記述しているテンプレートの行数を示す。
FIG. 4A is a diagram illustrating a start portion of the
ルールファイル132の開始セクション([START]から始まる部分)は、図3Aで説明したJCLの開始宣言に相当するテンプレートが記載されている。ジョブ名(%JOB%)、ジョブクラス名(%CLASS%)、ユーザ名(%USER%)はジョブフロー固有のパラメータであるため、可変パラメータとして定義することとした。これらパラメータは、ジョブフローファイル131内の適当な箇所に記載してもよいし、JCL自動生成プログラム120またはジョブフローファイル131の内部スクリプトによって入力ダイアログを画面表示して入力させてもよい。
In the start section of the rule file 132 (portion starting from [START]), a template corresponding to the JCL start declaration described in FIG. 3A is described. Since the job name (% JOB%), job class name (% CLASS%), and user name (% USER%) are parameters specific to the job flow, they are defined as variable parameters. These parameters may be described in an appropriate place in the
開始宣言の次セクション([ERACE]から始まる部分)は、事前削除を指示するJCLのテンプレートが記載されている。事前削除すべきデータセットの個数はジョブフローに依拠するため、当該部分のテンプレートは繰り返し可能であるように定義することが望ましい。そこで図4Aにおいては、当該部分はサブブロック[ERACE_DD]として切り出している。 In the next section of the start declaration (the part starting with [ERACE]), a JCL template for instructing prior deletion is described. Since the number of data sets to be deleted in advance depends on the job flow, it is desirable to define the template of the part so that it can be repeated. Therefore, in FIG. 4A, this portion is cut out as a sub-block [ERACE_DD].
JCL自動生成プログラム120は、ジョブフローファイル131が記述しているジョブフロー図から、最終出力すべきデータセットのうち世代管理データセットを除いたものを特定し、そのデータセット名を図4A末行の可変パラメータ%DSN%と置き換える。事前削除すべきデータセットが複数存在する場合は、その個数分だけ[ERACE_DD]サブブロックを繰り返し適用する。
The JCL
JCL自動生成プログラム120は、以上の処理により、図4Aに示すテンプレートを図3Aで説明したJCLに置き換えることができる。
The JCL
図4Bは、ルールファイル132のうち図3BのSTEP0010で説明したJCLに相当するテンプレートを記載した箇所を示す図である。SORTプロセスとバッチプロセスはJCLの記述の仕方が異なるため、それぞれのテンプレートは個別に定義することとした。バッチプロセスのテンプレートについては後述の図4Cで説明する。
FIG. 4B is a diagram illustrating a part in which a template corresponding to the JCL described in STEP0010 in FIG. 3B is described in the
%STEP%パラメータは、ステップ番号によって置き換えられる可変パラメータである。JCL自動生成プログラム120は、図2A〜図2Bで説明した、プロセス/入力データセット/出力データセットの組み合わせからなるステップの個数をカウントすることにより、ステップ番号を自動採番する。
The% STEP% parameter is a variable parameter that is replaced by a step number. The JCL
%PROC%パラメータは、当該SORTプロセスのプロセス名によって置き換えられる可変パラメータである。JCL自動生成プログラム120は、ジョブフロー図からSORTプロセスのプロセス名を取得し、%PROC%パラメータをこれに置き換える。
The% PROC% parameter is a variable parameter that is replaced by the process name of the SORT process. The JCL
[SORT_IDD]サブブロックは、当該SORTプロセスに対する入力を定義する部分のテンプレートである。ただしSYSINデータセットを除く。入力データセットの個数はジョブフローに依拠するため、繰り返し可能となるようにサブブロックとして定義されている。JCL自動生成プログラム120は、ジョブフロー図から入力データセット名を取得し、[SORT_IDD]サブブロック内の%DSN%パラメータをこれに置き換える。DISPパラメータは、共有アクセスを指定するSHRを固定的に指定しているが、他プロセスから引き渡されるデータをソートする場合は、後述する[BATCH_IDD]サブブロックと同様に可変パラメータとすることもできる。
The [SORT_IDD] sub-block is a template of a part that defines an input to the SORT process. However, the SYSIN data set is excluded. Since the number of input data sets depends on the job flow, it is defined as a sub-block so that it can be repeated. The JCL
[SORT_ODD]サブブロックは、当該SORTプロセスからの出力を定義する部分のテンプレートである。出力データセットの個数はジョブフローに依拠するため、繰り返し可能となるようにサブブロックとして定義されている。JCL自動生成プログラム120は、ジョブフロー図から出力データセット名を取得し、[SORT_ODD]サブブロック内の%DSN%パラメータをこれに置き換える。
The [SORT_ODD] sub-block is a template of a part that defines an output from the SORT process. Since the number of output data sets depends on the job flow, it is defined as a sub-block so that it can be repeated. The JCL
出力データセットがジョブフローの最終出力である場合、JCL自動生成プログラム120はDISPパラメータとして図3Cで説明したCATLGを指定する。出力データセットが次のプロセスに引き渡される場合、JCL自動生成プログラム120はDISPパラメータとして図3Bで説明したNEW/PASSを指定する。出力データセットの出力先についてはジョブフロー図から取得することができる。
When the output data set is the final output of the job flow, the JCL
JCL自動生成プログラム120は、出力データセットを書き込むデバイスタイプ(すなわちデバイスを表すジョブフロー部品のタイプ)をジョブフロー図から取得し、%UNIT%パラメータをそのデバイスタイプに置き換える。
The JCL
JCL自動生成プログラム120は、後述する1トラック当たりのデータサイズをルールファイル132から取得し、さらにジョブフロー図から当該出力データセットのレコード長と最大レコード件数を取得する。当該出力データセットを書き出すために確保すべきトラック数は、(総レコード件数)/(1トラックサイズ/レコード長)によって求めることができる。JCL自動生成プログラム120は、%DISKSPACE%パラメータを求めた値に置き換える。
The JCL
JCL自動生成プログラム120は、ジョブフロー図上で当該SORTプロセスに対して入力されているSYSINデータセット名を取得し、これをDD名SYSIN部分の%DSN%パラメータと置き換える。
The JCL
JCL自動生成プログラム120は、以上の処理により、図4Bに示すテンプレートを図3BのSTEP0010で説明したJCLに置き換えることができる。
The JCL
図4Cは、ルールファイル132のうち図3BのSTEP0020〜図3CのSTEP0040で説明したJCLに相当するテンプレートを記載した箇所を示す図である。これらステップは全てバッチプロセスであるため、同じテンプレートによってJCLを自動生成することができる。
FIG. 4C is a diagram illustrating a part in which a template corresponding to the JCL described in
%STEP%パラメータについては図4Bと同様である。%SYSTEM%パラメータと%PLAN%パラメータは、ジョブフローファイル131内の適当な箇所に記載してもよいし、JCL自動生成プログラム120またはジョブフローファイル131の内部スクリプトによって入力ダイアログを画面表示して入力させてもよい。
The% STEP% parameter is the same as in FIG. 4B. The% SYSTEM% parameter and the% PLAN% parameter may be entered in an appropriate place in the
[BATCH_IDD]サブブロックは、当該プロセスに対する入力を定義する部分のテンプレートである。[SORT_IDD]と同様に、繰り返し可能なサブブロックとして定義している。JCL自動生成プログラム120は、ジョブフロー図から入力データセット名とそのDD名を取得し、[BATCH_IDD]サブブロック内の%DSN%パラメータおよび%DDN%パラメータをこれらに置き換える。入力データセットが他プロセスからの出力である場合、JCL自動生成プログラム120はDISPパラメータとして図3Bで説明したOLD/DELETEを指定する。入力データセットが記憶装置上の既存データである場合、JCL自動生成プログラム120はDISPパラメータとしてSHRを指定する。
The [BATCH_IDD] sub-block is a part template that defines the input to the process. Similar to [SORT_IDD], it is defined as a repeatable sub-block. The JCL
[BATCH_ODD]サブブロックは、当該プロセスからの出力を定義する部分のテンプレートである。[SORT_ODD]と同様に、繰り返し可能なサブブロックとして定義している。JCL自動生成プログラム120は、ジョブフロー図から出力データセット名とそのDD名を取得し、[BATCH_ODD]サブブロック内の%DSN%パラメータおよび%DDN%パラメータをこれらに置き換える。%DISP%、%UNIT%、%DISKSPACE%については[SORT_ODD]サブブロックと同様である。%RECLENGTH%パラメータは、ジョブフロー図上で指定されているレコード長に置き換えられる。
The [BATCH_ODD] sub-block is a template of a part that defines the output from the process. Similar to [SORT_ODD], it is defined as a repeatable sub-block. The JCL
JCL自動生成プログラム120は、以上の処理により、図4Cに示すテンプレートを図3BのSTEP0020〜図3CのSTEP0040で説明したJCLに置き換えることができる。
The JCL
図4Dは、ルールファイル132のうち図3Cの終了宣言部分に相当するテンプレートを記載した箇所を示す図である。[END]セクションは終了宣言のテンプレートを記載している。終了宣言は固定的であるため、可変パラメータはない。
FIG. 4D is a diagram illustrating a part in which a template corresponding to the end declaration part of FIG. 3C is described in the
[DISKSPACE]セクションは、確保すべきハードディスクの記憶容量を計算する際の基礎データを記載している。BASE_SIZEパラメータは、1トラック当たりのデータサイズを指定する。JCL自動生成プログラム120はこの数値を用いて、先に説明した%DISKSPACE%パラメータを計算する。本セクションはテンプレートそのものではないため、JCL内には記載されない。
The [DISKSPACE] section describes basic data for calculating the storage capacity of the hard disk to be secured. The BASE_SIZE parameter specifies the data size per track. The JCL
JCL自動生成プログラム120は、ジョブフローファイル131が記述しているジョブフロー図を入力として受け取り、同図が記述しているジョブフローおよび各名称などのパラメータを、ルールファイル132が記述しているテンプレートに対して適用する。これにより、図3A〜図3Cで説明したようなジョブ制御ファイル133を自動生成することができる。
The JCL
<実施の形態1:まとめ>
本実施形態1に係るJCL自動生成プログラム120は、ジョブフロー図に基づき生成すべきJCLのテンプレートをルールファイル132から読み取り、これに対してジョブフローやデータセット名などを反映する。これにより、汎用機、そのOSなどの個別具体的な仕様に応じて、自動生成するJCLを柔軟にカスタマイズすることができる。
<Embodiment 1: Summary>
The JCL
本実施形態1に係るJCL自動生成プログラム120は、ジョブフローの最後において出力されるデータセットのうち世代管理されないものを特定し、そのデータセットを事前削除するJCL文を自動生成する。これにより、事前削除に係るJCL文をマニュアル作成する手間を削減することができる。また、事前削除すべきデータセットが複数ある場合であっても、単一の[ERACE_DD]サブブロックによってそれら全てについて自動対処することができる。
The JCL
本実施形態1に係るJCL自動生成プログラム120は、プロセスに対して入力されるデータセットが他プロセスの出力であるのか、それとも当該ジョブフローとは別に作成されたものであるのかに応じて、入力定義部分のDISPパラメータを自動セットする。これにより、プロセスに対する入力を定義するJCL文を作成する手間を削減することができる。
The JCL
本実施形態1に係るJCL自動生成プログラム120は、プロセスが出力するデータセットが他プロセスに対して引き渡されるのか、それとも当該ジョブフローの最終出力となるのかに応じて、出力定義部分のDISPパラメータを自動セットする。これにより、プロセスからの出力を定義するJCL文を作成する手間を削減することができる。
The JCL
本実施形態1に係るJCL自動生成プログラム120は、プロセスが出力するデータセットを書き出すために確保すべきハードディスクの記憶容量を、ルールファイル132が定義している1トラックサイズおよびジョブフロー図上の各パラメータに基づき自動計算する。これにより、プロセスからの出力を定義するJCL文を作成する手間をさらに削減することができる。
The JCL
<実施の形態2>
実施形態1で説明したジョブフローファイル131は、JCL自動生成プログラム120がジョブフローと各ジョブフロー部品および各名称などのパラメータを読み取ることができるのであれば、任意の形式で作成することができる。例えば市場で一般的に入手できる表計算ソフト、文書作成ソフト、プレゼンテーションソフトなどの図形編集機能によって作成することができる。ジョブフローファイル131のデータ形式が変更された場合、JCL自動生成プログラム120がジョブフローファイル131を読み取る処理のみ改修すれば、変更前と同様の機能を利用することができる。
<
The job flow file 131 described in the first embodiment can be created in an arbitrary format as long as the JCL
100:コンピュータ、110:CPU、120:JCL自動生成プログラム、130:記憶部、131:ジョブフローファイル、132:ルールファイル、133:ジョブ制御ファイル。 100: computer, 110: CPU, 120: JCL automatic generation program, 130: storage unit, 131: job flow file, 132: rule file, 133: job control file.
Claims (9)
前記汎用機に実行させるジョブフローを定義するジョブフロー図を記述したジョブフローファイルを読み込むジョブフロー取得ステップ、
前記ジョブフロー図にしたがって前記ジョブ制御ファイルを生成するための規則を記述したルールファイルを読み込むルール取得ステップ、
前記ジョブフロー図が定義しているジョブフローに対して前記ルールファイルを適用することにより前記ジョブ制御ファイルを生成する生成ステップ、
を実行させ、
前記ルールファイルは、前記ジョブフロー図が定義するジョブフローを記述する前記ジョブ制御言語のテンプレートを、前記ジョブフロー上におけるプロセスを表すジョブフロー部品の種別毎に記述しており、
前記生成ステップにおいては、前記コンピュータに、前記ジョブフロー部品を前記テンプレートに置き換えることによって前記ジョブ制御言語を生成させる
ことを特徴とするジョブ制御言語自動生成プログラム。 A program for causing a computer to execute processing for generating a job control file described in a job control language used by a general-purpose machine,
A job flow acquisition step of reading a job flow file describing a job flow diagram defining a job flow to be executed by the general-purpose machine;
A rule acquisition step of reading a rule file describing rules for generating the job control file according to the job flow diagram;
Generating the job control file by applying the rule file to the job flow defined by the job flow diagram;
And execute
The rule file describes the job control language template describing the job flow defined by the job flow diagram for each type of job flow component representing a process on the job flow,
In the generation step, the job control language is generated by causing the computer to replace the job flow component with the template.
前記ルールファイルは、前記プロセスに対する入力または前記プロセスからの出力を定義する前記ジョブ制御言語のテンプレートとして、入力定義テンプレートまたは出力定義テンプレートを記述しており、
前記生成ステップにおいては、前記コンピュータに、
前記ジョブフロー上において前記プロセスに対して入力されるデータの個数と同じ回数だけ前記入力定義テンプレートを繰り返し使用し、または前記プロセスから出力されるデータの個数と同じ回数だけ前記出力定義テンプレートを繰り返し使用することにより、単一の前記入力定義テンプレートまたは単一の前記出力定義テンプレートを用いて前記プロセスに対する入力または前記プロセスからの出力を定義する前記ジョブ制御言語を生成させる
ことを特徴とする請求項1記載のジョブ制御言語自動生成プログラム。 The job flow diagram defines the job flow in which one or more data is input to a process on the job flow, or the process outputs one or more data,
The rule file describes an input definition template or an output definition template as a template of the job control language that defines input to the process or output from the process.
In the generating step, the computer
The input definition template is repeatedly used as many times as the number of data input to the process in the job flow, or the output definition template is repeatedly used as many times as the number of data output from the process. The job control language defining the input to the process or the output from the process is generated by using the single input definition template or the single output definition template. The job control language automatic generation program described.
前記ルールファイルは、前記ジョブフローを開始する前の時点において前記出力データファイルが存在する場合は前記ジョブフローを開始する前に前記出力データファイルを削除する旨を指定する前記ジョブ制御言語のテンプレートを記述しており、
前記生成ステップにおいては、前記コンピュータに、
前記ジョブフロー図上における前記出力データファイルを特定した上で、前記ルールファイルの記述にしたがって、特定した前記出力データファイルを削除する前記ジョブ制御言語を、前記ジョブフローを記述する前記ジョブ制御言語の前に生成させる
ことを特徴とする請求項1または2記載のジョブ制御言語自動生成プログラム。 The job flow diagram defines that one or more output data files are output as the output of the job flow,
The rule file is a template for the job control language that specifies that the output data file is to be deleted before starting the job flow if the output data file exists at the time before starting the job flow. Has written,
In the generating step, the computer
After specifying the output data file on the job flow diagram, in accordance with the description of the rule file, the job control language for deleting the specified output data file is the same as the job control language for describing the job flow. The job control language automatic generation program according to claim 1, wherein the job control language automatic generation program is generated before.
前記出力データファイルのうち前記汎用機上で世代管理するものを除いた前記出力データファイルを特定し、特定した前記出力データファイルを削除する前記ジョブ制御言語を生成させる
を実行させることを特徴とする請求項3記載のジョブ制御言語自動生成プログラム。 In the generating step, the computer
The output data file except for the output data file whose generation is managed on the general-purpose machine is specified, and the job control language for deleting the specified output data file is generated. The job control language automatic generation program according to claim 3.
前記生成ステップにおいては、前記コンピュータに、
前記ジョブフロー上において前記プロセスに対して入力され、または前記プロセスから出力される前記データファイルのデータセット名を、前記ジョブフローファイルから取得するステップ、
前記プロセスに対する入力または前記プロセスからの出力として前記ジョブフローファイルから取得したデータセット名を指定する前記ジョブ制御言語を生成するステップ、
を実行させることを特徴とする請求項1から4のいずれか1項記載のジョブ制御言語自動生成プログラム。 The job flow diagram describes the data set name of the data file along with the connection relationship between the process and the data file on the job flow,
In the generating step, the computer
Obtaining from the job flow file a data set name of the data file input to or output from the process on the job flow;
Generating the job control language specifying a data set name obtained from the job flow file as an input to or output from the process;
The job control language automatic generation program according to any one of claims 1 to 4, wherein the program is executed.
前記プロセスに対する入力が他プロセスから引き渡されるデータファイルである場合は、前記プロセスに対する入力の種別として既存データファイルを指定するとともに、前記プロセスに対して入力し終えた前記既存データファイルを削除するよう指定する、前記ジョブ制御言語を生成するステップ、
前記プロセスに対する入力が他プロセスによって同時にアクセスされ得る共有データファイルである場合は、前記プロセスに対する入力の種別として共有データファイルを指定する、前記ジョブ制御言語を生成するステップ、
を実行させることを特徴とする請求項5記載のジョブ制御言語自動生成プログラム。 In the generating step, the computer
If the input to the process is a data file delivered from another process, specify the existing data file as the type of input to the process and specify to delete the existing data file that has been input to the process Generating the job control language;
If the input to the process is a shared data file that can be accessed simultaneously by other processes, generating the job control language, specifying the shared data file as a type of input to the process;
The job control language automatic generation program according to claim 5, wherein:
前記プロセスからの出力が他プロセスに対して引き渡されるデータファイルである場合は、前記プロセスからの出力の種別として新規データファイルを指定するとともに、他プロセスに対して引き渡すデータファイルである旨を指定する、前記ジョブ制御言語を生成するステップ、
前記プロセスからの出力が前記ジョブフローの最終出力として出力されるデータファイルである場合は、前記プロセスからの出力の種別として新規データファイルを指定するとともに、前記ジョブフローの最終出力として出力するデータファイルである旨を指定する、前記ジョブ制御言語を生成するステップ、
を実行させることを特徴とする請求項5または6記載のジョブ制御言語自動生成プログラム。 In the generating step, the computer
If the output from the process is a data file delivered to another process, specify a new data file as the type of output from the process and specify that the data file is delivered to another process Generating the job control language;
When the output from the process is a data file output as the final output of the job flow, a new data file is designated as the output type from the process and the data file is output as the final output of the job flow Generating the job control language, designating that
7. The job control language automatic generation program according to claim 5, wherein:
前記プロセスがデータファイルを書き込む記憶装置の1書込単位あたりの記憶容量、
前記記憶装置に対してデータファイルを書き込む際に前記記憶装置上の記憶領域を確保するよう指定する前記ジョブ制御言語のテンプレート、
を記述しており、
前記ジョブフロー図は、前記記憶装置に対して書き込まれるデータファイルのレコード長と最大レコード件数を記述しており、
前記生成ステップにおいては、前記コンピュータに、
前記ジョブフロー図が記述している前記レコード長と前記最大レコード件数、および前記ルールファイルが記述している前記1書込単位あたりの記憶容量を用いて、前記記憶装置上に確保すべき記憶領域のサイズを計算するステップ、
前記計算したサイズの記憶領域を前記記憶装置上に確保する前記ジョブ制御言語を生成するステップ、
を実行させることを特徴とする請求項1から7のいずれか1項記載のジョブ制御言語自動生成プログラム。 The rule file is
A storage capacity per writing unit of a storage device into which the process writes a data file;
A template for the job control language that specifies to reserve a storage area on the storage device when writing a data file to the storage device;
Is described,
The job flow diagram describes the record length and the maximum number of records of a data file written to the storage device,
In the generating step, the computer
A storage area to be secured on the storage device using the record length and the maximum number of records described in the job flow diagram, and the storage capacity per writing unit described in the rule file Calculating the size of the
Generating the job control language for securing a storage area of the calculated size on the storage device;
8. The job control language automatic generation program according to claim 1, wherein the program is executed.
ことを特徴とする請求項1から8のいずれか1項記載のジョブ制御言語自動生成プログラム。 The job control language automatic generation program according to any one of claims 1 to 8, wherein the job flow file is a file having a data format created by a drawing creation application executed on the computer.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2014209141A JP2016081126A (en) | 2014-10-10 | 2014-10-10 | Job control language automatic generation program |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2014209141A JP2016081126A (en) | 2014-10-10 | 2014-10-10 | Job control language automatic generation program |
Publications (1)
Publication Number | Publication Date |
---|---|
JP2016081126A true JP2016081126A (en) | 2016-05-16 |
Family
ID=55956271
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2014209141A Pending JP2016081126A (en) | 2014-10-10 | 2014-10-10 | Job control language automatic generation program |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP2016081126A (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US10310961B1 (en) | 2017-11-29 | 2019-06-04 | International Business Machines Corporation | Cognitive dynamic script language builder |
CN112181912A (en) * | 2020-09-28 | 2021-01-05 | 中国建设银行股份有限公司 | File format determining method, device, equipment and storage medium |
Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPH03269622A (en) * | 1990-03-19 | 1991-12-02 | Nec Corp | Generating device for job control statement |
JPH05127883A (en) * | 1991-11-02 | 1993-05-25 | Fujitsu Ltd | Automatic generator for job step |
-
2014
- 2014-10-10 JP JP2014209141A patent/JP2016081126A/en active Pending
Patent Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPH03269622A (en) * | 1990-03-19 | 1991-12-02 | Nec Corp | Generating device for job control statement |
JPH05127883A (en) * | 1991-11-02 | 1993-05-25 | Fujitsu Ltd | Automatic generator for job step |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US10310961B1 (en) | 2017-11-29 | 2019-06-04 | International Business Machines Corporation | Cognitive dynamic script language builder |
CN112181912A (en) * | 2020-09-28 | 2021-01-05 | 中国建设银行股份有限公司 | File format determining method, device, equipment and storage medium |
CN112181912B (en) * | 2020-09-28 | 2024-03-12 | 中国建设银行股份有限公司 | Method, device, equipment and storage medium for determining file format |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN108388622B (en) | API interface dynamic generation method and device, computer equipment and storage medium | |
CN112036736A (en) | Workflow creating method and device | |
CN104182252A (en) | App version incremental updating method | |
US9824000B1 (en) | Testing calling code dynamically with random error injection based on user-specified configuration | |
CN104794048A (en) | Automatic UI testing method and system | |
US20170220721A1 (en) | Systems and methods for dynamic symbols for devices in electrical schematics | |
JPWO2020008991A1 (en) | Verification automation equipment, verification automation methods, and programs | |
CN112256670A (en) | Data migration method, terminal device and readable storage medium | |
US10678864B2 (en) | Analysis model preparing system, programming apparatus, and analysis model preparing method | |
JP2023553220A (en) | Process mining for multi-instance processes | |
JP2016081126A (en) | Job control language automatic generation program | |
US20110167047A1 (en) | Editing apparatus, method, and storage medium | |
CN109408322A (en) | A kind of automatic business process implementation method of cloud platform | |
US8024158B2 (en) | Management system and management method of CAD data used for a structural analysis | |
JP2017107265A (en) | Test scenario creation support system and test scenario creation support method | |
JP2016009423A (en) | Information processing device, method for controlling information processing device, and program | |
JP6168206B2 (en) | Information processing apparatus, information processing apparatus control method, and program | |
CN111460235A (en) | Atlas data processing method, device, equipment and storage medium | |
CN114022105A (en) | Data processing method and device, electronic equipment and readable storage medium | |
JP2020064399A (en) | Control system, control device, terminal device, and program | |
CN108845857A (en) | A kind of icon management method and device based on cloud platform | |
JP6157375B2 (en) | Operation procedure flow update device, method and program | |
JP2018109898A (en) | Data migration system | |
WO2015181876A1 (en) | System operation support method and computer | |
WO2012169238A1 (en) | Operation assistance method and computer |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20170421 |
|
A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20180213 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20180320 |
|
A02 | Decision of refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A02 Effective date: 20180918 |