JP2018028738A - Communication control program, communication control device, and communication control method - Google Patents

Communication control program, communication control device, and communication control method Download PDF

Info

Publication number
JP2018028738A
JP2018028738A JP2016159383A JP2016159383A JP2018028738A JP 2018028738 A JP2018028738 A JP 2018028738A JP 2016159383 A JP2016159383 A JP 2016159383A JP 2016159383 A JP2016159383 A JP 2016159383A JP 2018028738 A JP2018028738 A JP 2018028738A
Authority
JP
Japan
Prior art keywords
log
load
communication control
message
output
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
JP2016159383A
Other languages
Japanese (ja)
Other versions
JP6652464B2 (en
Inventor
克樹 冨田
Katsuki Tomita
克樹 冨田
めぐみ 佐藤
Megumi Sato
めぐみ 佐藤
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.)
Fujitsu Frontech Ltd
Original Assignee
Fujitsu Frontech Ltd
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 Fujitsu Frontech Ltd filed Critical Fujitsu Frontech Ltd
Priority to JP2016159383A priority Critical patent/JP6652464B2/en
Publication of JP2018028738A publication Critical patent/JP2018028738A/en
Application granted granted Critical
Publication of JP6652464B2 publication Critical patent/JP6652464B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

PROBLEM TO BE SOLVED: To provide a communication control program that can reduce the influence of deterioration in performance of a system due to log output.SOLUTION: A communication control program issues a load state determination request (invocation of workload determination processing) to determine a load on a work processing part S901, determines whether the load on the work processing part is a heavy load S902, when the load is a heavy load Yes in S902, outputs an acquired log collection information to a log intermediate file storage part S903, and when the log is not a heavy load No in S902, issues a log editing request (invocation of log editing processing) S904. A sub routine of the log editing processing includes acquiring a template of a log message from a log message storage part, embedding the log collection information in the acquired template of the log message for editing, and outputting the edited log message to a log file storage part.SELECTED DRAWING: Figure 9

Description

本発明は、ログ出力を制御する通信制御プログラムに関する。   The present invention relates to a communication control program for controlling log output.

システムを運用する上で、ログはシステムにおいて何が起きたかを把握するために重要な役割を果たす。例えば、ログはプログラム動作中の状態監視や異常発生時の検知及び原因の調査に用いられる。その他に、業務の証跡として所定期間保存し、各種監査などのためにも用いられる。   In operating the system, the log plays an important role in grasping what happened in the system. For example, the log is used for status monitoring during program operation, detection when an abnormality occurs, and investigation of the cause. In addition, it is stored for a predetermined period as a business trail and used for various audits.

従来のログ出力の仕組みの一例は以下のようである。プログラム実行中にログ出力処理が呼び出されると、プログラムにあらかじめ埋め込まれたメッセージIDをキーとして、ログメッセージ定義ファイルを検索してログメッセージを取得する。定型化したログメッセージのみでは原因の調査ができないため、引数や変数の値など、そのタイミングでなければ取得できない情報を動的にログメッセージに埋め込み、編集してログファイルに出力する。すなわち、ログメッセージの出力までには、ログメッセージの取得処理、埋め込む情報の取得処理、ログメッセージの編集処理、ログメッセージの出力処理の一連の処理が行われる。ログメッセージを出力する技術が、例えば下記の特許文献1に開示されている。   An example of a conventional log output mechanism is as follows. When the log output process is called during the execution of the program, the log message definition file is searched using the message ID embedded in the program as a key to obtain the log message. Because the cause cannot be investigated only with the stylized log message, information that can only be acquired at that timing, such as arguments and variable values, is dynamically embedded in the log message, edited, and output to the log file. In other words, a series of processes including a log message acquisition process, an embedded information acquisition process, a log message editing process, and a log message output process are performed before the log message is output. A technique for outputting a log message is disclosed, for example, in Patent Document 1 below.

特開2014−149783号公報JP 2014-149783 A

しかし、例えば、証券取引業務などのように高速処理が求められる場合、上記一連の処理を行うことによって、求められる処理の性能を満たすことがシステム上、困難になってしまう。   However, for example, when high-speed processing is required, such as in securities trading business, it is difficult for the system to satisfy the required processing performance by performing the above-described series of processing.

本発明は、上記課題に鑑み、ログ出力によるシステムの性能劣化の影響を抑えることができる通信制御プログラムを提供することを目的とする。   An object of this invention is to provide the communication control program which can suppress the influence of the performance degradation of the system by log output in view of the said subject.

上記目的を達成するために、本発明は、ログ出力の処理を制御する通信制御プログラムであって、ログ出力の呼び出しに基づいて、前記呼び出し時に取得可能な、ログを生成するために必要な情報を取得するステップと、取得された前記情報をログ中間ファイル情報として、ログの生成が開始される前に所定の記憶領域に出力するステップとをコンピュータに実行させることを特徴とする。   In order to achieve the above object, the present invention provides a communication control program for controlling log output processing, which is information necessary for generating a log that can be acquired at the time of a call based on a log output call. And a step of outputting the acquired information as log intermediate file information to a predetermined storage area before log generation is started.

また、本発明の通信制御プログラムにおいて、前記ログ出力の対象業務における業務処理を実行する業務処理部の負荷が所定の負荷を超えているか否かを判断するステップを更に有し、前記所定の負荷を超えていると判断された場合、取得された前記情報を前記ログ中間ファイル情報として出力することは、好ましい態様である。   In the communication control program of the present invention, the communication control program further includes a step of determining whether or not a load of a business processing unit that executes business processing in the target business of log output exceeds a predetermined load, When it is determined that the log information is over, outputting the acquired information as the log intermediate file information is a preferable mode.

また、本発明の通信制御プログラムにおいて、時間帯、単位時間あたりのデータ送受信量、又はあらかじめ決められた負荷状況に基づいて、前記業務処理部の負荷が前記所定の負荷を超えているか否かを判断することは、好ましい態様である。   In the communication control program of the present invention, whether or not the load of the business processing unit exceeds the predetermined load based on a time zone, a data transmission / reception amount per unit time, or a predetermined load situation. Judging is a preferred embodiment.

また、本発明の通信制御プログラムにおいて、所定の条件を満たした場合に、前記所定の記憶領域の前記ログ中間ファイル情報を用いてログを生成し、生成された前記ログを出力するステップを更に有することは、好ましい態様である。   The communication control program according to the present invention further includes a step of generating a log using the log intermediate file information in the predetermined storage area and outputting the generated log when a predetermined condition is satisfied. This is a preferred embodiment.

また、本発明は、ログ出力の処理を制御する通信制御装置であって、ログ出力の呼び出しに基づいて、前記呼び出し時に取得可能な、ログを生成するために必要な情報を取得する取得部と、取得された前記情報をログ中間ファイル情報として、ログの生成が開始される前に所定の記憶領域に出力する出力部とを備えることを特徴とする。   In addition, the present invention is a communication control device that controls processing of log output, and based on a log output call, an acquisition unit that acquires information necessary for generating a log that can be acquired at the time of the call; And an output unit that outputs the acquired information as log intermediate file information to a predetermined storage area before log generation is started.

また、本発明は、ログ出力の処理を制御する通信制御方法であって、ログ出力の呼び出しに基づいて、前記呼び出し時に取得可能な、ログを生成するために必要な情報を取得するステップと、取得された前記情報をログ中間ファイル情報として、ログの生成が開始される前に所定の記憶領域に出力するステップとを有することを特徴とする。   Further, the present invention is a communication control method for controlling the processing of log output, the step of acquiring information necessary for generating a log that can be acquired at the time of calling based on the call of log output; A step of outputting the acquired information as log intermediate file information to a predetermined storage area before log generation is started.

本発明によれば、ログ出力によるシステムの性能劣化の影響を抑えることができる。   According to the present invention, it is possible to suppress the influence of system performance degradation caused by log output.

