Deprecated: The each() function is deprecated. This message will be suppressed on further calls in /home/zhenxiangba/zhenxiangba.com/public_html/phproxy-improved-master/index.php on line 456
JP5667097B2 - COMMUNICATION DEVICE, COMMUNICATION METHOD, AND COMMUNICATION PROGRAM - Google Patents
[go: Go Back, main page]

JP5667097B2 - COMMUNICATION DEVICE, COMMUNICATION METHOD, AND COMMUNICATION PROGRAM - Google Patents

COMMUNICATION DEVICE, COMMUNICATION METHOD, AND COMMUNICATION PROGRAM Download PDF

Info

Publication number
JP5667097B2
JP5667097B2 JP2012012177A JP2012012177A JP5667097B2 JP 5667097 B2 JP5667097 B2 JP 5667097B2 JP 2012012177 A JP2012012177 A JP 2012012177A JP 2012012177 A JP2012012177 A JP 2012012177A JP 5667097 B2 JP5667097 B2 JP 5667097B2
Authority
JP
Japan
Prior art keywords
message
input
time
buffer
stored
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.)
Expired - Fee Related
Application number
JP2012012177A
Other languages
Japanese (ja)
Other versions
JP2013153278A (en
Inventor
穣 片山
穣 片山
小林 守
守 小林
修一 吉野
修一 吉野
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
NTT Inc
NTT Inc USA
Original Assignee
Nippon Telegraph and Telephone Corp
NTT Inc USA
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 Nippon Telegraph and Telephone Corp, NTT Inc USA filed Critical Nippon Telegraph and Telephone Corp
Priority to JP2012012177A priority Critical patent/JP5667097B2/en
Publication of JP2013153278A publication Critical patent/JP2013153278A/en
Application granted granted Critical
Publication of JP5667097B2 publication Critical patent/JP5667097B2/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Multi Processors (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)
  • Communication Control (AREA)

Description

本発明は、通信装置、通信方法、及び通信プログラムに関する。   The present invention relates to a communication device, a communication method, and a communication program.

近年のネットワーク技術の進歩に伴い、数μ秒〜数100μ秒といったオーダーで高速にメッセージを伝送するリアルタイム通信に対する需要が高まっている。このような通信では、予め定められた規定時間を過ぎると、メッセージ自体に価値がなくなってしまうため、メッセージの伝送における制御が重要である。   With recent advances in network technology, there is an increasing demand for real-time communication that transmits messages at high speed on the order of several microseconds to several hundred microseconds. In such communication, since the value of the message itself is lost after a predetermined time, control in message transmission is important.

メッセージの伝送においてメッセージキューを用いた技術がある(非特許文献1)。
図5は、キューを用いたメッセージ転送の概要を示す図である。ここでは、送信元の処理プログラムAから送信先の処理プログラムへ複数のメッセージを、メッセージキュー(バッファ)を介して伝送する場合を説明する。
処理プログラムAに含まれる通信用プロセスの集合は、一意的な識別子を持つメッセージキューにメッセージを入力する。メッセージキューは、入力されたメッセージをバッファリングし、バッファリングしたメッセージを処理プログラムBに逐次出力することにより、メッセージを転送する。この技術では、メッセージがリアルタイム性を備える場合に(すなわち、高速なメッセージ伝送が要求される場合に)、メッセージが満たすべき規定時間T0を超えてバッファリングされていたとしても、そのメッセージを転送する。
非特許文献1に記載の技術では、メッセージのリアルタイム性に応じた制御や処理を行っていないために、規定時間を超えてしまったメッセージ、すなわち価値のないメッセージを伝送してしまい、通信資源を浪費してしまうことになる。
There is a technique using a message queue in message transmission (Non-Patent Document 1).
FIG. 5 is a diagram showing an outline of message transfer using a queue. Here, a case will be described in which a plurality of messages are transmitted from a transmission source processing program A to a transmission destination processing program via a message queue (buffer).
A set of communication processes included in the processing program A inputs a message to a message queue having a unique identifier. The message queue transfers the messages by buffering the input messages and sequentially outputting the buffered messages to the processing program B. In this technique, when a message has real-time characteristics (that is, when high-speed message transmission is required), the message is transferred even if the message is buffered over a predetermined time T0 to be satisfied. .
The technology described in Non-Patent Document 1 does not perform control or processing according to the real-time nature of the message, and therefore transmits a message that has exceeded the specified time, that is, a message that has no value, and uses communication resources. It will be wasted.

これに対して、メッセージキューにメッセージを入力する前に規定時間を満たした伝送が行えるか否かを判定し、規定時間を満たせるメッセージのみをメッセージキューに入力する技術が検討されている(非特許文献2)。
図6は、非特許文献2に記載されているメッセージ転送の概要を示す図である。ここでは、図5に示した例と同様に、送信元の処理プログラムAから送信先の処理プログラムBへ複数のメッセージを、メッセージキューを介して伝送する場合を説明する。
図6に示すように、処理プログラムAに含まれる通信用プロセスの集合は、メッセージをメッセージキュー12に入力する前に、メッセージの伝送に要する時間(経過時間+予想処理時間)が規定時間を満たすか否かを判定する。規定時間を満たすと判断した場合に、各通信プロセスは、メッセージをメッセージキューに入力する。すなわち、メッセージごとにリアルタイム性の充足可能性を判断した上で、メッセージをメッセージキューに入力する。
このよう処理することにより、無価値なメッセージが伝送されることを防ぎ、通信資源の浪費を抑えている。
On the other hand, a technique for determining whether or not transmission that satisfies a specified time can be performed before inputting a message to the message queue and inputting only a message that can satisfy the specified time to the message queue has been studied (non-patented). Reference 2).
FIG. 6 is a diagram showing an outline of message transfer described in Non-Patent Document 2. Here, as in the example shown in FIG. 5, a case where a plurality of messages are transmitted from the transmission source processing program A to the transmission destination processing program B via the message queue will be described.
As shown in FIG. 6, in the set of communication processes included in the processing program A, the time required for message transmission (elapsed time + expected processing time) satisfies the specified time before the message is input to the message queue 12. It is determined whether or not. When it is determined that the specified time is satisfied, each communication process inputs a message to the message queue. That is, after determining whether or not the real-time property can be satisfied for each message, the message is input to the message queue.
By performing such processing, it is possible to prevent transmission of a valueless message and suppress waste of communication resources.

