DISTRIBUTED PROCESSING SYSTEM AND METHOD

Abstract: In a processing system including a plurality of process­ ing units (11 . . . 16) connected to a common transmission line (1), program tests are permitted under on-line environ­ ments. Each of the processing units (11 . . . 16) decides whether or not a program loaded into it is a program to be tested, establishes a test mode when the program is to be tested, processes the program irrespective of whether or not the program is in the test mode, data of a test result be­ ing generated on the basis of data of a processed result when the program is in the test mode, and delivers the re­ sults to the common transmission line (1).

Description: Background of the Invention: Field of the Invention: The present invention relates to a distributed processing system. More particularly, it relates, in a distributed processing system including a plurality of processing units, to a distributed processing system and method which permit application program tests under on-line circumstances. Description of the prior Art: In a distributed processing system including plurality of processing units connected to a common transmission line, a method in which a program for executing each of a series of processes is started when data items necessary for executing the program have been completely received from the transmission line into its own processing unit is disclosed in the official gazette of Japanese Patent Application Laid-open No. 57-146361. This method makes it possible to execute the series of processes by the respective processing units without requiring an executive processor for managing the whole system. However, it does not have means for testing programs developed in order to be loaded in the respective processing units by the use of on-line data and deciding whether they are normal or abnormal in the on-line circumstances. Some of conventional systems other than the distributed processing system have means for gathering the result data of program processes. However, the means functions merely to take the logarithms of the data in time sequence and has been unsatisfactory for analyzing test results with the gathered results. Summary of the Invention: An object of the present invention is to eliminate the problem of the prior-art distributed processing system as stated above, and has for its object to provide, in a system wherein processes are executed by respective processing units without requiring an executive processor for managing the whole system, a distributed processing system and method which permit program tests under on-line circumstances. The present invention for accomplishing the object consists of a distributed processing method according to claim 1 or of a distributed processing system according to claim 4. Brief Description of the Drawings: Fig. 1 is a diagram showing a system architecture which is an embodiment of the present invention; Fig. 2 is a diagram showing a message format which is transmitted; Fig. 3, and Figs. 4(a) and 4(b) are diagrams showing the internal arrangement of a processor; Figs. 5(a) and 5(b), Fig. 6, and Figs. 7(a) and 7(b) are diagrams showing processing flows in the processor; Figs. 8(a) and 8(b), and Figs. 9(a) - 9(c) are diagrams for explaining test data gathering processes; and Fig. 10 is a diagram for explaining a program automatic-test process in a test unit. Detailed Description of the Preferred Embodiment: Fig. 1 is a general architectural diagram of a system to which the present invention is applied. Referring to the figure, numerals 11 - 16 designate processors each of which stores an application program in the internal memory thereof and can execute it, and numeral 1 designates a unidirectional loop transmission line in the direction of arrow. In addition, numerals 1001 - 1006 indicate network control processors NCP's each of which performs a data transmission control on the transmission line. Each of the NCP's 1001 - 1006 and the corresponding one of the processors 11 - 16 are connected bidirectionally. The processed results (data) of the processors 11 - 16 are forwarded onto the transmission line 1 via the NCP's 1001 - 1006. Each of the NCP's 1001 - 1006 decides whether or not data flowing on the transmission line 1 is necessary for the processor connected thereto, and it sends the data to its own processor only when the necessity has been decided. Each of the processors 11 - 16 starts the application program at the point of time at which all the data items required for executing the program stored in the processor have become complete. The started program executes its processes by the use of the data items. In this system, the processor 14 is assumed to conduct a test according to the method of the present invention, and a CRT console 14000 is connected thereto. Besides, in this system, an external input/output equipment 10001 is connected to the processor 11, and data is fed in from an external process through the external input/output equipment 10001. In case that the received data includes the information indicative of test mode, each processor executes the program which uses the above data and generates data of a test result on the basis of data of the processed result irrespective whether or not the executed program is in the test mode or not. Fig. 2 shows the format of the data flowing on the transmission line 1. 201(f) denotes a flag which indicates the start of a message, and 202(CC) a content code which corresponds to the content of the data. On the basis of the content code, each NCP decides whether or not the received data is necessary for the processor connected thereto. 203(SA) denotes the address of the NCP having sent the data (sending address), and 204(C) a sequence number required for transmission. 206(DATA) denotes information to be processed by the corresponding application program, 207(FCS) fault detection data, and 208(F) a flag indicating the end of the message. In addition, 205(EN) denotes a sequence number at a processing level, which consists of a processor number and a data generation sequence number. Hereinafter, this shall be called "event number." Fig. 3 is a diagram showing the internal arrangement of the processor 11 illustrated in Fig. 1 before, and each of the other processors 12 - 16 has the same arrangement. An interface 101 is a unit which transfers data between the NCP 1001 and the processor 11, and through which data received from the NCP is stored in a receiving buffer 103. Besides, the unit 101 transfers data in a sending buffer 104 to the NCP and simultaneously stores the data in the sending buffer 104 in the receiving buffer 103 in a case where it is necessary for the application program loaded in its own processor. A test unit 105 is a unit which serves for the test according to the present invention, and a program attribute register 106 is a table which stores therein information items indicating whether or not the respective application programs are in a test mode. An own processor number register 113 is an area which stores one of numbers assigned to the respective processors so as to differ from one another, and a sequence number register 114 is an area which is used as a counter for the number of generated data. A processing unit 107 is a unit which serves to control the execution of the application programs 1101 - 1103. Besides, an interface 111 is a unit for receiving an input from the external input/output equipment 10001. A content code register 112 is an area in which the content codes of external input data are stored. An input/output data register 109 is an area which serves to store input/output data for each of the application programs. Fig. 4(a) is a diagram showing the contents of the input/output data register 109. The first line 1091 of the area 109 consists of input/output data areas for the application program 1101, and the area 10911 stores the input data of the application program 1101, while the area 10912 stores the processed result thereof. The second area 1092 of the area 109 consists of areas for storing the input/output data of the application program 1102. Thenceforth, input/output data areas are similarly set for the respective application programs. Fig. 4(b) is a diagram showing the format of the data which is stored in the input data area or the output data area. 10901(CC) denotes the content code of the input data or output data, 10902(EN) the event number of the input or output data, and 10903(DATA) the data content of the input or output data. Now, the test method which is an embodiment of the present invention will be described. Figs. 5(a) and 5(b) are diagrams showing processing flows in the processing unit 107. First, processing at the reception of data will be described with reference to Fig. 5(a). Data is received from the receiving buffer 103, and the content code (CC), event number (EN) and data part (DATA) of the received data are stored in the input data area within the input/output data area (step 501). Subsequently, the processing unit decides whether or not an executable application program exists, that is, whether or not input data items necessary for the execution of the program are all stored in the input data areas (10911 etc.) (step 502). In a case where the executable program exists, the event number area content (EN) of the input data area corresponding to the program is stored in the event number area of the output data area corresponding to the program, without any change (step 503). Here, in case of the application program which is started with a plurality of input data items, the event number areas of the output data area are taken in the number of the input data items, and the event numbers of all the input data items are stored in the event number areas within the output data area, without any change. Thereafter, the application programs having become executable are successively started (step 504). The started application program executes processes on the basis of the data within the input data area corresponding thereto, and sets the results in the output area corresponding thereto. When the execution of the started application program has ended owing to the above processes, the processing unit 107 decides whether or not the output data is stored in the output data area (step 521 in Fig. 5(b)). When stored, the data is transferred to the test unit 105 (step 522 in Fig. 5(b)). Fig. 6 is a diagram showing the processing of the interface 111. Upon generation of an external input, the interface 111 decides the content code of the input data in view of the content code register 112 and sets the content of the input data as well as the content code decided from the content code register 112, in the sending buffer 104 (step 610). Next, the unit 111 sets the content of the own processor number register 113 and the content of the sequence number register 114 in the event number area within the sending buffer 104 (step 611). Thereafter, the content of the sequence number register is incremented by "1." Now, the processing of the test unit 105 after the execution of the application program will be described with reference to Figs. 7(a) and 7(b). The test unit 105 having received the output result of the application program from the processing unit 107 decides whether or not the application program is in the test mode, from the set status of a test flag in the program attribute register 106, and when the program is not in the test mode, the test unit stores the data received from processing unit as it is, in the sending buffer 104 (steps 701 and 702 in Fig. 7(a)). In contrast, when the program is in the test mode, the test unit 105 generates test data whose data part has the data received from the processing unit 107 (step 703) and stores it in the sending buffer 104 (step 704). The data in the sending buffer is constructed into the transmission format in the interface 101, and then transferred onto the transmission line 1. Fig. 7(b) shows the format of the test data which is generated at the processing step 703. In a content code area 750, a content code CC T indicative of the test data is set. In an event number area 751, the content of the own processor number register 113 and that of the sequence number register 114 are set. After the event number setting process, the test unit 105 increments the content of the sequence number register by "1." In the data part 752, the data contents received from the processing unit 107, namely, the content code 7521, data part 7523 and event number 7522 of the application program output are set as they are. Owing to the processes of the processing unit 107 and the test unit 105 stated above, the developed application program is loaded in the processor as the test mode, and the test flag in the program attribute register is set, whereby during the on-line operation, the test can be started using on-line data without exerting any influence on the system. Besides, the output data of the program executed for the test is reconstructed by the test unit 105 into the test data ( content code CC T ), which is delivered onto the transmission line 1, so that any of the processors can receive the test data and analyze the result of the test start. Now, the processing of gathering the test data will be described with reference to Figs. 8(a) and 8(b) and Figs. 9(a) to 9(c). Fig. 8(a) is a diagram showing the flows of data between the system architecture and the application program. Here, let's consider a case where a program B (1401) which executes processes by the use of the output results of an on-line operation application program A (1201) in the processor 12 is loaded in the processor 14 with the test mode set therefor so as to be tested using on-line data. The interface 111 in the processor 11 accepts input data from the external input equipment 10001, and generates data 801 which includes a content code CC I (8011 in Fig. 8(b)), an event number (8014) consisting of a processor number 11 and a data generation sequence number 1, and an external input data content DATA I (8015), in accordance with the flow illustrated in Fig. 6. This data is transferred onto the transmission line 1 through the NCP 1001. In the data format 801 shown in Fig. 8(b), SA₁ (8012) denotes the address of the NCP 1001, and C₁ (8013) denotes a sequence number required for transmission. The processor 12 receives the data 801 through the NCP 1002, and the processing unit 107 thereof starts the application program A (1201) in accordance with the flow of Fig. 5(a). The application program A executes a process by the use of the data content DATA I (8015) within the data 801, and sets processed result data DATA A as well as a content code CC A indicative of the content thereof in the output data area of the input/output data area 109. This processed result is transferred onto the transmission line 1 as data in a format shown at numeral 802 in Fig. 8(b), through the processing unit 107, interface 101 and NCP 1002. Besides, in an event number area 8024, the content of the event number of the data 801 as left intact is set by the processing unit. The processor 14 is loaded with a program T (1402) for gathering the test start results, in addition to the program B (1401) in the test mode to be started with the data 802. Fig. 9(a) shows the scheme of the data gathering program T. The program T is composed of a program T₁ (14021) which is started with the start data 802 of the program B having the content code CC A , a program T₂ (14022) which is started with test data having a content code CC T , and a data storage area 14023. The data storage area 14023 consists of an area 140231 for storing the input data of the program B, and an area 140232 for storing the output data thereof. Each of these areas is constructed of a data storage buffer corresponding to a previously appointed number of data items, and it has a cyclic buffer arrangement in which, when the number is exceeded, an older data item stored is erased earlier. The program B in the processor 14 is started with the output data 802 of the program A as shown in Fig. 8(a), executes a process by the use of the content DATA A (8025) within the data 802, and outputs processed result data DATA B as well as a content code CC B indicating the content thereof. Since the program B is in the test mode, the test unit 105 within the processor 14 accepts the output data and reconstructs it into test data 803, which is delivered. Meanwhile, the program T₁ 14021 in the processor 14 is also started with the data 802 and executes the process of its own (refer to Fig. 8(a)). The processing flow of the program T₁ is shown in Fig. 9(b). The program T₁ stores the content code CC A (8021), event number EN₁ (8024) and data part content DATA A (8025) within the input data 802, in the CC A data storage area 140231 (step 901). Subsequently, it is decided whether or not data having the same event number as that of the current input data 802 has already been stored in the test data storage area 140232 (step 902). When such data has been stored, the data applied this time and the data in the test data storage area having the same event number as that of the former are displayed as test result information on the CRT console 14000 (step 903). The program T₂ (14022 in Fig. 9(a)) is started with the test data 803 (refer to Fig. 8(b)), and executes the process of its own. The processing flow of the program T₂ is shown in Fig. 9(c). The program T₂ stores a content code CC B (80351), event number (80352) and data content DATA B (80353) within the data part 8035 of the input data 803, in the test data storage area (140232 in Fig. 9(a)) (step 950). Subsequently, it is decided whether or not data having the same event number as the event number within the data part 8035 of the current input data 803 has already been stored in the CC A data storage area 140231 (step 951). When such data has been stored, the data items in the CC A data storage area and the test data storage area having the same event number are displayed as test results on the CRT console 14000 (step 952). As stated above, according to the present embodiment, a developed program is loaded as a test mode program in any desired processor, whereby during an on-line operation, the program can be started for a test by the use of on-line data without affecting a system. Moreover, the input data of the program and the output result corresponding thereto can be gathered in any desired processor. The embodiment has referred to only the case where the program is started for the test with the on-line data. Further, an area for storing the normal output pattern of an applicable program and an output fault detection flag are set in the program attribute register (106 in Fig. 3), and the test unit (105 in Fig. 3) is endowed with the function of resetting a program attribute flag when output values for input data items in a fixed period or in a fixed number since the loading of the test mode program have been decided faultless as compared with the aforementioned normal output pattern, whereby the program loaded in the processor is permitted to automatically come into an on-line operation after the test with the on-line data of the program has ended. By way of example, Fig. 10 shows the processing flow of the test unit in the case where input data items in a fixed number (N o ) are subjected to the test. This example illustrates a case where a program is deemed faultless when the contents of program output data have agreed with a normal output pattern. Steps 1701 - 1704 are the same processes as those shown as the steps 701 - 704 in Fig. 7(a). After storing test data in the sending buffer (step 1704), whether or not the contents of program output data coincide with an output pattern in the program attribute register is decided (step 1705). In case of non-coincidence, an output fault detection flag in the program attribute register is set (step 1706). Thereafter, the input data counter corresponding to the program started this time is incremented by "1" (step 1707). Subsequently, the counter value is compared with a predetermined value N o (step 1708). When the counter value is equal to or greater than the value N o , the fault detection flag is decided (step 1709). Unless the fault is set, a test flag in the program attribute register is reset (step 1710). Owing to the foregoing processes, the program loaded in the processor is not immediately operated, but it is automatically tested under on-line circumstances and is permitted to come into the on-line operation only when decided faultless as the result of the test. In the embodiment, the test program and the data gathering program have been set in the processor 14. However, these programs can be set in any desired processor other than the processor 14 so as to conduct the test. Moreover, the test program and the data gathering program can be set in different processors so as to conduct the test. Besides, in the embodiment, the unidirectional loop transmission line has been mentioned as an example of the common transmission line. Needless to say, however, a common transmission line in any other form may be used as long as it is a data transmission medium. As preferable aspects of performance of the present invention, the following items can be listed: (1) In a decentralized processing system wherein the series of processes of one task are executed in decentralized fashion by a plurality of processors connected to a common transmission line; a decentralized processing system characterized in that said each processor comprises means to decide whether or not an application program loaded in its own processor is in a test mode, and means to receive data of a processed result of said application program and to generate and deliver data of a test result, whereby when a decided result of the decision means is the test mode, the data of the test result is delivered onto said common transmission line by the data generation and delivery means. (2) A decentralized processing system as defined in Item (1), wherein a program which gathers input data of the test mode program and test result data corresponding to the input data and which displays them after associating them to each other is further set in any of said processors. (3) A decentralized processing system as defined in Items (1) and (2), wherein said each processor further includes therein an output pattern preset in correspondence with the test mode program, and a program is set therein according to which the test result data is compared with the output pattern, the test mode of said processor being released in accordance with a result of the comparison. As described above, according to the present invention, in a system wherein the series of processes of one task are decentralizedly executed by a plurality of processors connected to a common transmission line, developed application programs can be tested under on-line circumstances by any desired processor, and the results of the tests can be gathered, so that the efficiency of the program tests rises. Besides, only when the result of the test has been recognized normal, the program can be brought into an on-line operation, so that the reliability of a system rises.