実施の形態に係る通信制御プログラムを実装するサーバを含む通信制御システムの構成の一例を示す図である。It is a figure which shows an example of a structure of the communication control system containing the server which mounts the communication control program which concerns on embodiment. 実施の形態における運用監視装置の構成の一例を示す図である。It is a figure which shows an example of a structure of the operation | movement monitoring apparatus in embodiment. 実施の形態に係るサーバの機能構成の一例を示す図である。It is a figure which shows an example of the function structure of the server which concerns on embodiment. 実施の形態に係るサーバを実現するためのハードウェア構成の一例を示す図である。It is a figure which shows an example of the hardware constitutions for implement | achieving the server which concerns on embodiment. 実施の形態における業務処理部が高負荷の場合の処理を説明するための図である。It is a figure for demonstrating the process when the work process part in embodiment is high load. 実施の形態における業務処理部が低負荷の場合の処理を説明するための図である。It is a figure for demonstrating the process when the work process part in embodiment is low load. 実施の形態におけるログ出力後処理部によるログ出力後処理を説明するための図である。It is a figure for demonstrating the log output post-process by the log output post-processing part in embodiment. 実施の形態に係る通信制御プログラムを実装するサーバ2におけるログ出力の処理フローの一例を示すフローチャートである。It is a flowchart which shows an example of the processing flow of the log output in the server 2 which mounts the communication control program which concerns on embodiment. 実施の形態におけるログ出力処理のサブルーチンを示すフローチャートである。It is a flowchart which shows the subroutine of the log output process in embodiment. 実施の形態における業務負荷判定処理のサブルーチンを示すフローチャートである。It is a flowchart which shows the subroutine of the work load determination process in embodiment. 実施の形態におけるログ編集処理のサブルーチンを示すフローチャートである。It is a flowchart which shows the subroutine of the log edit process in embodiment. 実施の形態におけるログ出力後処理のサブルーチンを示すフローチャートである。It is a flowchart which shows the subroutine of the log output post-process in embodiment. 実施の形態におけるログ中間ファイルの一例を示す図である。It is a figure which shows an example of the log intermediate | middle file in embodiment. 実施の形態におけるログメッセージのテンプレートの一例を示す図である。It is a figure which shows an example of the template of the log message in embodiment. 実施の形態における業務負荷判定基準(時間帯による基準)の一例を示す図である。It is a figure which shows an example of the business load determination standard (standard by a time slot | zone) in embodiment. 実施の形態における業務処理部が高負荷の場合の処理を説明するための図である。It is a figure for demonstrating the process when the work process part in embodiment is high load. 実施の形態における業務処理部が低負荷の場合の処理を説明するための図である。It is a figure for demonstrating the process when the work process part in embodiment is low load. 実施の形態におけるログメッセージの編集処理のサブルーチンを示すフローチャートである。It is a flowchart which shows the subroutine of the edit process of the log message in embodiment. 実施の形態における埋め込み文字変換テーブルの一例を示す図である。It is a figure which shows an example of the embedded character conversion table in embodiment. 実施の形態におけるログメッセージのマージ処理及びソート処理の具体的な例について説明するための図である。FIG. 10 is a diagram for describing a specific example of log message merging processing and sorting processing in the embodiment;

以下、実施の形態について図面を参照して説明する。まず、実施の形態に係る通信制御プログラムを実装するサーバを含む通信制御システムの一例について図1を用いて説明する。通信制御システム1は、サーバ2(通信制御装置)と運用監視装置3から構成されている。サーバ2と運用監視装置3は、ネットワーク4を介して接続されている。   Hereinafter, embodiments will be described with reference to the drawings. First, an example of a communication control system including a server that implements a communication control program according to an embodiment will be described with reference to FIG. The communication control system 1 includes a server 2 (communication control device) and an operation monitoring device 3. The server 2 and the operation monitoring device 3 are connected via a network 4.

サーバ2は、所定の業務が遂行されている間に、ログ出力処理が呼び出される(ログ出力対象の事象が発生する)と、ログ(以下、ログメッセージとも言う)の生成に必要な情報(例えば、タイムスタンプ、メッセージID、埋め込み文字など)を取得する。そして、サーバ2は、取得した情報をログ中間ファイルとして、ログの生成が開始される前、すなわち将来的に行われるログの生成処理の前に出力する。ここで、所定の業務とは、例えば高速処理を必要とする業務であって、証券取引業務などである。サーバ2(通信制御プログラム)における詳細な処理については後述する。   When the server 2 performs a predetermined job, when the log output process is called (an event that is a log output target occurs), information necessary for generating a log (hereinafter also referred to as a log message) (for example, , Time stamp, message ID, embedded character, etc.). Then, the server 2 outputs the acquired information as a log intermediate file before starting log generation, that is, before log generation processing to be performed in the future. Here, the predetermined business is, for example, business requiring high-speed processing, such as securities trading business. Detailed processing in the server 2 (communication control program) will be described later.

運用監視装置3は、図2に示すように、サーバ2によって出力されるログ中間ファイル及びログファイルを監視する監視プログラム20と、監視結果を出力する監視画面21から構成される。具体的には、運用監視装置3は、後述するログファイル格納部38に格納されたログメッセージなどを監視画面21に表示する。これにより、監視者はシステムにおいて何が起きたかを把握することができる。   As shown in FIG. 2, the operation monitoring apparatus 3 includes a log intermediate file output by the server 2 and a monitoring program 20 that monitors the log file, and a monitoring screen 21 that outputs a monitoring result. Specifically, the operation monitoring apparatus 3 displays a log message or the like stored in a log file storage unit 38 described later on the monitoring screen 21. Thereby, the supervisor can grasp what happened in the system.

次に、実施の形態に係る通信制御プログラムを実装するサーバの機能構成の一例について図3を用いて説明する。図3に示すように、サーバ2は、業務処理部30、ログ出力処理部31、ログ編集処理部32、ログ出力後処理部33、業務負荷判定処理部34、業務負荷格納部35、ログメッセージ格納部36、ログ中間ファイル格納部37、ログファイル格納部38から構成されている。なお、サーバ2の構成はこれに限られるものではなく、他の構成を含むものであってもよい。   Next, an example of a functional configuration of a server that implements the communication control program according to the embodiment will be described with reference to FIG. As shown in FIG. 3, the server 2 includes a business processing unit 30, a log output processing unit 31, a log editing processing unit 32, a log output post-processing unit 33, a business load determination processing unit 34, a business load storage unit 35, and a log message. The storage unit 36 includes a log intermediate file storage unit 37 and a log file storage unit 38. The configuration of the server 2 is not limited to this, and may include other configurations.

業務処理部30は、サーバ2の主な業務機能を実現する処理部であって、通信制御プログラムの場合、データの送受信を行う。また、ログ出力のための情報採取や、業務処理部30の業務負荷(負荷状況)を判断するための単位時間あたりのデータ送受信量の測定も行う。   The business processing unit 30 is a processing unit that realizes main business functions of the server 2, and transmits and receives data in the case of a communication control program. It also collects information for log output and measures the amount of data sent and received per unit time to determine the business load (load status) of the business processing unit 30.

ログ出力処理部31は、業務処理部30からのログ出力依頼を受け、ログ出力処理を行う。この際、後述するように、ログ出力処理部31は、業務負荷判定処理部34の判定結果を参照し、業務負荷が高負荷の場合はログ採取情報のみをログ中間ファイルとしてログ中間ファイル格納部37へ出力する。また、業務負荷が低負荷の場合は、ログ出力処理部31はログ編集処理部32にログ編集要求を行い、ログ採取情報を渡す。   The log output processing unit 31 receives a log output request from the business processing unit 30 and performs log output processing. At this time, as will be described later, the log output processing unit 31 refers to the determination result of the business load determination processing unit 34, and when the business load is high, only the log collection information is stored as a log intermediate file. Output to 37. When the business load is low, the log output processing unit 31 makes a log editing request to the log editing processing unit 32 and passes the log collection information.

ここで、ログ採取情報とは、ログの生成に必要な情報であって、ログ出力処理が呼び出された時点でなければ取得できない情報である。具体的には、上述したタイムスタンプ、メッセージID、埋め込み文字などであり、ログ中間ファイルとして、例えばCSV(Comma-Separated Values)型式でログ中間ファイル格納部37へ出力される。   Here, the log collection information is information necessary for generating a log and can be acquired only when the log output process is called. Specifically, the above-mentioned time stamp, message ID, embedded character, and the like are output to the log intermediate file storage unit 37 in the CSV (Comma-Separated Values) format, for example, as a log intermediate file.