桜川貴司(訳)、Berny M. Goodheart、James H. Cox、「UNIXカーネルの魔法 SystemVリリース4のアーキテクチャ」、ピアンソンエデュケーション、2000年4月、p.523−530Takashi Sakuragawa (translation), Berny M. Goodheart, James H. Cox, “The Architecture of UNIX Kernel Magic System V Release 4”, Pianson Education, April 2000, p. 523-530 野村哲弘、石川裕、「リアルタイムパケットの通信制御」、情報処理学会研究報告−システムソフトウエアとオペレーティング・システム(OS)、2005年5月、Vol.2005、No.79、p.79−84Tetsuhiro Nomura, Hiroshi Ishikawa, “Communication Control of Real-Time Packets”, Information Processing Society of Japan Research Report-System Software and Operating System (OS), May 2005, Vol. 2005, no. 79, p. 79-84

しかしながら、非特許文献2に記載の技術では、無価値なメッセージの伝送による通信資源の浪費を防げるが、メッセージごとにリアルタイム性の充足可能性を判断する処理のために時間を要してしまう。この判断の処理に要する時間が長くなると、メッセージを規定時間内に伝送することが困難になってしまう。特に、伝送するメッセージ数が増加した場合、判断に要する時間が増加して、結果的にほとんどのメッセージをメッセージキューに入力せずに、メッセージの伝送を行わないことになってしまうという問題がある。   However, in the technique described in Non-Patent Document 2, it is possible to prevent waste of communication resources due to transmission of a valueless message, but time is required for processing for determining whether or not the real-time property can be satisfied for each message. If the time required for this determination process becomes long, it becomes difficult to transmit the message within the specified time. In particular, when the number of messages to be transmitted increases, the time required for determination increases, and as a result, most messages are not input to the message queue, and the message is not transmitted. .

本発明は、上記問題を解決すべくなされたもので、その目的は、リアルタイム性を有するメッセージの伝送において、メッセージの伝送への影響を抑えつつ、無価値なメッセージの伝送を回避する通信装置、通信方法、及び通信プログラムを提供することにある。   The present invention has been made to solve the above-mentioned problem, and its purpose is to avoid the transmission of a valueless message while suppressing the influence on the transmission of the message in the transmission of a message having real-time characteristics, A communication method and a communication program are provided.

上記問題を解決するために、本発明は、送信元から入力されるメッセージを送信先に出力する通信装置であって、前記送信元から前記メッセージ群のうち最初のメッセージが入力されてから経過した経過時間を測定するタイマ部と、前記送信元から入力された前記メッセージ群のメッセージをバッファに記憶させ、前記送信先からの要求に応じて前記バッファに記憶されている前記メッセージ群のメッセージを前記送信先に出力するメッセージ入出力部と、前記タイマ部が計測している経過時間が予め定められている規定時間を超えた場合、前記バッファに記憶されている前記メッセージ群のメッセージを削除するメッセージ破棄部とを備えることを特徴とする通信装置である。 In order to solve the above problem, the present invention provides a communication device that outputs a message group input from a transmission source to a transmission destination, and has elapsed since the first message was input from the transmission source to the message group. a timer unit for measuring elapsed time, the message set of the message that is input from the transmission source is stored in the buffer, a message of said message groups stored in said buffer in response to a request from the destination When the elapsed time measured by the message input / output unit and the timer unit output to the transmission destination exceeds a predetermined time, the message of the message group stored in the buffer is deleted. A communication device comprising a message discarding unit.

また、本発明は、上記の発明において、前記メッセージ破棄部は、更に、前記タイマ部が計測している経過時間が予め定められた時間に達するごとに、該時間に対応して予め定められた規定数以上のメッセージの出力が完了していない場合、前記バッファに記憶されている前記メッセージ群のメッセージを削除することを特徴とする。 Further, the present invention is the invention of the above SL, the message discarding unit further, each time the timer unit reaches a predetermined time is elapsed time is measured, predetermined corresponding to said time When the output of more than the specified number of messages has not been completed, the messages of the message group stored in the buffer are deleted.

また、本発明は、上記の発明において、前記メッセージ破棄部は、更に、前記バッファに記憶されている前記メッセージ群のメッセージを削除すると、前記規定時間内に出力できないメッセージがあることを示すタイムアウト信号を前記送信元及び前記送信先に通知することを特徴とする。 Further, the present invention is the invention of the above SL, the message discarding unit further, deleting the message set of the message stored in the buffer, time out to indicate that there is a message that can not be output within the prescribed time A signal is notified to the transmission source and the transmission destination.

