CSLRMDEL: delete resources

You can issue the CSLRMDEL request to delete one or more uniquely named resources, or all resources by owner for a specific resource type on a resource structure.

This request is supported in assembler language.

CSLRMDEL syntax

CSLRMDEL DSECT syntax

Use the DSECT function of a CSLRMDEL request to include the following resources in your program:

  • Equate (EQU) statement for the CSLRMDEL parameter list length
  • The CSLRMDEL return codes, reason codes, and completion codes
  • The CSLRDELL DSECT to map the input delete list
  • The CSLRDELO DSECT to map the delete output
Read syntax diagramSkip visual syntax diagramCSLRMDEL FUNC=DSECT

CSLRMDEL DELETE syntax

Use the DELETE function of a CSLRMDEL request to delete one or more uniquely named resources on a resource structure.

Read syntax diagramSkip visual syntax diagramCSLRMDEL FUNC=DELETE PARM= parm LIST= deletelist LISTLEN= deletelistlength OUTPUT= output OUTLEN= outputlength ECB= ecb RETNAME= returnname RETTOKEN= returntoken RETCODE= returncode RSNCODE= reasoncode SCITOKEN= scitoken

CSLRMDEL parameters

ECB=symbol
ECB=(r2-r12)
(Optional) - Specifies the address of a z/OS® ECB used for asynchronous requests. When the request is complete, the ECB specified is posted. If an ECB is not specified, the task is suspended until the request is complete. If an ECB is specified, the invoker of the request must issue a WAIT (or equivalent) after receiving control from CSLRMDEL before using or examining any data returned by this request (including the RETCODE and RSNCODE fields).
LIST=symbol
LIST=(r2-r12)
(Required) - Specifies the delete resource list built by the caller. Each list entry is a separate delete request. The list length can vary, depending on the number of list entries.

CSLRDELL maps the delete resource list entry. The list contains a header and one or more list entries. The list entries must reside in contiguous storage. Each delete list entry contains information about what to delete.

For delete by resource name, to delete a uniquely named resource:

  • Resource name - the client-defined name of the resource.
  • Resource type - a client-defined physical grouping of resources on the resource structure. Valid values are 1-255.
  • Version - resource version, which is the number of times the resource has been updated.

For delete by owner, to delete all resources owned by a particular owner for a resource type, regardless of the resource version:

  • Resource type - a client-defined physical grouping of the resources on the resource structure. Valid values are 1-255.
  • Owner - resource owner.
LISTLEN=symbol
LISTLEN=(r2-r12)
(Required) - Specifies the 4-byte delete resource list length.
OUTLEN=symbol
OUTLEN=(r2-r12)
(Required) - Specifies a 4-byte field to receive the length of the output returned by the CSLRMDEL request. OUTLEN contains the length of the output pointed to by the OUTPUT= parameter.

The output length is zero if no output is built, for example, if an error is detected before any output can be built.

OUTPUT=output
OUTPUT=(r2-r12)
(Required) - Specifies a 4-byte field to receive the address of the variable length output returned by the CSLRMDEL request. The output contains a header and one or more delete entries for resource deletes that were attempted. The output length is returned in the OUTLEN= field.

The output address is zero if no output was built, for example, if an error was detected before any output could be built.

The CSLRDELO macro maps the output that is returned. The output contains a header and one or more list entries.

The output header contains the following parameters:

  • Eyecatcher
  • Output length
  • CSLRDELO version
  • CSLRDELO header length (offset to start of entries)
  • CSLRDELO entry length
  • Resource entry count

Each output entry represents a resource delete that failed. Each entry contains the following parameters:

  • Output entry length - the list entry length
  • Name type - a client-defined value associated with a resource type that ensures uniqueness of client-defined resource names within a name type. Valid values are 1-255.
  • Resource name
  • Resource type
  • Delete type
  • Version - resource version of an existing resource if the delete request failed because of a version mismatch.
  • Owner - resource owner of an existing resource if the delete failed because of a version mismatch and the option to read the owner was set.
  • Completion code for the delete request. Completion codes are mapped by CSLRRR.

Possible completion codes are:

X'00000008'
Invalid resource type.
X'00000010'
Version mismatch. The version specified on input does not match the resource's version, so delete fails.
X'00000018'
Resource type is not registered. The resource type must be registered by using a CSLRMREG request.
X'00000024'
Resource structure is unavailable.
X'00000038'
Delete failed because of CQS internal error.
X'0000003C'
Delete failed because RM incorrectly built the CQSDEL list entry.

The output buffer is not preallocated by the caller. After being returned from the request, this word contains the address of a buffer containing the delete output. It is the caller's responsibility to release this storage by issuing the CSLSCBFR FUNC=RELEASE request when it is through with the storage. The length of the output is returned in the OUTLEN= field.

PARM=symbol
PARM=(r2-r12)
(Required) - specifies the CSLRMDEL parameter list. The length of the parameter list must be equal to the parameter list length EQU value defined by RDEL_PARMLN.
RETCODE=symbol
RETCODE=(r2-r12)
(Required) - specifies a 4-byte field to receive the return code on output. RM return codes are defined in CSLRRR. SCI return codes are defined in CSLSRR. Possible return codes are described in the following table.
RETNAME=symbol
RETNAME=(r2-r12)
(Optional) - Specifies an 8-byte field to receive the RM name returned to the caller. This is the CSL member name of the target RM address space to which SCI sent the request.
RETTOKEN=symbol
RETTOKEN=(r2-r12)
(Optional) - Specifies a 16-byte field to receive RM's SCI token returned to the caller. This is the SCI token for the target RM address space to which SCI sent the request.
RSNCODE=symbol
RSNCODE=(r2-r12)
(Required) - Specifies a 4-byte field to receive the reason code on output. RM reason codes are defined in CSLRRR. SCI reason codes are defined in CSLSRR. Possible reason codes are described in the following table.
SCITOKEN=symbol
SCITOKEN=(r2-r12)
(Required) - Specifies a 16-byte field containing the SCI token. This token uniquely identifies this connection to SCI. The SCI token was returned by a successful CSLSCREG FUNC=REGISTER request.

CSLRMDEL return and reason codes

The following table lists the return and reason codes that can be returned on a CSLRMDEL request. Also included is the meaning of a reason code (that is, what possibly caused it).

Table 1. CSLRMDEL return and reason codes
Return code Reason code Meaning
X'00000000' X'00000000' The request completed successfully.
X'03000008' X'00002000' The client is not registered.
  X'00002100' The delete list length is invalid.
  X'00002108' The delete list address is invalid.
  X'00002110' The version in the list header (DELL_PVER) is zero, which is invalid. The list version must be set in the list header to the maximum list version (DELL_PVERMAX).
  X'00002114' The list header length is invalid. The list header length cannot be zero or greater than the list length that was passed in. The list header length (DELL_HDRLEN) must be set in the list header to the list header length.
  X'00002200' One of the list entries contains an invalid resource type, such as zero. RM assumes that the rest of the list is invalid.
  X'0000220C' One of the list entries contains one or more invalid delete options. RM assumes that the rest of the list is invalid.
  X'00002210' A resource name or owner is required.
  X'00002214' The version is invalid.
  X'00002404' No resource structure is defined.
X'0300000C' X'00003000' The request succeeded for at least one, but not all, list entries. Check the completion code in each list entry in the OUTPUT buffer for individual errors.
  X'00003004' The request failed for all entries. Check the completion code in each list entry in the OUTPUT buffer for individual errors.
  X'00003008' The request failed for one or more list entries and all failures were version mismatches. Check the completion code in each list entry in the OUTPUT buffer for individual errors.
X'03000010' X'00004000' The CQS address space is unavailable. Retry the request again, which attempts to route the request to a different RM with an available CQS.
  X'00004100' The requested version is not supported. The client compiled with a version of CSLRMDEL that is not supported by RM. All RMs must be migrated to a new release before IMS is migrated to a new release that uses a new CSLRMDEL function.
  X'00004104' The list version is not supported. The client created the delete list at a version that is not supported by RM. All RMs must be migrated to a new release before the client is migrated to a new release that uses a new CSLRMDEL function.
X'03000014' X'00005000' Storage allocation for the delete output buffer failed.
  X'00005120' Storage allocation for the CQSDEL buffer failed.
  X'00005200' The CQS request resulted in unexpected error.
  X'00005204' The CQS request failed because RM incorrectly built the request input.