ログ中間ファイルの一例を図13に示す。ログ中間ファイルは、例えばタイムスタンプ、メッセージID、埋め込み文字の順に構成される。1つのログ中間ファイルが、1つのレコードとしてログ中間ファイル格納部37に格納される。なお、この例では埋め込み文字が5つであるが、これに限られるものではない。   An example of the log intermediate file is shown in FIG. The log intermediate file is configured in the order of, for example, a time stamp, a message ID, and embedded characters. One log intermediate file is stored in the log intermediate file storage unit 37 as one record. In this example, there are five embedded characters, but this is not restrictive.

ログ編集処理部32は、業務負荷が低負荷の場合にログ出力処理部31からのログ編集要求を受け、ログ編集処理を行う。具体的には、ログ採取情報のメッセージIDをキーとして、対応するログメッセージ(ログメッセージのテンプレート)をログメッセージ格納部36から取得し、取得したログメッセージにログ採取情報を埋め込んで編集(生成)する。編集結果(編集後のログメッセージ)はログファイル格納部38へ出力される。ログメッセージは、運用監視装置3を管理する監視者が目視でメッセージの意味を確認しやすい形式に編集される。なお、ログメッセージの編集は、サーバ2以外の装置やプログラムが行うようにしてもよい。   The log editing processing unit 32 receives a log editing request from the log output processing unit 31 and performs log editing processing when the business load is low. Specifically, using the message ID of the log collection information as a key, the corresponding log message (log message template) is acquired from the log message storage unit 36, and the log collection information is embedded in the acquired log message for editing (generation). To do. The editing result (the log message after editing) is output to the log file storage unit 38. The log message is edited into a format in which the supervisor who manages the operation monitoring apparatus 3 can easily confirm the meaning of the message visually. The log message may be edited by a device or program other than the server 2.

ここで、ログメッセージ格納部36に格納されたログメッセージのテンプレートの一例を図14に示す。ログメッセージには、エラー(E)、警告(W)、インフォメーション(I)、デバッグ(D)などの種類がある。図14には、エラーメッセージ(ERROR)と警告メッセージ(WARNING)のテンプレートが示されている。例えば、エラーメッセージのテンプレートは、メッセージID(E001)にメッセージ内容(ERROR:001 Error occurred. A=%s、B=%d、C=%x、at %s-%d)が関連付けられている。上記%は埋込識別子といい、上記s、d、xは書式指定子という。%s、%d、%xにログ採取情報が埋め込まれる。ログメッセージの編集処理の詳細については後述する。   An example of a log message template stored in the log message storage unit 36 is shown in FIG. There are types of log messages such as error (E), warning (W), information (I), and debug (D). FIG. 14 shows templates of an error message (ERROR) and a warning message (WARNING). For example, in the error message template, the message content (ERROR: 001 Error occurred. A =% s, B =% d, C =% x, at% s-% d) is associated with the message ID (E001). . The% is called an embedded identifier, and the s, d, and x are called format specifiers. Log collection information is embedded in% s,% d, and% x. Details of the log message editing process will be described later.

ログ出力後処理部33は、業務終了指示などにより、業務処理部30からのログ出力後処理要求を受け、ログ出力後処理を行う。具体的には、ログ出力後処理部33は、業務負荷が高負荷の場合にログ中間ファイル格納部37に格納されたログ採取情報を読み込む。そして、ログ出力後処理部33は、メッセージIDをキーとして対応するログメッセージをログメッセージ格納部36から取得し、取得したログメッセージにログ採取情報を埋め込んで編集(生成)する。   The log output post-processing unit 33 receives a log output post-processing request from the business processing unit 30 according to a business end instruction or the like, and performs post-log output processing. Specifically, the log output post-processing unit 33 reads the log collection information stored in the log intermediate file storage unit 37 when the business load is high. Then, the log output post-processing unit 33 acquires the corresponding log message from the log message storage unit 36 using the message ID as a key, and edits (generates) the log collection information embedded in the acquired log message.