また、上記問題を解決するために、本発明は、送信元から入力されるメッセージを送信先に出力する通信装置が行う通信方法であって、前記送信元から前記メッセージ群のうち最初のメッセージが入力されてから経過した経過時間を測定するステップと、前記送信元から入力された前記メッセージ群のメッセージをバッファに記憶させ、前記送信先からの要求に応じて前記バッファに記憶されている前記メッセージ群のメッセージを前記送信先に出力するステップと、前記経過時間が予め定められている規定時間を超えた場合、前記バッファに記憶されている前記メッセージ群のメッセージを削除するステップとを有することを特徴とする通信方法である。 Further, in order to solve the above problem, the present invention provides a communication method performed by a communication device that outputs a message group input from a transmission source to a transmission destination, the first message of the message group from the transmission source. a step but to measure the elapsed time that has elapsed since the input, the message set of the message that is input from the transmission source is stored in the buffer, the stored in the buffer in response to a request from the destination Outputting a message in a message group to the destination, and deleting the message in the message group stored in the buffer when the elapsed time exceeds a predetermined time. A communication method characterized by the above.

また、上記問題を解決するために、本発明は、送信元から入力されるメッセージを送信先に出力する通信装置に設けられているコンピュータに前記送信元から前記メッセージ群のうち最初のメッセージが入力されてから経過した経過時間を測定するステップと、前記送信元から入力された前記メッセージ群のメッセージをバッファに記憶させ、前記送信先からの要求に応じて前記バッファに記憶されている前記メッセージ群のメッセージを前記送信先に出力するステップと、前記経過時間が予め定められている規定時間を超えた場合、前記バッファに記憶されている前記メッセージ群のメッセージを削除するステップとを実行させるための通信プログラムである。 In order to solve the above problems, the present invention is the first message of the message group from the source to the computer provided in the communication device for outputting the message group to be inputted from the source to the destination measuring the elapsed time that has elapsed since the input, the message set of the message that is input from the transmission source is stored in the buffer, the message stored in the buffer in response to a request from the destination Outputting a group message to the destination, and deleting the message group message stored in the buffer when the elapsed time exceeds a predetermined time. Communication program.

この発明によれば、通信装置において、送信元からメッセージが入力されてから経過した時間が規定時間を超えた場合に記憶されているメッセージを削除するようにした。これにより、事前に規定時間内にメッセージを伝送できるか否かの判定を行うことなく、経過時間と規定時間とを比較するという演算負荷の小さい処理で無価値なメッセージの伝送を回避することができる。   According to the present invention, in the communication device, the stored message is deleted when the elapsed time after the message is input from the transmission source exceeds the specified time. As a result, it is possible to avoid the transmission of an insignificant message with a processing with a small calculation load of comparing the elapsed time and the specified time without determining whether the message can be transmitted within the specified time in advance. it can.

本発明に係る実施形態における通信装置1の構成を示す概略ブロック図である。It is a schematic block diagram which shows the structure of the communication apparatus 1 in embodiment which concerns on this invention. 同実施形態における通信装置1が行う転送処理を示すフローチャートである。It is a flowchart which shows the transfer process which the communication apparatus 1 in the embodiment performs. 同実施形態における通信装置1が行う転送時間管理処理を示すフローチャートである。It is a flowchart which shows the transfer time management process which the communication apparatus 1 in the embodiment performs. 同実施形態における通信装置1によるメッセージ転送の一例を示す概要図である。It is a schematic diagram which shows an example of the message transfer by the communication apparatus 1 in the embodiment. キューを用いたメッセージ転送の概要を示す図である。It is a figure which shows the outline | summary of the message transfer using a queue. キューを用いた他のメッセージ転送の概要を示す図である。It is a figure which shows the outline | summary of the other message transfer using a queue.

以下、図面を参照して、本発明に係る実施形態における通信装置、通信方法、及び通信プログラムを説明する。
図1は、本実施形態における通信装置1の構成を示す概略ブロック図である。通信装置1は、送信元から入力される少なくとも1つのメッセージを含むメッセージ群が入力され、入力されたメッセージ群を一時的に記憶し、記憶しているメッセージ群を送信先に出力する転送処理を行う。また、通信装置1は、同図に示すように、メッセージ入出力部11と、メッセージキュー12と、制御部13とを具備している。
Hereinafter, a communication device, a communication method, and a communication program according to an embodiment of the present invention will be described with reference to the drawings.
FIG. 1 is a schematic block diagram showing the configuration of the communication device 1 in the present embodiment. The communication apparatus 1 receives a message group including at least one message input from a transmission source, temporarily stores the input message group, and outputs a stored message group to a transmission destination. Do. Further, the communication apparatus 1 includes a message input / output unit 11, a message queue 12, and a control unit 13, as shown in FIG.

メッセージ入出力部11は、メッセージの送信元から入力されるメッセージをメッセージキュー12に出力し、送信元の識別子を記憶する。また、メッセージ入出力部11は、送信先からアクセスされると送信先の識別子を記憶し、また、メッセージキュー12からメッセージを読み出して送信先に出力する。メッセージ入出力部11は、送信先からメッセージの送信先であることを示す登録要求信号が入力され、また、送信先からメッセージを要求するメッセージ要求信号が入力される。また、メッセージ入出力部11は、制御部13から入力されるタイムアウト信号を送信元及び送信先に出力する。
メッセージキュー12は、メッセージ入出力部11から入力されるメッセージを記憶する。また、メッセージキュー12は、記憶しているメッセージのうち、メッセージ入出力部11が読み出したメッセージを削除する。メッセージキュー12は、例えば、FIFO方式のバッファとして構成される。
制御部13は、送信元から送信先へのメッセージの伝送に対して予め定められている規定時間T0に基づいて、メッセージの伝送を制御する。ここで、規定時間T0は、本実施形態において、通信装置1が送信元よりメッセージを入力されてから、通信装置1が送信先にメッセージを出力するまでに要する時間に対する制約である。換言すると、メッセージのリアルタイム性を維持するために守るべき条件である。
The message input / output unit 11 outputs a message input from the message transmission source to the message queue 12 and stores the identifier of the transmission source. Further, when accessed from the transmission destination, the message input / output unit 11 stores the identifier of the transmission destination, and reads out the message from the message queue 12 and outputs it to the transmission destination. The message input / output unit 11 receives a registration request signal indicating that it is a message transmission destination from a transmission destination, and also receives a message request signal for requesting a message from the transmission destination. Further, the message input / output unit 11 outputs a timeout signal input from the control unit 13 to the transmission source and the transmission destination.
The message queue 12 stores messages input from the message input / output unit 11. Further, the message queue 12 deletes the message read by the message input / output unit 11 from the stored messages. The message queue 12 is configured as a FIFO buffer, for example.
The control unit 13 controls message transmission based on a predetermined time T0 predetermined for message transmission from the transmission source to the transmission destination. Here, the specified time T0 is a restriction on the time required for the communication apparatus 1 to output a message to the transmission destination after the communication apparatus 1 receives a message from the transmission source in the present embodiment. In other words, it is a condition to be observed in order to maintain the real-time property of the message.