Claims: A distributed processing method in a processing system wherein a plurality of programs can be executed in decentralised fashion by a plurality of processing units (11...16) connected to a common transmission line (1), characterised in that each processing unit (11...16) executes each program loaded into it either in a conventional program processing mode or in a test mode and executes the steps of: receiving a message from a processing unit, deciding, on the basis of the received message, whether or not a program loaded into it is to be executed in the test mode, establishing the test mode when the program is to be tested, processing the program irrespective of whether or not it is executed in the test mode, data of a test result being generated on the basis of data of a processed result when the program is executed in the test mode, and delivering the result to said common transmission line (1). The method of claim 1, wherein the program is an application program. The method of claim 1, wherein the data of a test result are generated on the basis of data of a processed result of the program. A distributed processing system wherein a plurality of programs can be executed in the decentralised fashion by a plurality of processing units (11...16) connected to a common transmission line (1), characterised in that each processing unit (11... 16) executes each program loaded into it either in a conventional program processing mode or in a test mode, and comprises means (103) to receive a message from a processing unit, means (107) to decide, on the basis of the received message, whether or not the program loaded into it is to be executed in the test mode, means (106) to establish the test mode when the program is to be tested, means (105) to process the program irrespective of whether or not it is executed in the test mode, and to generate data of a test result on the basis of data of a processed result when the program is executed in the test mode, and means (104) to deliver the result to said common transmission line (1).

Inventors: KASAJIMA, HIROKAZU, KAWANO, KATSUMI, KOIZUMI, MINORU, MORI, KINJI, NAKAI, KOZO, ORIMO, MASAYUKI, SUZUKI, YASUO
Applicants: HITACHI, LTD.
Application year: 1986
Main classification: G06F11
IPC codes: G06F11, G06F15