また、ログ出力後処理部33は、編集したログメッセージと、ログファイル格納部38内のログメッセージ(低負荷時に編集されたログメッセージ)とをマージ(併合)し、タイムスタンプ順などでソート(整列)してログファイル格納部38に出力する。所定の業務を遂行している間には、業務負荷が低負荷のときと高負荷のときが混在する場合がある。そのため、業務終了後に、それぞれの負荷時に編集されたログメッセージをマージする必要がある。そこで、ログ出力後処理部33は、業務終了後に、業務終了後に編集される高負荷時のログメッセージと、低負荷の場合に編集され、ログファイル格納部38に格納されたログメッセージとをマージし、ソートして出力する。ログ出力後処理部33によるマージ処理及びソート処理の詳細については後述する。なお、ログ出力後処理部33は、同一機器(プログラム)内に配置する場合と、別の機器(プログラム)に配置する場合が考えられる。   Further, the log output post-processing unit 33 merges the edited log message and the log message in the log file storage unit 38 (the log message edited at low load) and sorts them in the order of the time stamp ( And output to the log file storage unit 38. While a predetermined task is being performed, there may be a case where the workload is low and the load is high. Therefore, it is necessary to merge log messages edited at each load after the end of business. Therefore, the post-log output processing unit 33 merges the log message at the time of high load that is edited after the end of the business and the log message that is edited at the time of low load and stored in the log file storage unit 38. And sort and output. Details of the merge processing and sort processing by the log output post-processing unit 33 will be described later. The log output post-processing unit 33 can be arranged in the same device (program) or in another device (program).

業務負荷判定処理部34は、業務負荷判定基準を参照し、業務処理部30の負荷を判定する。業務負荷判定基準としては、例えば、時間帯によるもの、データ送受信量によるもの、あらかじめ業務処理部30の負荷が高負荷か低負荷に設定されているものなどがある。具体的には、負荷判定時の時間が所定の時間帯にある場合、業務処理部30の負荷は高い(高負荷)と判定する。また、単位時間あたりのデータ送受信量が所定の閾値を超えている場合、業務処理部30は高負荷と判定する。また、あらかじめ業務処理部30の負荷が設定されている場合、設定された負荷に基づいて、業務処理部30の負荷を判定する。例えば、あらかじめ負荷が高負荷と設定されている場合、業務処理部30の負荷は高負荷と判定される。   The business load determination processing unit 34 determines the load of the business processing unit 30 with reference to the business load determination standard. Examples of the business load determination criteria include a time zone, a data transmission / reception amount, and a job processing unit 30 with a high load or a low load set in advance. Specifically, when the load determination time is in a predetermined time zone, it is determined that the load of the business processing unit 30 is high (high load). Further, when the data transmission / reception amount per unit time exceeds a predetermined threshold, the business processing unit 30 determines that the load is high. Further, when the load of the business processing unit 30 is set in advance, the load of the business processing unit 30 is determined based on the set load. For example, when the load is set as a high load in advance, the load of the business processing unit 30 is determined as a high load.

業務負荷格納部35は、業務負荷判定処理部34が負荷を判定する際に用いる業務負荷判定基準を格納する。業務負荷判定基準(時間帯による基準)の一例を図15に示す。例えば、始業時(9時から10時)、昼休み前(11時から12時)、終業前(16時から17時)は注文などの依頼が集中するなどで高負荷となり、それ以外は依頼が集中せずに低負荷となるという経験則があるとする。その場合、図15に示すような業務負荷判定基準となる。このような業務負荷判定基準を用いて高負荷であるか低負荷であるかが判定される。   The business load storage unit 35 stores a business load determination criterion used when the business load determination processing unit 34 determines a load. FIG. 15 shows an example of the business load determination standard (standard based on time zone). For example, during the start of work (9:00 to 10:00), before lunch break (11:00 to 12:00), and before the end of work (16:00 to 17:00), it becomes a heavy load due to the concentration of requests such as orders. Suppose that there is an empirical rule of low load without concentration. In that case, the business load determination criteria are as shown in FIG. It is determined whether the load is high or low using such a business load determination criterion.

ログメッセージ格納部36には、上述したように、ログメッセージ(ログメッセージのテンプレート)がメッセージIDと関連付けられて格納されている。   As described above, the log message storage unit 36 stores a log message (a log message template) in association with a message ID.

次に、実施の形態に係る通信制御プログラムを実装するサーバ2を実現するためのハードウェア構成の一例について図4を用いて説明する。ハードウェア構成は、例えば、CPU41、HDD(Hard Disk Drive)42、RAM(Random Access Memory)43、ROM(Read Only Memory)44、グラフィック処理装置45、入力インタフェース(I/F)46、通信インタフェース(I/F)47、バス48を備えている。CPU41、HDD42、RAM43、ROM44、グラフィック処理装置45、入力インタフェース(I/F)46、通信インタフェース(I/F)47は、例えば、バス48を介して互いに接続されている。   Next, an example of a hardware configuration for realizing the server 2 that implements the communication control program according to the embodiment will be described with reference to FIG. The hardware configuration includes, for example, a CPU 41, a HDD (Hard Disk Drive) 42, a RAM (Random Access Memory) 43, a ROM (Read Only Memory) 44, a graphic processing device 45, an input interface (I / F) 46, a communication interface ( I / F) 47 and bus 48 are provided. The CPU 41, HDD 42, RAM 43, ROM 44, graphic processing device 45, input interface (I / F) 46, and communication interface (I / F) 47 are connected to each other via a bus 48, for example.

CPU41は、バス48を介して、HDD42などに格納されるサーバ2の各種処理を行うためのプログラム(例えば、通信制御プログラムなど)を読み込み、読み込んだプログラムをRAM43に一時的に格納し、そのプログラムにしたがって各種処理を行うものである。   The CPU 41 reads a program (for example, a communication control program) for performing various processes of the server 2 stored in the HDD 42 or the like via the bus 48, temporarily stores the read program in the RAM 43, and the program Various processes are performed according to the above.

HDD42には、サーバ2の各種処理を行うためのアプリケーションプログラムや、サーバ2の処理に必要なデータなどが格納される。   The HDD 42 stores application programs for performing various processes of the server 2, data necessary for the processes of the server 2, and the like.

RAM43は、揮発性メモリであって、CPU41に実行させるためのOS(Operating System)プログラムやアプリケーションプログラムの一部が一時的に格納される。また、RAM43には、CPU41による処理に必要な各種データが格納される。   The RAM 43 is a volatile memory and temporarily stores a part of an OS (Operating System) program and application programs to be executed by the CPU 41. The RAM 43 stores various data necessary for processing by the CPU 41.

ROM44は、不揮発性メモリであって、ブートプログラムやBIOS(Basic Input/Output System)などのプログラムを記憶する。   The ROM 44 is a non-volatile memory, and stores programs such as a boot program and BIOS (Basic Input / Output System).

グラフィック処理装置45は、モニタ400と接続可能であって、モニタ400に表示させる情報を生成するものである。   The graphic processor 45 can be connected to the monitor 400 and generates information to be displayed on the monitor 400.

入力インタフェース(I/F)46は、キーボード401やマウス402などを介して入力される情報を受け付けるものである。   The input interface (I / F) 46 receives information input via the keyboard 401, the mouse 402, or the like.

通信インタフェース(I/F)47は、外部(運用監視装置3や利用者が使用する端末など)とネットワーク4を介してデータの送受信を行うものである。   The communication interface (I / F) 47 performs data transmission / reception via the network 4 with the outside (such as the operation monitoring device 3 or a terminal used by a user).

バス48は、各装置間の制御信号、データ信号などの授受を媒介する経路である。なお、運用監視装置3を実現するためのハードウェア構成も、サーバ2と同様、CPU、HDD、各種インタフェースなどを含む。   The bus 48 is a path that mediates transmission / reception of control signals, data signals, and the like between the devices. Note that the hardware configuration for realizing the operation monitoring apparatus 3 includes a CPU, an HDD, various interfaces, and the like, similar to the server 2.

次に、上述した業務処理部30が高負荷の場合の処理の流れについて図5、図16を用いて説明する。図5に示すように、サーバ2は、証券取引などにおける注文のために利用者によって送信されたメッセージを受信する。ここで、メッセージ受信による注文のメッセージ送信がログ出力対象の事象であるとすると、業務処理部30は、ログ出力対象事象が発生したと認識する。業務処理部30は、ログ出力対象事象が発生したことにより、ログ採取情報(例えば、タイムスタンプ、メッセージID、埋め込み文字など)を取得する。埋め込み文字は、事象発生時のプログラムの状態を示す情報であり、主にプログラムの変数値である。図16に示す例では、埋め込み文字は1番目から5番目まであり、順に変数Aの値(aaa)、変数Bの値(1)、変数Cの値(16)、変数Dの値(ddd)、変数Eの値(5)である。   Next, the flow of processing when the above-described job processing unit 30 is heavily loaded will be described with reference to FIGS. As shown in FIG. 5, the server 2 receives a message transmitted by a user for an order in a securities transaction or the like. Here, if the message transmission of the order by message reception is an event to be logged, the business processing unit 30 recognizes that a log output event has occurred. The business processing unit 30 acquires log collection information (for example, time stamp, message ID, embedded character, etc.) when a log output target event occurs. The embedded character is information indicating the state of the program when the event occurs, and is mainly a variable value of the program. In the example shown in FIG. 16, there are embedded characters from the first to the fifth, in order of the value of variable A (aaa), the value of variable B (1), the value of variable C (16), and the value of variable D (ddd). , The value of the variable E (5).

業務処理部30は、ログ採取情報の取得後、ログ出力処理部31に対してログ出力依頼を発行する。ログ出力処理部31は、業務負荷判定処理部34に対して、負荷状況判定要求を発行する。業務負荷判定処理部34は、業務負荷格納部35から業務負荷判定基準を取得し、取得した業務負荷判定基準に基づいて、例えば業務負荷を高負荷と判定する。ログ出力処理部31は、業務負荷が高負荷のため、取得したログ採取情報のみをログ中間ファイルとしてログ中間ファイル格納部37へ出力する。出力されるログ中間ファイルの一例が、図16中に詳細として記載されている。   The business processing unit 30 issues a log output request to the log output processing unit 31 after acquiring the log collection information. The log output processing unit 31 issues a load status determination request to the business load determination processing unit 34. The business load determination processing unit 34 acquires a business load determination standard from the business load storage unit 35, and determines, for example, the business load as a high load based on the acquired business load determination standard. The log output processing unit 31 outputs only the acquired log collection information to the log intermediate file storage unit 37 as a log intermediate file because the business load is high. An example of the output log intermediate file is described in detail in FIG.

このとき、運用監視装置3は、監視プログラム20により、ログ中間ファイルとログファイルを監視し、監視対象の事象が発生すると、監視結果を監視画面21に出力する。後述する低負荷の場合も同様である。   At this time, the operation monitoring apparatus 3 monitors the log intermediate file and the log file by the monitoring program 20 and outputs a monitoring result to the monitoring screen 21 when an event to be monitored occurs. The same applies to a low load described later.

一方、業務処理部30が低負荷の場合の処理の流れについて図6、図17を用いて説明する。業務負荷判定処理部34による業務負荷を判定するまでの処理は、図5に示す高負荷の場合と同様であるため説明を省略する。業務負荷判定処理部34が、業務負荷の判定の結果、低負荷であると判定すると、ログ出力処理部31は、ログ編集処理部32に対してログ編集要求を発行する。このとき、ログ出力処理部31は、ログ採取情報をログ編集処理部32へ渡す。   On the other hand, the flow of processing when the business processing unit 30 is lightly loaded will be described with reference to FIGS. Since the processing until the business load is determined by the business load determination processing unit 34 is the same as the case of the high load shown in FIG. When the business load determination processing unit 34 determines that the load is low as a result of the business load determination, the log output processing unit 31 issues a log editing request to the log editing processing unit 32. At this time, the log output processing unit 31 passes the log collection information to the log editing processing unit 32.

ログ編集処理部32は、ログ出力処理部31から渡されたログ採取情報に含まれるメッセージIDをキーとして、ログメッセージ格納部36から対応するログメッセージのテンプレートを取得する。ログ編集処理部32は、取得したログメッセージのテンプレートに従ってログメッセージを編集(生成)する。すなわち、ログ編集処理部32は、テンプレートの文字列を1文字ずつ順に解析し、埋め込み文字を埋め込む位置が出現(埋込識別子が出現)した場合、取得したログ採取情報の埋め込み文字を1項目ずつ変換しながらログメッセージを編集する。ログメッセージの編集処理の詳細については後述する。ログ編集処理部32は、編集されたログメッセージをログファイル格納部38に出力する。編集されたログメッセージの一例が、図17中に詳細として記載されている。   The log editing processing unit 32 acquires a corresponding log message template from the log message storage unit 36 using the message ID included in the log collection information passed from the log output processing unit 31 as a key. The log editing processing unit 32 edits (generates) a log message according to the acquired log message template. That is, the log editing processing unit 32 sequentially analyzes the character string of the template character by character, and when a position where the embedded character is embedded appears (embedding identifier appears), the embedded character of the acquired log collection information is displayed item by item. Edit log messages while converting. Details of the log message editing process will be described later. The log editing processing unit 32 outputs the edited log message to the log file storage unit 38. An example of the edited log message is described in detail in FIG.

次に、上述したログ出力後処理部33によるログ出力後処理について図7、図16を用いて説明する。監視者などから業務終了指示が出され、業務処理部30が、所定の条件を満たした場合、すなわち業務終了事象を検知した場合、ログ出力後処理部33に対してログ出力後処理要求を発行する。ログ出力後処理部33は、ログ中間ファイル格納部37のレコードを読み込み、1レコードごとに以下のようにログメッセージを編集(生成)する。   Next, post-log output processing by the log output post-processing unit 33 will be described with reference to FIGS. When a business end instruction is issued from a monitor or the like and the business processing unit 30 satisfies a predetermined condition, that is, when a business end event is detected, a log output post-processing request is issued to the log output post-processing unit 33 To do. The log output post-processing unit 33 reads a record in the log intermediate file storage unit 37 and edits (generates) a log message for each record as follows.

ログ出力後処理部33は、読み込んだレコードのメッセージIDをキーとして、ログメッセージ格納部36から対応するログメッセージのテンプレートを取得する。ログ出力後処理部33は、取得したログメッセージのテンプレートに対して、レコードに含まれるタイムスタンプやその他の埋め込み文字などを反映し、ログメッセージを編集する。テンプレートにタイムスタンプや埋め込み文字を反映させる方法は、上述した低負荷時のログ編集処理部32による方法と同様である。このように、ログメッセージの編集処理を業務終了後などに後処理として行うことで、業務中の1つの事象のログ出力にかかる処理時間を短縮でき、業務の処理性能を向上させることができる。   The log output post-processing unit 33 acquires a corresponding log message template from the log message storage unit 36 using the message ID of the read record as a key. The log output post-processing unit 33 reflects the time stamp and other embedded characters included in the record on the acquired log message template, and edits the log message. The method of reflecting the time stamp and the embedded character in the template is the same as the method by the log editing processing unit 32 at the time of low load described above. As described above, the log message editing process is performed as a post process after the end of the work, so that the processing time required to output the log of one event in the work can be shortened and the work processing performance can be improved.

ログ出力後処理部33は、ログファイル格納部38のログメッセージ(低負荷時に編集されたログメッセージ)をすべて読み込む。ログ出力後処理部33は、上記編集したログメッセージと、ログファイル格納部38から読み込んだログメッセージとをマージし、例えばタイムスタンプの昇順にソートする。ログ出力後処理部33は、マージしてソートしたログメッセージをログファイル格納部38に出力する。なお、業務が終了しているため、運用監視装置3による監視も終了する。   The log output post-processing unit 33 reads all log messages in the log file storage unit 38 (log messages edited at low load). The log output post-processing unit 33 merges the edited log message and the log message read from the log file storage unit 38 and sorts the log messages in ascending order of time stamps, for example. The log output post-processing unit 33 outputs the log messages merged and sorted to the log file storage unit 38. In addition, since the work is finished, the monitoring by the operation monitoring apparatus 3 is also finished.

次に、実施の形態に係る通信制御プログラムを実装するサーバ2におけるログ出力の処理フローの一例について図8を用いて説明する。図8に示すように、サーバ2(通信制御プログラム)は、業務における事象(例えば、証券取引などの事象)が発生したか否かを判断し(ステップS801)、事象が発生したと判断した場合(ステップS801でYes)、発生した事象に応じた業務処理を行う(ステップS802)。なお、事象が発生したと判断しない場合(ステップS801でNo)、ステップS801へ戻る。   Next, an example of a processing flow of log output in the server 2 that implements the communication control program according to the embodiment will be described with reference to FIG. As shown in FIG. 8, when the server 2 (communication control program) determines whether or not an event in business (for example, an event such as a securities transaction) has occurred (step S801), and determines that an event has occurred (Yes in step S801), business processing corresponding to the event that has occurred is performed (step S802). If it is not determined that an event has occurred (No in step S801), the process returns to step S801.

サーバ2は、ログ出力対象の事象(例えば、メッセージ送信事象)が発生したか否かを判断し(ステップS803)、発生した場合(ステップS803でYes)、ログ採取情報を取得し(ステップS804)、ログ出力依頼(ログ出力処理の呼出)を発行する(ステップS805)。ログ出力処理については後述する。なお、ログ出力対象の事象が発生していない場合(ステップS803でNo)、ステップS806へ進む。   The server 2 determines whether a log output target event (for example, a message transmission event) has occurred (step S803), and if it occurs (Yes in step S803), acquires log collection information (step S804). Then, a log output request (call of log output processing) is issued (step S805). The log output process will be described later. If no log output target event has occurred (No in step S803), the process advances to step S806.

サーバ2は、受け付けた事象が業務終了の事象であるか否かを判断し(ステップS806)、業務終了の事象である場合(ステップS806でYes)、ログ出力後処理要求(ログ出力後処理の呼出)を発行する(ステップS807)。ログ出力後処理については後述する。   The server 2 determines whether the received event is a business end event (step S806). If the received event is a business end event (Yes in step S806), the log output post-processing request (log output post-processing (Call) is issued (step S807). The log output post-processing will be described later.

次に、上記ログ出力処理のサブルーチンについて図9を用いて説明する。サーバ2(通信制御プログラム)は、業務処理部30の負荷を判定させるため、負荷状況判定要求(業務負荷判定処理の呼出)を発行する(ステップS901)。業務負荷判定処理については後述する。サーバ2は、業務処理部30の負荷が高負荷か否かを判断し(ステップS902)、高負荷である場合(ステップS902でYes)、取得されたログ採取情報をログ中間ファイル格納部37へ出力する(ステップS903)。一方、高負荷でない場合(ステップS902でNo)、ログ編集要求(ログ編集処理の呼出)を発行する(ステップS904)。ログ編集処理については後述する。   Next, the log output processing subroutine will be described with reference to FIG. The server 2 (communication control program) issues a load status determination request (call of a business load determination process) in order to determine the load of the business processing unit 30 (step S901). The business load determination process will be described later. The server 2 determines whether or not the load of the business processing unit 30 is high (step S902). If the load is high (Yes in step S902), the acquired log collection information is sent to the log intermediate file storage unit 37. Output (step S903). On the other hand, if the load is not high (No in step S902), a log edit request (call log edit processing) is issued (step S904). The log editing process will be described later.

次に、上記業務負荷判定処理のサブルーチンについて図10を用いて説明する。サーバ2(通信制御プログラム)は、業務負荷を、例えばデフォルト値の低負荷とセットし(ステップS1001)、業務負荷格納部35から業務負荷判定基準を取得する(ステップS1002)。サーバ2は、取得した業務負荷判定基準が時間帯による判定基準か否かを判断し(ステップS1003)、時間帯によるものの場合(ステップS1003でYes)、現在の時刻の情報を取得する(ステップS1004)。   Next, a subroutine for the business load determination process will be described with reference to FIG. The server 2 (communication control program) sets the business load as, for example, a default low load (step S1001), and obtains the business load determination criterion from the business load storage unit 35 (step S1002). The server 2 determines whether or not the acquired business load determination criterion is a determination criterion based on a time zone (step S1003), and if it is based on a time zone (Yes in step S1003), acquires information on the current time (step S1004). ).

サーバ2は、取得した時刻が高負荷の時間帯であるか否かを判断し(ステップS1005)、高負荷の時間帯の場合(ステップS1005でYes)、業務負荷を高負荷とセットする(ステップS1006)。   The server 2 determines whether or not the acquired time is a high load time zone (step S1005). If the acquired time is a high load time zone (Yes in step S1005), the server 2 sets the work load as a high load (step S1005). S1006).