制御部13は、タイマ部131と、タイムアウト判定部132と、メッセージ破棄部133とを備えている。タイマ部131は、送信元から通信装置1にメッセージが入力されてから経過した時間(滞留時間T1)を計測する。タイムアウト判定部132は、メッセージキュー12に記憶されているメッセージの規定時間T0が守られているか否かを判定する。また、タイムアウト判定部132は、判定結果に基づいてメッセージ破棄部133を制御する。メッセージ破棄部133は、タイムアウト判定部132の制御に応じて、メッセージキュー12に記憶されているメッセージを削除する。また、メッセージ破棄部133は、メッセージキュー12に記憶されているメッセージを削除した場合、メッセージ入出力部11を介して、タイムアウトの発生を示すタイムアウト信号を当該メッセージの送信元及び送信先に通知する。ここで、タイムアウトとは、規定時間内に伝送できないメッセージが発生することである。   The control unit 13 includes a timer unit 131, a timeout determination unit 132, and a message discard unit 133. The timer unit 131 measures the time (residence time T1) that has elapsed since the message was input to the communication device 1 from the transmission source. The timeout determination unit 132 determines whether or not the specified time T0 of the message stored in the message queue 12 is kept. Further, the timeout determination unit 132 controls the message discard unit 133 based on the determination result. The message discard unit 133 deletes the message stored in the message queue 12 according to the control of the timeout determination unit 132. Further, when the message discarding unit 133 deletes the message stored in the message queue 12, the message discarding unit 133 notifies the transmission source and destination of the message of a timeout signal indicating the occurrence of timeout through the message input / output unit 11. . Here, timeout means that a message that cannot be transmitted within a specified time occurs.

図2は、本実施形態における通信装置1が行う転送処理を示すフローチャートである。
通信装置1において、転送処理が開始されると、タイムアウト判定部132は、送信元から送信先へのメッセージの転送における規定時間(T0)を設定し、メッセージキュー12をクリアして初期化する(ステップS101)。なお、送信元と送信先との組み合わせに関わらず規定時間が一定である場合には、規定時間(T0)の設定を行わずともよい。
メッセージ入出力部11は、送信元又は送信先からのアクセスを待ち(ステップS102)、アクセスがあると当該アクセスが送信元のアクセスであるか否かを判定する(ステップS103)。
FIG. 2 is a flowchart showing transfer processing performed by the communication device 1 according to the present embodiment.
In the communication device 1, when the transfer process is started, the timeout determination unit 132 sets a specified time (T0) for transferring the message from the transmission source to the transmission destination, and clears and initializes the message queue 12 ( Step S101). If the specified time is constant regardless of the combination of the transmission source and the transmission destination, the specified time (T0) need not be set.
The message input / output unit 11 waits for an access from the transmission source or the transmission destination (step S102).

アクセスが送信元からのアクセスである場合(ステップS103:Yes)、メッセージ入出力部11は、メッセージ群における最初のメッセージであるか否かを判定する(ステップS104)。
最初のメッセージである場合(ステップS104:Yes)、メッセージ入出力部11は、制御部13に対して転送時間管理処理の開始を指示し(ステップS105)、送信元から入力されたメッセージをメッセージキュー12に出力して記憶させ(ステップS106)、処理をステップS102に戻す。
一方、最初のメッセージでない場合(ステップS104:No)、メッセージ入出力部11は、送信元から終端信号が入力されたか否かを判定し(ステップS107)、終端信号でない場合(ステップS107:No)、処理をステップS106に進め、終端信号である場合(ステップS107:Yes)、処理をステップS102に戻す。ここで、終端信号とは、送信元からのメッセージ群の入力の完了を示す信号である。
When the access is an access from the transmission source (step S103: Yes), the message input / output unit 11 determines whether or not it is the first message in the message group (step S104).
If it is the first message (step S104: Yes), the message input / output unit 11 instructs the control unit 13 to start the transfer time management process (step S105), and the message input from the transmission source is sent to the message queue. 12 is output and stored (step S106), and the process returns to step S102.
On the other hand, when it is not the first message (step S104: No), the message input / output unit 11 determines whether or not a termination signal is input from the transmission source (step S107), and when it is not the termination signal (step S107: No). The process proceeds to step S106, and if it is a termination signal (step S107: Yes), the process returns to step S102. Here, the termination signal is a signal indicating completion of input of a message group from the transmission source.

