DDM-related jobs and DDM conversations
This topic provides additional information about activation groups, source server jobs, target server jobs, and the DDM conversations used by those jobs.
For remote file processing, at least two separate jobs are used, one running on each server: a source job and a target job. (The source server job is the one in which the user application is running.) Multiple application programs can be running in different activation groups within a single source job. Each activation group within a source job has a separate DDM conversation and target job for the remote location information specified in the DDM files. Multiple DDM files share a conversation when the following items are true:
- The files are accessed in the same activation group within a source job.
- The files specify the same remote location combination.
For each DDM conversation, there is one target job, which includes the TDDM.
The SDDM runs within a source job or activation group on the source server. It can handle multiple DDM conversations with one or more target servers at the same time. For the same source job or activation group, one SDDM handles all the remote file access requests. This is true regardless of how many target servers or remote files are involved. No separate job for the SDDM exists in the server.
If the source server DDM files involved all use the same remote location information to identify the target server, one TDDM job is created for each source server job that requests access to one or more files on the target server.
The following figure shows five programs accessing six DDM files. The numbers in the upper set of boxes representing DDM files correspond to the same numbers in the lower set of boxes representing the associated remote files. These DDM files are using four different remote location descriptions to access six different remote files, all on the same target server. Seven DDM conversations are needed to handle the processing. An explanation of the DDM conversations follows:
- PGM1 and PGM2 run in different source jobs and are using DDM files (2 and 3) that contain the same remote location information. A separate conversation is needed for each source job.
- PGM3 in source job 3 uses the two DDM files (5 and 6) that both use the same remote location information. They will share the same conversation and target job (5B).
- PGM4 and PGM5 run in different activation groups within source job 4. They are using two DDM files (5 and 6) that both use the same remote location information. A separate conversation is needed for each activation group.
In the following figure, jobs 1, 2, and 3 in System A each have a SDDM. Each activation group in job 4 has its own SDDM. Jobs 1B through 7B each have their own TDDM. When the application program or the source job closes the DDM file on the source server, the DDM conversation and its associated target job ends, unless the following items are true:
Figure 1. Relationships of DDM source and target jobs
- The value of the DDMCNV attribute of the Change Job (CHGJOB) command for the source job is *KEEP (the server default).
- Any locks established during the job by the Allocate Object (ALCOBJ) command still exist.
The CHGJOB and ALCOBJ commands are described in topic Use CL and DDS with DDM. If DDMCNV(*KEEP) is specified, the DDM conversation remains active and waits for another DDM request to be started.
From a performance viewpoint, if the DDM conversation is likely to be used again, *KEEP is the value that should be used. This saves the time and resources used on the target server to start each TDDM and establish the conversation and job.
The following figure shows the relationship between the SDDM and two TDDMs on different target servers and the figure in Example: Access files on multiple servers with DDM topic shows the relationship between the SDDM and two TDDMs on one target server.
An iSeries™ server can be a source server and a target server at the same time, and two servers can be accessing files located on each other. In addition, an iSeries job can be a source job and a target job. A DDM file can refer to a remote file that is another DDM file. Figure 2. Example: Access multiple local and remote files. An iSeries server with communications links to a System/38™ and to a System/36™.
Parent topic:
Additional DDM concepts
Related concepts
Use CL and DDS with DDM
Related reference
Example: Access files on multiple servers with DDM
Additional considerations: SBMRMTCMD command
Related information