一方、取得した業務負荷判定基準が時間帯による判定基準でない場合(ステップS1003でNo)、サーバ2は、単位時間あたりのデータ送受信量による判定基準か否かを判断し(ステップS1007)、データ送受信量によるものの場合(ステップS1007でYes)、単位時間あたりのデータ送受信量を取得する(ステップS1008)。サーバ2は、取得したデータ送受信量が所定の閾値以上であるか否かを判断し(ステップS1009)、所定の閾値以上である場合(ステップS1009でYes)、業務負荷を高負荷とセットする(ステップS1010)。なお、所定の閾値以上でない場合(ステップS1009でNo)、業務負荷判定処理を終了する。   On the other hand, if the acquired business load determination criterion is not the determination criterion based on the time zone (No in step S1003), the server 2 determines whether or not the determination criterion is based on the data transmission / reception amount per unit time (step S1007). If it is based on the amount (Yes in step S1007), the data transmission / reception amount per unit time is acquired (step S1008). The server 2 determines whether or not the acquired data transmission / reception amount is equal to or greater than a predetermined threshold (step S1009), and if it is equal to or greater than the predetermined threshold (Yes in step S1009), sets the business load as a high load ( Step S1010). If it is not equal to or greater than the predetermined threshold (No in step S1009), the business load determination process ends.