ステップS103において、アクセスが送信元からのアクセスでない場合(ステップS103:No)、メッセージ入出力部11は、送信先から登録要求信号が入力されたか否かを判定する(ステップS111)。
メッセージ入出力部11は、送信先からの登録要求信号が入力された場合(ステップS111:Yes)、当該登録要求信号を自装置に出力した送信先を記憶して登録し(ステップS112)、処理をステップS102に戻す。
一方、送信先から登録要求信号が入力されなかった場合、すなわち送信先からメッセージ要求信号が入力された場合(ステップS111:No)、メッセージ入出力部11は、メッセージキュー12からメッセージを読み出し、読み出したメッセージを送信先に出力する。このとき、送信先に出力したメッセージをメッセージキュー12から削除する(ステップS113)。
In step S103, when the access is not an access from the transmission source (step S103: No), the message input / output unit 11 determines whether or not a registration request signal is input from the transmission destination (step S111).
When the registration request signal from the transmission destination is input (step S111: Yes), the message input / output unit 11 stores and registers the transmission destination that has output the registration request signal to the own device (step S112), and performs processing. Is returned to step S102.
On the other hand, when the registration request signal is not input from the transmission destination, that is, when the message request signal is input from the transmission destination (step S111: No), the message input / output unit 11 reads and reads the message from the message queue 12. Output the message to the destination. At this time, the message output to the transmission destination is deleted from the message queue 12 (step S113).

メッセージ入出力部11は、メッセージキュー12に記憶されていたすべてのメッセージを送信先に出力する転送が完了したか否かを判定し(ステップS114)、完了している場合(ステップS114:Yes)、制御部13に対して転送時間管理処理の停止を指示し(ステップS115)、転送処理を終了させる。
一方、メッセージの転送が完了していない場合(ステップS114:No)、メッセージ入出力部11は、処理をステップS102に戻し、ステップS102からステップS115までの処理を繰り返して行う。
The message input / output unit 11 determines whether or not the transfer for outputting all the messages stored in the message queue 12 to the transmission destination is completed (step S114), and when the transfer is completed (step S114: Yes). Then, the controller 13 is instructed to stop the transfer time management process (step S115), and the transfer process is terminated.
On the other hand, when the message transfer has not been completed (step S114: No), the message input / output unit 11 returns the process to step S102 and repeats the process from step S102 to step S115.

図3は、本実施形態における通信装置1が行う転送時間管理処理を示すフローチャートである。
通信装置1において、メッセージ入出力部11から制御部13に転送時間管理処理の開始が指示されると、タイマ部131はカウント値(T1)を「0」にする初期化を行う(ステップS201)。
タイマ部131がカウント値(T1)をカウントアップ(インクリメント)すると(ステップS202)、タイムアウト判定部132は、カウント値(T1)とチェックポイント値とが一致しているか否かを判定する(ステップS203)。
ここで、チェックポイント値は、0以上、かつ規定時間T0未満の少なくとも1つの時間(時限)を示す値である。また、チェックポイント値ごとに、経過時間がチェックポイント値に達した際に、転送が完了しているべきメッセージ数を示す規定数(M)が予め設定されている。チェックポイント値には、例えば、規定時間(T0)の半分(T0/2)や、規定時間(T0)の4分の1、4分の3などの値を設定する。
FIG. 3 is a flowchart showing a transfer time management process performed by the communication device 1 according to this embodiment.
In the communication device 1, when the message input / output unit 11 instructs the control unit 13 to start the transfer time management process, the timer unit 131 initializes the count value (T1) to “0” (step S201). .
When the timer unit 131 counts up (increments) the count value (T1) (step S202), the timeout determination unit 132 determines whether or not the count value (T1) matches the checkpoint value (step S203). ).
Here, the check point value is a value indicating at least one time (time period) that is 0 or more and less than the specified time T0. For each checkpoint value, a specified number (M) indicating the number of messages that should be transferred when the elapsed time reaches the checkpoint value is preset. As the check point value, for example, a value such as half of the specified time (T0) (T0 / 2), 1/4 of the specified time (T0), or 3/4 is set.

カウント値(T1)とチェックポイント値とが一致している場合(ステップS203:Yes)、タイムアウト判定部132は、最初のメッセージが送信元から入力された以降において送信先に出力したメッセージ数(転送済のメッセージ数)が予め定められた規定数(M)以上であるか否かを判定する(ステップS204)。
転送済のメッセージが規定数(M)以上である場合(ステップS204:Yes)、タイムアウト判定部132は、処理をステップS202に戻す。
一方、転送済のメッセージ数が規定数(M)未満である場合(ステップS204:No)、タイムアウト判定部132は、処理をステップS206に進める。
When the count value (T1) matches the checkpoint value (step S203: Yes), the timeout determination unit 132 outputs the number of messages output to the transmission destination (transfer) after the first message is input from the transmission source. It is determined whether or not the number of completed messages is equal to or greater than a predetermined number (M) (step S204).
If the number of transferred messages is equal to or greater than the specified number (M) (step S204: Yes), the timeout determination unit 132 returns the process to step S202.
On the other hand, when the number of transferred messages is less than the specified number (M) (step S204: No), the timeout determination unit 132 advances the process to step S206.

