# US 2005/0097539 A1 · System and method for asynchronous processing in COBOL

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 2005/0097539 A1
- Document ID: US20050097539A1
- Status: Published application
- Kind: A1
- Application number: 10/697,417
- Filed: 2003-10-30
- Published: 2005-05-05
- Earliest claimed: 2003-10-30
- Assignees: Sprint Communications Company L.P.
- Inventors: Joseph Laura
- Web page: https://patentgrep.com/patent/US20050097539A1

## CPC

- G06F 9/52: Program synchronisation; Mutual exclusion, e.g. by means of semaphores
- G06F 9/542: {Event management; Broadcasting; Multicasting; Notifications}
- G06F 9/546: {Message passing systems or structures, e.g. queues}
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)

## Abstract

The present disclosure provides a method for enabling events in a COBOL program, including maintaining, in a COBOL program, a index including a process identifier and an event associated with a child process. The method includes placing the child process in a wait state and signaling, by the COBOL program, the child process to run using the process identifier and the event associated with the child process. A system for coordinating processing in COBOL programs is also provided. The system includes a first COBOL program having a first routine for processing, a second COBOL program having a second routine for processing, and a module callable by the first and second COBOL programs. The module maintains a state sharable between the first and second COBOL programs to coordinate the processing of the first and second routines.

## Claims

### Claim 1

A method for enabling events in a COBOL program, the method comprising:
maintaining, in a COBOL program, a index including a process identifier and an event associated with a child process;
placing the child process in a wait state;
signaling, by the COBOL program, the child process to run using the process identifier and the event associated with the child process.

### Claim 2 (depends on 1)

The method of claim 1, wherein the COBOL program signals a technical layer using the process identifier and event associated with the child process and further wherein the technical layer signals the child process to run.

### Claim 3 (depends on 1)

The method of claim 1, wherein the index maintained by the COBOL program maintains a plurality of identifiers and a plurality of events associated with a plurality of child processes.

### Claim 4 (depends on 1)

The method of claim 1, wherein the child process is placed in the wait state by a technical layer.

### Claim 5 (depends on 1)

The method of claim 1, wherein the technical layer is further defined as a COBOL technical layer in communication with the COBOL program.

### Claim 6 (depends on 1)

The method of claim 1, wherein the technical layer is further defined as COBOL library including at least one routine callable by the COBOL program.

### Claim 7 (depends on 1)

The method of claim 1, wherein the technical layer is integral to the COBOL program.

### Claim 8 (depends on 1)

The method of claim 1, wherein the technical layer is enabled by a COBOL compiler.

### Claim 9 (depends on 1)

The method of claim 1, wherein the technical layer is integral to a COBOL compiler.

### Claim 10 (depends on 1)

The method of claim 1, wherein the technical layer includes a coordination module operable.

### Claim 11 (depends on 1)

The method of claim 1, wherein the child process registers the process identifier of the child process with a technical layer.

### Claim 12 (depends on 11)

The method of claim 11, wherein the child process further registers the event associated with the child process with the technical layer.

### Claim 13 (depends on 1)

The method of claim 1, further comprising maintaining a plurality of child processes wherein the process identifiers and events associated with each of the plurality of child processes is maintained in the index of the COBOL program.

### Claim 14

The method of 13, further comprising:
providing a COBOL technical layer having a coordination module operable to coordinate signaling the plurality of child processes;
registering, by the plurality of child processes, with the COBOL technical layer;
signaling, by the COBOL program, the COBOL technical layer to run one or more of the plurality of child processes using the process identifiers and events associated with the child processes; and
coordinating, by the coordination module of the COBOL technical layer, the signaling of the child processes.

### Claim 15 (depends on 14)

The method of claim 14, wherein method further comprises:
creating a system resource by the COBOL program;
designating the system resource to a process identification of the COBOL program;
giving the system resource from the COBOL program to the child process using the process identifier of the child process; and
taking the system resource by the child process from the COBOL program.

### Claim 16 (depends on 15)

The method of claim 15, further comprising synchronizing such that the COBOL program completes giving the system resource prior to the child process taking the system resource.

### Claim 17 (depends on 16)

The method of claim 16, wherein the system resource is defined as a socket connection.

### Claim 18 (depends on 16)

The method of claim 16, wherein the system resource is defined as a pipe connection.

### Claim 19 (depends on 16)

The method of claim 16, further comprising:
placing the COBOL program in a wait state after giving the system resource to the child process; and
maintaining the COBOL program in the wait state until the child process takes the system resource.

### Claim 20

A system for coordinating processing in COBOL programs, comprising:
a first COBOL program having a first routine for processing;
a second COBOL program having a second routine for processing; and
a module callable by the first and second COBOL programs, the module maintaining a state sharable between the first and second COBOL programs to coordinate the processing of the first and second routines.

### Claim 21 (depends on 20)

The system of claim 20, wherein the module is further defined as a COBOL library having routines callable from the first and second COBOL programs.

### Claim 22 (depends on 20)

The system of claim 20, wherein the module is further defined as a COBOL callable routine.

### Claim 23 (depends on 20)

The system of claim 20, wherein the module is integral to the first and second COBOL programs.

### Claim 24 (depends on 20)

The system of claim 20, wherein the module is further defined as COBOL compiler enabled.