また、取得した業務負荷判定基準が単位時間あたりのデータ送受信量による判定基準でない場合(ステップS1007でNo)、サーバ2は、あらかじめ負荷が設定されたもの、すなわち高負荷であるか又は低負荷であるかあらかじめ負荷が設定されているか否かを判断し(ステップS1011)、あらかじめ負荷が設定されている場合(ステップS1011でYes)、設定が高負荷であるか否かを判断し(ステップS1012)、高負荷である場合(ステップS1012でYes)、業務負荷を高負荷とセットする(ステップS1013)。なお、あらかじめ負荷が設定されていない場合(ステップS1011でNo)及び設定が高負荷でない場合(ステップS1012でNo)、業務負荷判定処理を終了する。   If the acquired business load determination criterion is not a determination criterion based on the amount of data transmitted / received per unit time (No in step S1007), the server 2 has a load set in advance, that is, a high load or a low load. It is determined whether or not a load is set in advance (step S1011). If the load is set in advance (Yes in step S1011), it is determined whether or not the setting is a high load (step S1012). If the load is high (Yes in step S1012), the business load is set to be high (step S1013). If the load is not set in advance (No in step S1011) and the setting is not high (No in step S1012), the business load determination process ends.

次に、上記ログ編集処理のサブルーチンについて図11を用いて説明する。サーバ2(通信制御プログラム)は、ログメッセージ格納部36からログメッセージのテンプレートを取得し(ステップS1101)、取得したログメッセージのテンプレートにログ採取情報を埋め込んで編集する(ステップS1102)。ログメッセージの編集処理の詳細については後述する。サーバ2は、編集したログメッセージをログファイル格納部38へ出力する(ステップS1103)。   Next, the log editing process subroutine will be described with reference to FIG. The server 2 (communication control program) acquires a log message template from the log message storage unit 36 (step S1101), and embeds the log collection information in the acquired log message template for editing (step S1102). Details of the log message editing process will be described later. The server 2 outputs the edited log message to the log file storage unit 38 (step S1103).

次に、上記ログ出力後処理のサブルーチンについて図12を用いて説明する。サーバ2(通信制御プログラム)は、ログ中間ファイル格納部37から1つのレコードを読み込み(ステップS1201)、ログメッセージ格納部36からステップS1201で読み込んだレコードのメッセージIDに対応するログメッセージのテンプレートを取得する(ステップS1202)。サーバ2は、取得したログメッセージのテンプレートにログ採取情報を埋め込んで編集する(ステップS1203)。ログメッセージの編集処理の詳細については後述する。このとき、編集したログメッセージを不図示のバッファに格納する(ステップS1204)。サーバ2は、次のレコードがないか否かを判断し(ステップS1205)、次のレコードがある場合(ステップS1205でNo)、ステップS1201へ戻る。   Next, the log output post-processing subroutine will be described with reference to FIG. The server 2 (communication control program) reads one record from the log intermediate file storage unit 37 (step S1201), and acquires a log message template corresponding to the message ID of the record read in step S1201 from the log message storage unit 36. (Step S1202). The server 2 compiles the log collection information in the acquired log message template and edits it (step S1203). Details of the log message editing process will be described later. At this time, the edited log message is stored in a buffer (not shown) (step S1204). The server 2 determines whether or not there is a next record (step S1205). If there is a next record (No in step S1205), the process returns to step S1201.

一方、次のレコードがない場合(ステップS1205でYes)、サーバ2は、ログファイル格納部38から全てのログメッセージ(低負荷時に編集されたログメッセージ)を読み込み、バッファにマージ(追加)する(ステップS1206)。そして、サーバ2は、バッファ中の全てのログメッセージをタイムスタンプ順でソートする(ステップS1207)。ログメッセージのマージ処理及びソート処理の詳細については後述する。サーバ2は、バッファ中の全てのログメッセージをログファイル格納部38へ出力する(ステップS1208)。   On the other hand, if there is no next record (Yes in step S1205), the server 2 reads all log messages (log messages edited at low load) from the log file storage unit 38 and merges (adds) them to the buffer ( Step S1206). Then, the server 2 sorts all log messages in the buffer in order of time stamp (step S1207). Details of the log message merge processing and sort processing will be described later. The server 2 outputs all log messages in the buffer to the log file storage unit 38 (step S1208).

ここで、上記ログメッセージの編集処理のサブルーチンについて図18を用いて説明する。以下では、処理の主体をログ出力後処理部33として説明しているが、低負荷時におけるログメッセージの編集処理の場合には、処理の主体はログ編集処理部32となる。   The log message editing process subroutine will be described with reference to FIG. In the following description, the processing subject is described as the log output post-processing unit 33. However, in the case of log message editing processing at low load, the processing subject is the log editing processing unit 32.

ログ出力後処理部33は、取得したテンプレートの先頭から最初のコーテーションマークが検出されるまでのデータを削除する(ステップS1801a)。ログ出力後処理部33は、削除したコーテーションマークの次の文字を読み込み位置とするとともに、埋め込み文字カウンタNを1とする(ステップS1801b)。このとき、ログ出力後処理部33は、削除したテンプレートの先頭にレコードから取得したタイムスタンプを埋め込む。なお、この例では、テンプレートのデータの削除をコーテーションマークの検出に基づいて行っているが、コーテーションマークに限定されるものではなく、他のマークや目印などであってもよい。   The log output post-processing unit 33 deletes data from the beginning of the acquired template until the first quotation mark is detected (step S1801a). The log output post-processing unit 33 sets the character next to the deleted quotation mark as the reading position and sets the embedded character counter N to 1 (step S1801b). At this time, the log output post-processing unit 33 embeds the time stamp acquired from the record at the head of the deleted template. In this example, the deletion of the template data is performed based on the detection of the quotation mark. However, the present invention is not limited to the quotation mark, and may be another mark or a mark.