ステップS203において、カウント値(T1)とチェックポイント値とが一致していない場合(ステップS203:No)、タイムアウト判定部132は、カウント値(T1)が規定時間(T0)より大きいか否かを判定する(ステップS205)。
カウント値(T1)が規定時間(T0)より大きくない場合(ステップS205:No)、タイムアウト判定部132は処理をステップS202に戻す。
一方、カウント値(T1)が規定時間(T0)より大きい場合(ステップS205:Yes)、タイムアウト判定部132は、メッセージ破棄部133を制御してエラー処理を開始させる。メッセージ破棄部133は、メッセージキュー12に記憶されているメッセージを削除する(ステップS206)。
メッセージ破棄部133は、メッセージ入出力部11を介して、ステップS206において削除したメッセージの送信元及び送信先にタイムアウト信号を出力し(ステップS207)、転送時間管理処理を終了させる。送信元と送信先とは、タイムアウト信号によりメッセージの転送が正常に行われなかったことを把握することができる。
In step S203, when the count value (T1) does not match the checkpoint value (step S203: No), the timeout determination unit 132 determines whether or not the count value (T1) is greater than the specified time (T0). Determination is made (step S205).
If the count value (T1) is not greater than the specified time (T0) (step S205: No), the timeout determination unit 132 returns the process to step S202.
On the other hand, when the count value (T1) is larger than the specified time (T0) (step S205: Yes), the timeout determination unit 132 controls the message discard unit 133 to start error processing. The message discard unit 133 deletes the message stored in the message queue 12 (step S206).
The message discard unit 133 outputs a timeout signal to the transmission source and transmission destination of the message deleted in step S206 via the message input / output unit 11 (step S207), and ends the transfer time management process. The transmission source and the transmission destination can grasp that the message transfer was not normally performed by the timeout signal.

図4は、本実施形態における通信装置1によるメッセージ転送の一例を示す概要図である。ここでは、6つのメッセージを含むメッセージ群が送信元から通信装置1に入力され、規定時間T0内に3つのメッセージが通信装置1から送信先に出力された場合について説明する。
同図に示すように、通信装置1は6つのメッセージを含むメッセージ群が入力されると、メッセージキュー12に各メッセージを記憶する。通信装置1は、送信先からの要求に応じて、メッセージキュー12に記憶しているメッセージを順に送信先に出力し、メッセージを転送する。
ここで、最初のメッセージを送信元から入力されてから規定時間(T0)が経過すると、通信装置1は、転送時間管理処理において、メッセージキュー12に記憶されているメッセージの削除、及び送信元及び送信先へのタイムアウトの通知を含むエラー処理を行う。これにより、通信装置1は、規定時間(T0)が経過した後に、無価値なメッセージを送信先に出力することを回避することができる。
FIG. 4 is a schematic diagram illustrating an example of message transfer by the communication device 1 according to the present embodiment. Here, a case will be described in which a message group including six messages is input from the transmission source to the communication apparatus 1 and three messages are output from the communication apparatus 1 to the transmission destination within the specified time T0.
As shown in the figure, when a message group including six messages is input, the communication apparatus 1 stores each message in the message queue 12. In response to a request from the transmission destination, the communication device 1 sequentially outputs the messages stored in the message queue 12 to the transmission destination and transfers the messages.
Here, when the specified time (T0) has elapsed since the first message was input from the transmission source, the communication device 1 deletes the message stored in the message queue 12 and transmits the transmission source and Error handling including timeout notification to the destination. Thereby, the communication apparatus 1 can avoid outputting a worthless message to a transmission destination after the lapse of the specified time (T0).

上述のように、通信装置1は、送信元から最初のメッセージが入力されると、タイマ部131により経過時間(カウント値)を測定し、経過時間が規定時間(T0)に達した場合に、メッセージキュー12に記憶されているメッセージを破棄するとともに、メッセージの送信元及び送信先にタイムアウトの通知を行う。
これにより、メッセージをメッセージキュー12に入力する都度、メッセージの転送に要する時間を推定することなく、無価値なメッセージの転送を回避することができる。
As described above, when the first message is input from the transmission source, the communication device 1 measures the elapsed time (count value) by the timer unit 131, and when the elapsed time reaches the specified time (T0), The message stored in the message queue 12 is discarded, and a timeout notification is sent to the message transmission source and the transmission destination.
Thereby, every time a message is input to the message queue 12, it is possible to avoid transfer of a valueless message without estimating the time required for message transfer.

また、通信装置1は、チェックポイントを設け、経過時間がチェックポイントに達した場合に、転送済のメッセージ数が規定数(M)に達していないときには、処理を継続して行っても規定時間(T0)内にメッセージの転送を完了することができないと判断し、エラー処理を行う。
これにより、規定時間(T0)の経過を待つことなく、メッセージの破棄を行うことができ、通信装置1における処理の負荷を軽減することができる。
In addition, the communication device 1 provides a checkpoint, and when the elapsed time reaches the checkpoint and the number of transferred messages has not reached the specified number (M), the specified time even if the processing is continued. It is determined that the message transfer cannot be completed within (T0), and error processing is performed.
Accordingly, the message can be discarded without waiting for the lapse of the specified time (T0), and the processing load on the communication device 1 can be reduced.

なお、上述の実施形態においては、転送処理、及び転送時間管理処理を通信装置1が行う処理として説明したが、コンピュータシステム上で実行されるプロセスやスレッドが、転送処理、及び転送時間管理処理を行うようにしてもよい。この場合、送信元及び送信先は、コンピュータシステムが備えるインタフェースや、当該コンピュータシステム上で実行されるプロセスやスレッドなどになる。   In the above-described embodiment, the transfer process and the transfer time management process have been described as processes performed by the communication apparatus 1. However, processes and threads executed on the computer system perform the transfer process and the transfer time management process. You may make it perform. In this case, the transmission source and the transmission destination are interfaces provided in the computer system, processes and threads executed on the computer system, and the like.

