Claims
- 1. A method of storing and distributing messages in a data processing system, the steps of the method performed by said data processing system, comprising:
- establishing a message queue that stores messages in a computer memory in an order sequence, said message queue having a beginning and an end;
- providing a multiplicity of reader interfaces to said message queue, each reader interface accessing all the messages stored in said message queue in sequence starting at the beginning of said message queue, such that each message stored in said message queue is accessed only once by each reader interface,
- running at least one writer process, said at least one writer process generating messages;
- storing each message generated by said at least one writer process at the end of said message queue;
- running a multiplicity of reader processes;
- coupling each reader process to one of said multiplicity of reader interfaces such that each reader interface is coupled to at least one of said reader processes;
- each reader process prompting the reader interface coupled thereto to access a next one of said messages in said message queue and to pass a copy thereof to said reader process; and
- each reader interface, in response to said prompting by said at least one reader process coupled thereto, passing a copy of a next one of said messages stored in said message queue to a reader process coupled to said reader interface that first prompts said reader interface, and then preventing access to said next one of said messages by any other reader processes coupled to said reader interface, such that each message stored in said message queue is accessed by exactly one of said at least one reader processes coupled to each said reader interface.
- 2. The method of claim 1, further characterized by said data processing system performing the steps of:
- storing in said computer memory data representing the total number of said multiplicity of reader interfaces;
- recording in said computer memory data corresponding to the number of accesses to each message of said message queue;
- deleting a first message at the beginning of said message queue when said first message has been accessed a number of times equal to the number of said multiplicity of reader interfaces.
- 3. The method of claim 2, further characterized by said data processing system performing the steps of:
- storing in said computer memory a respective message type identifier for each respective message stored in said message queue;
- storing in said computer memory, for at least one said reader interface, a respective filter definition denoting one or more of said message type identifiers;
- screening each one of said messages in said message queue accessed by said at least one reader interface having a respective stored filter definition to determine whether said message type identifier matches said stored filter definition; and
- passing a copy of said one accessed message to said at least one reader process coupled thereto only when said one accessed message has a stored message type identifier matching said respective stored filter definition.
- 4. The method of claim 1, further characterized by said data processing system performing the steps of:
- storing a respective message type identifier for each respective message stored in said message queue;
- storing, for at least one said reader interface, a respective filter definition denoting one or more of said message type identifiers;
- screening each one of said messages in said message queue accessed by said at least one reader interface having a respective stored filter definition to determine whether said message type identifier matches said stored filter definition;
- passing a copy of said one accessed message to said at least one reader process coupled thereto only when said one accessed message has a stored message type identifier matching said respective stored filter definition.
- 5. The method of claim 4, further characterized by said data processing system performing the steps of:
- storing in said computer memory a count value for each respective message stored in said message queue, said stored count value indicating a maximum number of times that said respective message can be accessed;
- whenever any one of said multiplicity of reader interfaces accesses one of said messages stored in said message queue, decrementing said count value stored for said one accessed message; and
- deleting each respective message stored in said message queue when said count value stored for said respective message is decremented to a value of zero.
- 6. The method of claim 1, further characterized by said data processing system performing the steps of:
- storing in said computer memory a count value for each respective message stored in said message queue, said stored count value indicating a maximum number of times that said respective message can be accessed;
- whenever any one of said multiplicity of reader interfaces accesses one of said messages stored in said message queue, decrementing said count value stored for said one accessed message; and
- deleting each respective message stored in said message queue when said count value stored for said respective message is decremented to a value of zero.
- 7. The method of claim 1, wherein said coupling step includes coupling a plurality of said reader processes to one of said reader interfaces.
- 8. The method of claim 3, wherein said coupling step includes coupling a plurality of said reader processes to one of said reader interfaces.
- 9. The method of claim 5, wherein said coupling step includes coupling a plurality of said reader processes to one of said reader interfaces.
Parent Case Info
This is a continuation of application Ser. No. 07/939,392 filed Aug. 31, 1992, which is a continuation of application Ser. No. 07/374,099 filed Jun. 29, 1989, both now abandoned.
US Referenced Citations (19)
Continuations (2)
|
Number |
Date |
Country |
Parent |
939392 |
Aug 1992 |
|
Parent |
374099 |
Jun 1989 |
|