ログ出力後処理部33は、読み込み位置から1文字を読み込む(ステップS1802)。ここで取得したテンプレートが、図14に示すテンプレートのうちのメッセージIDがE001のテンプレートの場合、読み込まれる文字は“E”となる。   The log output post-processing unit 33 reads one character from the reading position (step S1802). When the template acquired here is a template with the message ID E001 in the templates shown in FIG. 14, the read character is “E”.

ログ出力後処理部33は、読み込んだ文字が埋込識別子%であるか否かを判断する(ステップS1803)。読み込んだ文字が埋込識別子%である場合(ステップS1803でYes)、ログ出力後処理部33は、更に1文字を読み込み(ステップS1804)、読み込んだ文字がどのような書式指定子であるかを判断する(ステップS1805)。   The log output post-processing unit 33 determines whether or not the read character is the embedded identifier% (step S1803). When the read character is the embedded identifier% (Yes in step S1803), the log output post-processing unit 33 further reads one character (step S1804) and determines what format specifier the read character is. Judgment is made (step S1805).

ここでは、埋込識別子に続く文字(書式指定子)によってどのような変換を行うかを、例えば図19に示す埋め込み文字変換テーブルを用いて決めている。例えば、書式指定子が“s”の場合には、埋め込み文字を変換せずにそのまま埋め込む。書式指定子が“d”の場合には、埋め込み文字を10進数に変換して埋め込む。書式指定子が“x”の場合には、埋め込み文字を16進数に変換して埋め込む。なお、この例では、3種類の変換の例を挙げているが、数値の桁数を指定するなど、更に高度な編集を行うようにしてもよい。   Here, what conversion is performed by the character (format specifier) following the embedded identifier is determined using, for example, an embedded character conversion table shown in FIG. For example, when the format specifier is “s”, the embedded character is embedded as it is without being converted. When the format specifier is “d”, the embedded character is converted into a decimal number and embedded. When the format specifier is “x”, the embedded character is converted into a hexadecimal number and embedded. In this example, three types of conversion examples are given, but more advanced editing such as specifying the number of digits of numerical values may be performed.

ログ出力後処理部33は、書式指定子が“s”の場合、ログメッセージ(テンプレート)にN番目の埋め込み文字を連結(埋め込み)する(ステップS1806)。書式指定子が“d”の場合、ログ出力後処理部33は、N番目の埋め込み文字を10進数に変換し(ステップS1807)、変換後の文字列をログメッセージに連結する(ステップS1808)。書式指定子が“x”の場合、ログ出力後処理部33は、N番目の埋め込み文字を16進数に変換し(ステップS1809)、変換後の文字列をログメッセージに連結する(ステップS1810)。   When the format specifier is “s”, the log output post-processing unit 33 concatenates (embeds) the Nth embedded character in the log message (template) (step S1806). When the format specifier is “d”, the log output post-processing unit 33 converts the Nth embedded character into a decimal number (step S1807), and concatenates the converted character string to the log message (step S1808). When the format specifier is “x”, the log output post-processing unit 33 converts the Nth embedded character into a hexadecimal number (step S1809), and concatenates the converted character string to the log message (step S1810).

連結後、ログ出力後処理部33は、埋め込み文字カウンタNを埋め込み文字数に応じてインクリメントする(ステップS1811)。ログ出力後処理部33は、テンプレートの読み込み位置の示す文字が最初のコーテーションマークに対応するコーテーションマークであるか否かを判断する(ステップS1812)。ログ出力後処理部33は、対応するコーテーションマークの場合(ステップS1812でYes)には、テンプレートの最後の文字に達したと判断し、ステップS1814においてログメッセージに連結された当該対応するコーテーションマークを削除してログメッセージの編集処理を終了する。一方、対応するコーテーションマークでない場合(ステップS1812でNo)、読み込み位置をインクリメントする(ステップS1813)。   After concatenation, the log output post-processing unit 33 increments the embedded character counter N according to the number of embedded characters (step S1811). The log output post-processing unit 33 determines whether or not the character indicating the template reading position is a quotation mark corresponding to the first quotation mark (step S1812). In the case of the corresponding quotation mark (Yes in step S1812), the log output post-processing unit 33 determines that the last character of the template has been reached, and the corresponding quotation mark linked to the log message in step S1814 is determined. Delete the log message and finish the log message editing process. On the other hand, if it is not the corresponding quotation mark (No in step S1812), the reading position is incremented (step S1813).

一方、ステップS1803において、読み込んだ文字が埋込識別子でない場合(ステップS1803でNo)、ログ出力後処理部33は、ログメッセージに読み込んだ文字を連結する(ステップS1814)。   On the other hand, if the read character is not an embedded identifier in step S1803 (No in step S1803), the log output post-processing unit 33 concatenates the read character to the log message (step S1814).

次に、上記ログメッセージのマージ処理及びソート処理の具体的な例について図20を用いて説明する。図20に示すように、ログ出力後処理部33は、ログ中間ファイル格納部37から読み込んだログ中間ファイルと、ログメッセージ格納部36から取得したテンプレートとに基づいて、ログメッセージを編集する。編集されたログメッセージはバッファに格納(追加)される。   Next, a specific example of the log message merge processing and sort processing will be described with reference to FIG. As illustrated in FIG. 20, the log output post-processing unit 33 edits the log message based on the log intermediate file read from the log intermediate file storage unit 37 and the template acquired from the log message storage unit 36. The edited log message is stored (added) in the buffer.

その後、次のレコード(ログ中間ファイル)がないと判断されると、ログ出力後処理部33は、ログファイル格納部38から全てのログメッセージ(低負荷時に編集されたログメッセージ)を読み込む。この例では、全てのログメッセージのうちの2つのログメッセージが表記されている。読み込まれた全てのログメッセージは上記バッファにマージ(追加)される。四角い破線で囲まれたものがマージされたログメッセージである。   Thereafter, when it is determined that there is no next record (log intermediate file), the log output post-processing unit 33 reads all log messages (log messages edited at low load) from the log file storage unit 38. In this example, two log messages among all log messages are shown. All read log messages are merged (added) into the buffer. The merged log message is enclosed by a square broken line.

ログ出力後処理部33は、バッファに格納されたログメッセージを、例えばタイムスタンプをキーにして、昇順にソートし、ログファイル格納部38へ出力する。なお、ソートの方法は、タイムスタンプをキーにして行うものに限らず、例えばエラーコードの重要度に応じてソートするようにしてもよい。   The log output post-processing unit 33 sorts the log messages stored in the buffer in ascending order using, for example, a time stamp as a key, and outputs the log message to the log file storage unit 38. Note that the sorting method is not limited to the method using the time stamp as a key. For example, the sorting may be performed according to the importance of the error code.

上述したようなサーバ2(通信制御プログラム)によれば、ログ出力によるシステムの性能劣化の影響を抑えることができる。   According to the server 2 (communication control program) as described above, it is possible to suppress the influence of system performance deterioration due to log output.

なお、上述した実施の形態では、サーバ2の主な処理をCPUによるソフトウェア処理によって実行するものとして説明したが、この処理の全部又は一部をハードウェアによって実現するようにしてもよい。   In the above-described embodiment, the main processing of the server 2 has been described as being executed by software processing by the CPU. However, all or part of this processing may be realized by hardware.

また、上述した実施の形態は、上述したものに限定されるものではなく、実施の形態の要旨を逸脱しない範囲において種々の変更を加えることができる。   Further, the above-described embodiment is not limited to the above-described embodiment, and various changes can be made without departing from the gist of the embodiment.