なお、本発明における通信装置の機能を実現するためのプログラムをコンピュータ読み取り可能な記録媒体に記録して、この記録媒体に記録されたプログラムをコンピュータシステムに読み込ませ、実行することにより、転送処理及び転送時間管理処理を行ってもよい。なお、ここでいう「コンピュータシステム」とは、OSや周辺機器等のハードウェアを含むものとする。また、「コンピュータシステム」は、ホームページ提供環境(あるいは表示環境)を備えたWWWシステムも含むものとする。また、「コンピュータ読み取り可能な記録媒体」とは、フレキシブルディスク、光磁気ディスク、ROM、CD−ROM等の可搬媒体、コンピュータシステムに内蔵されるハードディスク等の記憶装置のことをいう。更に「コンピュータ読み取り可能な記録媒体」とは、インターネット等のネットワークや電話回線等の通信回線を介してプログラムが送信された場合のサーバやクライアントとなるコンピュータシステム内部の揮発性メモリ(RAM)のように、一定時間プログラムを保持しているものも含むものとする。   Note that a program for realizing the function of the communication device according to the present invention is recorded on a computer-readable recording medium, and the program recorded on the recording medium is read by a computer system and executed, whereby transfer processing and Transfer time management processing may be performed. Here, the “computer system” includes an OS and hardware such as peripheral devices. The “computer system” includes a WWW system having a homepage providing environment (or display environment). The “computer-readable recording medium” refers to a storage device such as a flexible medium, a magneto-optical disk, a portable medium such as a ROM and a CD-ROM, and a hard disk incorporated in a computer system. Further, the “computer-readable recording medium” refers to a volatile memory (RAM) in a computer system that becomes a server or a client when a program is transmitted via a network such as the Internet or a communication line such as a telephone line. In addition, those holding programs for a certain period of time are also included.

また、上記プログラムは、このプログラムを記憶装置等に格納したコンピュータシステムから、伝送媒体を介して、あるいは、伝送媒体中の伝送波により他のコンピュータシステムに伝送されてもよい。ここで、プログラムを伝送する「伝送媒体」は、インターネット等のネットワーク(通信網)や電話回線等の通信回線(通信線)のように情報を伝送する機能を有する媒体のことをいう。また、上記プログラムは、前述した機能の一部を実現するためのものであっても良い。更に、前述した機能をコンピュータシステムに既に記録されているプログラムとの組み合わせで実現できるもの、いわゆる差分ファイル(差分プログラム)であっても良い。   The program may be transmitted from a computer system storing the program in a storage device or the like to another computer system via a transmission medium or by a transmission wave in the transmission medium. Here, the “transmission medium” for transmitting the program refers to a medium having a function of transmitting information, such as a network (communication network) such as the Internet or a communication line (communication line) such as a telephone line. The program may be for realizing a part of the functions described above. Furthermore, what can implement | achieve the function mentioned above in combination with the program already recorded on the computer system, and what is called a difference file (difference program) may be sufficient.

1…通信装置
11…メッセージ入出力部
12…メッセージキュー
13…制御部
131…タイマ部
132…タイムアウト判定部
133…メッセージ破棄部
DESCRIPTION OF SYMBOLS 1 ... Communication apparatus 11 ... Message input / output part 12 ... Message queue 13 ... Control part 131 ... Timer part 132 ... Timeout determination part 133 ... Message discard part

Claims (5)

送信元から入力されるメッセージを送信先に出力する通信装置であって、
前記送信元から前記メッセージ群のうち最初のメッセージが入力されてから経過した経過時間を測定するタイマ部と、
前記送信元から入力された前記メッセージ群のメッセージをバッファに記憶させ、前記送信先からの要求に応じて前記バッファに記憶されている前記メッセージ群のメッセージを前記送信先に出力するメッセージ入出力部と、
前記タイマ部が計測している経過時間が予め定められている規定時間を超えた場合、前記バッファに記憶されている前記メッセージ群のメッセージを削除するメッセージ破棄部と
を備えることを特徴とする通信装置。
A communication device that outputs a message group input from a transmission source to a transmission destination,
A timer unit for measuring an elapsed time since the first message is input from the sender to the message group ;
Wherein said group of messages of a message which is input from the source is stored in the buffer, the message output unit for outputting a message of said message groups stored in said buffer in response to a request from the transmission destination to the transmission destination When,
A message discarding unit for deleting a message of the message group stored in the buffer when the elapsed time measured by the timer unit exceeds a predetermined time set in advance. apparatus.
請求項1に記載の通信装置であって、
前記メッセージ破棄部は、更に、
前記タイマ部が計測している経過時間が予め定められた時間に達するごとに、該時間に対応して予め定められた規定数以上のメッセージの出力が完了していない場合、前記バッファに記憶されている前記メッセージ群のメッセージを削除する
ことを特徴とする通信装置。
The communication device according to claim 1,
The message discarding unit further includes:
Every time the elapsed time measured by the timer unit reaches a predetermined time, if the output of a predetermined number of messages corresponding to the time has not been completed, the message is stored in the buffer. The communication apparatus, wherein the message of the message group is deleted.
請求項1又は請求項2のいずれかに記載の通信装置であって、
前記メッセージ破棄部は、更に、
前記バッファに記憶されている前記メッセージ群のメッセージを削除すると、前記規定時間内に出力できないメッセージがあることを示すタイムアウト信号を前記送信元及び前記送信先に通知する
ことを特徴とする通信装置。
The communication device according to claim 1 or 2,
The message discarding unit further includes:
When the message of the message group stored in the buffer is deleted, a time-out signal indicating that there is a message that cannot be output within the specified time is notified to the transmission source and the transmission destination.
送信元から入力されるメッセージを送信先に出力する通信装置が行う通信方法であって、
前記送信元から前記メッセージ群のうち最初のメッセージが入力されてから経過した経過時間を測定するステップと、
前記送信元から入力された前記メッセージ群のメッセージをバッファに記憶させ、前記送信先からの要求に応じて前記バッファに記憶されている前記メッセージ群のメッセージを前記送信先に出力するステップと、
前記経過時間が予め定められている規定時間を超えた場合、前記バッファに記憶されている前記メッセージ群のメッセージを削除するステップと
を有することを特徴とする通信方法。
A communication method performed by a communication device that outputs a message group input from a transmission source to a transmission destination,
Measuring an elapsed time since the first message of the message group was input from the sender;
And outputting the message set of the message that is input from the transmission source is stored in the buffer, a message of said message groups stored in said buffer in response to a request from said destination to said destination,
And a step of deleting a message of the message group stored in the buffer when the elapsed time exceeds a predetermined time.
送信元から入力されるメッセージを送信先に出力する通信装置に設けられているコンピュータに
前記送信元から前記メッセージ群のうち最初のメッセージが入力されてから経過した経過時間を測定するステップと、
前記送信元から入力された前記メッセージ群のメッセージをバッファに記憶させ、前記送信先からの要求に応じて前記バッファに記憶されている前記メッセージ群のメッセージを前記送信先に出力するステップと、
前記経過時間が予め定められている規定時間を超えた場合、前記バッファに記憶されている前記メッセージ群のメッセージを削除するステップと
を実行させるための通信プログラム。
Measuring the elapsed time that has elapsed from the input of the first message of the message group from the source to the computer provided in the communication device for outputting the message group to be inputted from the source to the destination,
And outputting the message set of the message that is input from the transmission source is stored in the buffer, a message of said message groups stored in said buffer in response to a request from said destination to said destination,
And a step of deleting a message of the message group stored in the buffer when the elapsed time exceeds a predetermined time.
JP2012012177A 2012-01-24 2012-01-24 COMMUNICATION DEVICE, COMMUNICATION METHOD, AND COMMUNICATION PROGRAM Expired - Fee Related JP5667097B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2012012177A JP5667097B2 (en) 2012-01-24 2012-01-24 COMMUNICATION DEVICE, COMMUNICATION METHOD, AND COMMUNICATION PROGRAM

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2012012177A JP5667097B2 (en) 2012-01-24 2012-01-24 COMMUNICATION DEVICE, COMMUNICATION METHOD, AND COMMUNICATION PROGRAM