### Claim 25 (depends on 20)

The system of claim 20, wherein the module is further defined as a COBOL pre-compiler program used by the first and second COBOL programs.

### Claim 26 (depends on 20)

The system of claim 20, wherein the first and second routines are further defined as a first and second jobs and wherein the first and second COBOL programs analyze the state maintained by the technical layer to resolve the processing of the first and second jobs.

### Claim 27 (depends on 20)

The system of claim 20, wherein the module initiates a first state when the first routine is processing such that the second routine postpones processing in response to the first state of the module.

### Claim 28 (depends on 20)

The system of claim 20, wherein the module is operable to maintain a plurality of states based upon a task of the first and second routines.

### Claim 29 (depends on 20)

The system of claim 20, wherein the first and second routines are further defined as a first and second threads and wherein the module maintains the state sharable between the first and second COBOL programs to coordinate the processing of the first and second threads.

### Claim 30 (depends on 29)

The system of claim 29, wherein the first and second threads process in the same address space in a computer system.

### Claim 31 (depends on 20)

The system of claim 20, wherein the first and second routines are further defined as a first and second jobs and wherein the module maintains the state sharable between the first and second COBOL programs to coordinate the processing of the first and second jobs.

### Claim 32 (depends on 31)

The system of claim 31, wherein the first and second jobs process in separate address space in a computer system.

### Claim 33

A method for employing semaphores to coordinating processing in COBOL programs, comprising:
processing by a first COBOL program to a shared resource;
processing by a second COBOL program to the shared resource; and
maintaining a state sharable between the first and COBOL programs to coordinate the processing by of the first and second COBOL programs to the shared resource.

### Claim 34 (depends on 33)

The method of claim 33, further comprising providing a COBOL technical layer operable to maintain the sharable state.

### Claim 35 (depends on 34)

The method of claim 34, further comprising:
creating a semaphore, by the COBOL technical layer;
obtaining an identifier identifying the semaphore;
querying to determine whether the state indicates that the semaphore is locked;
changing the state to indicate that the semaphore is locked;
changing the state to indicate that the semaphore is unlocked;
obtaining a process identification number to determine a process associated with the semaphore; and
removing the semaphore from a computer system.

### Claim 36 (depends on 35)

The method of claim 35, wherein the state further defined as is a flag.

### Claim 37

A method of employing threads in COBOL programs, comprising:
outputting by a first COBOL program to a block of shared memory;
outputting by a second COBOL program to the block of share memory;
writing, by a COBOL routine, the output of the first COBOL program to a shared resource; and
writing, by the COBOL routine, the output of the second COBOL program to the shared resource.

### Claim 38 (depends on 37)

The method of claim 37, wherein the method includes creating the block of shared memory.

### Claim 39 (depends on 37)

The method of claim 37, further comprising:
passing the output of the first COBOL program to the COBOL routine;
writing, by the COBOL routine, the output of the first COBOL program to the block of shared memory;
passing the output of the second COBOL program to the COBOL subroutine; and
writing, by the COBOL subroutine, the output of the second COBOL program to the block of shared memory.

### Claim 40 (depends on 37)

The method of claim 37, wherein the first and second COBOL programs are further defined as a first and second COBOL subtasks.

### Claim 41 (depends on 37)

The method of claim 37, wherein the COBOL routine includes a coordination module and wherein the method further comprises:
gathering output from the first and second COBOL programs; and
coordinating the writing of the output from the first and second COBOL programs to the shared resource.

### Claim 42 (depends on 41)

The method of claim 41, wherein the technical layer is further defined as a COBOL library callable from the first and second COBOL programs.

### Claim 43 (depends on 41)

The method of claim 41, wherein the COBOL routine is integral to the first and second COBOL programs.

### Claim 44 (depends on 41)

The method of claim 41, wherein the COBOL routine is further defined as a compiler enabled function.

### Claim 45 (depends on 37)

The method of claim 37, wherein the share resource is further defined as a socket connection.

### Claim 46 (depends on 37)

The method of claim 37, wherein the shared resource is further defined as a display resource.

### Claim 47

A method for a COBOL program to use signal handlers, the method comprising:
registering, by a COBOL language program, a signal handler with an operating system, the signal handler associated with an event; and
executing, by the operating system, the signal handler on the event occurs.

### Claim 48 (depends on 47)

The method of claim 47, wherein the COBOL language program registers with a register of the operating system.

### Claim 49 (depends on 47)

The method of claim 47, wherein the signal handler executes a corrective process.

### Claim 50 (depends on 49)

The method of claim 49, wherein the corrective process is closing a file.

### Claim 51 (depends on 47)

The method of claim 47, wherein the signal handler executes a notification process.

### Claim 52 (depends on 47)

The method of claim 47, wherein the event is an input/output error.

### Claim 53 (depends on 47)

The method of claim 47, further comprising:
creating a memory block:
writing an identifier to the memory block related to a system processes being executed; and
reading from the memory block the identifier to determine the system process executed when the event occurred.

### Claim 54

A system for coordinating processing in COBOL, comprising:
a COBOL program desiring to process a first and second tasks to a shared resource;
a module in communication with the COBOL program and maintaining a shared state between the first and second tasks to coordinate processing to the shared resource, the COBOL program and module operating in the same runtime environment.