1 通信制御システム
2 サーバ
3 運用監視装置
4 ネットワーク
20 監視プログラム
21 監視画面
30 業務処理部
31 ログ出力処理部
32 ログ編集処理部
33 ログ出力後処理部
34 業務負荷判定処理部
35 業務負荷格納部
36 ログメッセージ格納部
37 ログ中間ファイル格納部
38 ログファイル格納部
41 CPU
42 HDD
43 RAM
44 ROM
45 グラフィック処理装置
46 入力インタフェース
47 通信インタフェース
48 バス
400 モニタ
401 キーボード
402 マウス
DESCRIPTION OF SYMBOLS 1 Communication control system 2 Server 3 Operation monitoring apparatus 4 Network 20 Monitoring program 21 Monitoring screen 30 Business processing part 31 Log output processing part 32 Log edit processing part 33 Log output post-processing part 34 Business load judgment processing part 35 Business load storage part 36 Log message storage unit 37 Log intermediate file storage unit 38 Log file storage unit 41 CPU
42 HDD
43 RAM
44 ROM
45 graphic processing unit 46 input interface 47 communication interface 48 bus 400 monitor 401 keyboard 402 mouse

Claims (6)

ログ出力の処理を制御する通信制御プログラムであって、
ログ出力の呼び出しに基づいて、前記呼び出し時に取得可能な、ログを生成するために必要な情報を取得するステップと、
取得された前記情報をログ中間ファイル情報として、ログの生成が開始される前に所定の記憶領域に出力するステップとを、
コンピュータに実行させることを特徴とする通信制御プログラム。
A communication control program for controlling log output processing,
Obtaining information necessary to generate a log, which can be acquired at the time of the call, based on the call of the log output;
Outputting the acquired information as log intermediate file information to a predetermined storage area before log generation is started,
A communication control program executed by a computer.
前記ログ出力の対象業務における業務処理を実行する業務処理部の負荷が所定の負荷を超えているか否かを判断するステップを更に有し、
前記所定の負荷を超えていると判断された場合、取得された前記情報を前記ログ中間ファイル情報として出力することを特徴とする請求項1に記載の通信制御プログラム。
A step of determining whether or not a load of a business processing unit that executes a business process in the target business of the log output exceeds a predetermined load;
The communication control program according to claim 1, wherein when it is determined that the predetermined load is exceeded, the acquired information is output as the log intermediate file information.
時間帯、単位時間あたりのデータ送受信量、又はあらかじめ設定された負荷状況に基づいて、前記業務処理部の負荷が前記所定の負荷を超えているか否かを判断することを特徴とする請求項2に記載の通信制御プログラム。   3. The apparatus according to claim 2, wherein it is determined whether or not a load of the business processing unit exceeds the predetermined load based on a time zone, a data transmission / reception amount per unit time, or a preset load status. The communication control program described in 1. 所定の条件を満たした場合に、前記所定の記憶領域の前記ログ中間ファイル情報を用いてログを生成し、生成された前記ログを出力するステップを更に有する請求項1から3のいずれか1つに記載の通信制御プログラム。   4. The method according to claim 1, further comprising a step of generating a log using the log intermediate file information in the predetermined storage area and outputting the generated log when a predetermined condition is satisfied. The communication control program described in 1. ログ出力の処理を制御する通信制御装置であって、
ログ出力の呼び出しに基づいて、前記呼び出し時に取得可能な、ログを生成するために必要な情報を取得する取得部と、
取得された前記情報をログ中間ファイル情報として、ログの生成が開始される前に所定の記憶領域に出力する出力部とを、
備えることを特徴とする通信制御装置。
A communication control device for controlling log output processing,
An acquisition unit that acquires information necessary for generating a log, which can be acquired at the time of the call, based on a log output call;
An output unit that outputs the acquired information as log intermediate file information to a predetermined storage area before log generation is started;
A communication control apparatus comprising:
ログ出力の処理を制御する通信制御方法であって、
ログ出力の呼び出しに基づいて、前記呼び出し時に取得可能な、ログを生成するために必要な情報を取得するステップと、
取得された前記情報をログ中間ファイル情報として、ログの生成が開始される前に所定の記憶領域に出力するステップとを、
有することを特徴とする通信制御方法。
A communication control method for controlling log output processing,
Obtaining information necessary to generate a log, which can be acquired at the time of the call, based on the call of the log output;
Outputting the acquired information as log intermediate file information to a predetermined storage area before log generation is started,
A communication control method comprising:
JP2016159383A 2016-08-15 2016-08-15 Communication control program, communication control device, and communication control method Active JP6652464B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2016159383A JP6652464B2 (en) 2016-08-15 2016-08-15 Communication control program, communication control device, and communication control method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2016159383A JP6652464B2 (en) 2016-08-15 2016-08-15 Communication control program, communication control device, and communication control method

Publications (2)

Publication Number Publication Date
JP2018028738A true JP2018028738A (en) 2018-02-22
JP6652464B2 JP6652464B2 (en) 2020-02-26

Family

ID=61248384

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2016159383A Active JP6652464B2 (en) 2016-08-15 2016-08-15 Communication control program, communication control device, and communication control method

Country Status (1)

Country Link
JP (1) JP6652464B2 (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2004070420A (en) * 2002-08-01 2004-03-04 Matsushita Electric Ind Co Ltd Trace data storage device
JP2009110078A (en) * 2007-10-26 2009-05-21 Hitachi Ltd Failure log management method
CN103176888A (en) * 2011-12-22 2013-06-26 阿里巴巴集团控股有限公司 Log recording method and log recording system
JP2014229313A (en) * 2013-05-20 2014-12-08 エルエス産電株式会社Lsis Co., Ltd. Method for storing data
US20150293801A1 (en) * 2014-04-15 2015-10-15 Lsis Co., Ltd. Apparatus, system and method for application log data processing

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2004070420A (en) * 2002-08-01 2004-03-04 Matsushita Electric Ind Co Ltd Trace data storage device
JP2009110078A (en) * 2007-10-26 2009-05-21 Hitachi Ltd Failure log management method
CN103176888A (en) * 2011-12-22 2013-06-26 阿里巴巴集团控股有限公司 Log recording method and log recording system
JP2014229313A (en) * 2013-05-20 2014-12-08 エルエス産電株式会社Lsis Co., Ltd. Method for storing data
US20150293801A1 (en) * 2014-04-15 2015-10-15 Lsis Co., Ltd. Apparatus, system and method for application log data processing

Also Published As

Publication number Publication date
JP6652464B2 (en) 2020-02-26

Similar Documents

Publication Publication Date Title
CN108319547B (en) Test case generation method, device and system
KR101238550B1 (en) Method and computer-readable medium for commanding
CN107977442B (en) Log file compression and decompression method, electronic device and readable storage medium
JP6150453B2 (en) Server apparatus, system, and log collection support method
JP4483807B2 (en) Log format conversion device, log format conversion method, and log format conversion program
JP2014081811A (en) Log management system and log management method
JPWO2020204144A1 (en) Business analysis method
CN110928851B (en) Method, device and equipment for processing log information and storage medium
CN115525292A (en) Low code development method and device, readable storage medium and electronic equipment
CN110941405A (en) Kernel client log printing method, device, equipment and storage medium
JP2017045238A (en) Information processing system, information processing device, and information processing method
Skinner Performance monitoring of parallel scientific applications
JP6652464B2 (en) Communication control program, communication control device, and communication control method
US10644971B2 (en) Graph search in structured query language style query
JP2020064399A (en) Control system, control device, terminal device, and program
Elmsheuser et al. ATLAS Grid Workflow Performance Optimization
KR20190071571A (en) Apparutus and method for analyzing user process based on standard process
Amontamavut et al. Separated Linux process logging mechanism for embedded systems
CN115964348A (en) Log data processing method and device, storage medium and electronic terminal
US9633061B2 (en) Methods for determining event counts based on time-sampled data
Weber et al. Online performance analysis with the Vampir tool set
KR102300347B1 (en) Apparatus of continuous profiling for multicore embedded system and the method of the same
JP2020181429A (en) Information analysis apparatus, information analysis method, program, and information analysis system
JPWO2020188779A1 (en) Information processing equipment, information processing system and information processing program
JP5718256B2 (en) System performance analysis apparatus, system performance analysis method, and system performance analysis program

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20181004

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20190730

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20190813

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20191002

RD03 Notification of appointment of power of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7423

Effective date: 20191002

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20200121

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20200123

R150 Certificate of patent or registration of utility model

Ref document number: 6652464

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150