Publications (2)

Publication Number Publication Date
JP2013153278A JP2013153278A (en) 2013-08-08
JP5667097B2 true JP5667097B2 (en) 2015-02-12

Family

ID=49049315

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2012012177A Expired - Fee Related JP5667097B2 (en) 2012-01-24 2012-01-24 COMMUNICATION DEVICE, COMMUNICATION METHOD, AND COMMUNICATION PROGRAM

Country Status (1)

Country Link
JP (1) JP5667097B2 (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
GB201408408D0 (en) * 2014-05-12 2014-06-25 Tomlinson Martin Method and apparatus for time limited messages in packet communications
JP6459654B2 (en) * 2014-11-07 2019-01-30 富士通株式会社 Event-driven system, information processing apparatus, event-driven program, and event-driven method
JP6769230B2 (en) * 2016-10-14 2020-10-14 オムロン株式会社 Communication device, control device and communication method

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH05314069A (en) * 1992-05-11 1993-11-26 Hitachi Ltd Input message control method for online system
JP2001117788A (en) * 1999-10-15 2001-04-27 Fujitsu Ten Ltd Information transmission managing device
JP5610773B2 (en) * 2010-01-06 2014-10-22 キヤノン株式会社 Message processing apparatus and message processing method

Also Published As

Publication number Publication date
JP2013153278A (en) 2013-08-08

Similar Documents

Publication Publication Date Title
US10788992B2 (en) System and method for efficient access for remote storage devices
US10454850B2 (en) Apparatus and method for buffering data in a switch
CN102480430B (en) Method and device for realizing message order preservation
CN111542803B (en) A method, device and system for writing data based on NVMe
US9319493B2 (en) Communication method and information processing system
CN107391271A (en) A kind of delayed tasks triggering method and device based on Message Queuing system
US20170272343A1 (en) Systems and methods for monitoring servers for overloading conditions
CN103493449A (en) Effective Circuits in Packet-Switched Networks
CN102571568B (en) Task processing method and device
JP5667097B2 (en) COMMUNICATION DEVICE, COMMUNICATION METHOD, AND COMMUNICATION PROGRAM
US20250133134A1 (en) Method and system for scalable reliable connection transport for rdma
US20170339071A1 (en) Apparatus and method for routing data in a switch
JP2019525349A5 (en)
US20170346753A1 (en) Method and device for forwarding data messages
US11907170B2 (en) Switching serialization techniques for handling concurrent write requests to a shared file
JP6396934B2 (en) Packet processing system and packet processing method
US8918559B2 (en) Partitioning of a variable length scatter gather list
US9678922B2 (en) Data storage control system, data storage control method, and data storage control program
US20190319901A1 (en) Scalable, real-time messaging system
US20140025730A1 (en) Managing concurrent conversations over a communications link between a client computer and a server computer
US9270742B2 (en) Computer system and control method of computer system
CN115955501B (en) Transmission Control Protocol TCP connection processing method and device
WO2013065151A1 (en) Computer system, data transmission method, and data transmission program
JP2019003245A (en) Service providing system, service providing server, service providing method and service providing program
JP2017016173A (en) Log output control device, log output control method, and program

Legal Events

Date Code Title Description
RD02 Notification of acceptance of power of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7422

Effective date: 20130606

RD04 Notification of resignation of power of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7424

Effective date: 20130802

A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20140124

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20140807

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20140924

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20141120

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

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20141211

R150 Certificate of patent or registration of utility model

Ref document number: 5667097

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

LAPS Cancellation because of no payment of annual fees