Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                

141 W445ngsc415443

Download as pdf or txt
Download as pdf or txt
You are on page 1of 10

0045 CONTROL_DATA_COMPLETE, CONFIRM 031D CONTROL_DATA_COMPLETE,

0046 CONTROL_DATA_COMPLETE, CONFIRM_DEALLOCATE


CONFIRM_DEALLOCATE 0344 CONTROL_DATA_COMPLETE,
0200 DATA_COMPLETE, SEND CONFIRM_SEND

0201 DATA_COMPLETE 0345 CONTROL_DATA_COMPLETE, CONFIRM

0202 CONTROL_DATA_COMPLETE 0346 CONTROL_DATA_COMPLETE,


CONFIRM_DEALLOCATE
0204 CONTROL_DATA_COMPLETE, SEND
0357 TAKE_COMMIT
0205 CONTROL_DATA_COMPLETE
0358 TAKE_COMMIT_SEND
0206 CONTROL_DATA_COMPLETE, SEND
0359 TAKE_COMMIT_DEALLOCATE
02081 DATA_COMPLETE
3421 CONTROL_DATA_TRUNCATED
020C1 CONTROL_DATA_COMPLETE
3422 CONTROL_DATA_TRUNCATED
02111 CONTROL_DATA_COMPLETE
3431 DATA_TRUNCATED
0213 CONTROL_DATA_COMPLETE,
CONFIRM_SEND 3471 DATA_INCOMPLETE

0214 DATA_COMPLETE, CONFIRM_SEND 3481 CONTROL_DATA_INCOMPLETE


1The LU 6.2 architected return code DEALLOCATE is
0215 DATA_COMPLETE, CONFIRM
returned by this ICF return code.
0218 CONTROL_DATA_COMPLETE, CONFIRM
021C DATA_COMPLETE, CONFIRM_DEALLOCATE
WHAT_RECEIVED Values Mapped to ICF Return Codes:
The following list shows the WHAT_RECEIVED values for
021D CONTROL_DATA_COMPLETE, the MC_RECEIVE_AND_WAIT verb with the corresponding
CONFIRM_DEALLOCATE ICF return codes.
0244 CONTROL_DATA_COMPLETE, WHAT_RECEIVED Value ICF Return Codes
CONFIRM_SEND
DATA_COMPLETE 0000, 0001, 00081, 0010, 0014, 0015,
0245 CONTROL_DATA_COMPLETE, CONFIRM 001C, 0200, 0201, 02081, 0214, 0215, 021C
0246 CONTROL_DATA_COMPLETE, DATA_TRUNCATED 3431
CONFIRM_DEALLOCATE
DATA_INCOMPLETE 3471
0257 TAKE_COMMIT
CONTROL_DATA_COMPLETE 0002, 0004, 0005, 0006,
0258 TAKE_COMMIT_SEND 000C1, 00111, 0013, 0018, 001D, 0044, 0045,
0259 TAKE_COMMIT_DEALLOCATE 0046, 0202, 0204, 0205, 0206, 020C1, 02111,
0213, 0218, 021D, 0244, 0245, 0246, 0302,
0300 SEND 0304, 0305, 0306, 030C1, 03111, 0313, 0318,
0301 031D, 0344, 0345, 0346
0302 CONTROL_DATA_COMPLETE CONTROL_DATA_TRUNCATED 3421, 3422
0304 CONTROL_DATA_COMPLETE, SEND CONTROL_DATA_INCOMPLETE 3481
0305 CONTROL_DATA_COMPLETE SEND 0000, 0004, 0006, 0200, 0204, 0206, 0300,
0304, 0306
0306 CONTROL_DATA_COMPLETE, SEND
CONFIRM 0015, 0018, 0045, 0215, 0218, 0245, 0315,
03081
0318, 0345
030C1 CONTROL_DATA_COMPLETE
CONFIRM_SEND 0013, 0014, 0044, 0213, 0214, 0244,
03111 CONTROL_DATA_COMPLETE 0313, 0314 0344
0313 CONTROL_DATA_COMPLETE, CONFIRM_DEALLOCATE 001C, 001D, 0046, 021C, 021D,
CONFIRM_SEND 0246, 031C, 031D, 0346
0314 CONFIRM_SEND TAKE_COMMIT 0257, 0357
0315 CONFIRM TAKE_COMMIT_SEND 0258, 0358
0318 CONTROL_DATA_COMPLETE, CONFIRM TAKE_COMMIT_DEALLOCATE 0259, 0359
031C CONFIRM_DEALLOCATE 1The LU 6.2 architected return code DEALLOCATE is
returned by this ICF return code.

Appendix C. Implementation of the LU Type 6.2 Architecture C-7


Response Indicators Mapped to WHAT_RECEIVED 1The LU 6.2 architected return code DEALLOCATE is
Values: The following list shows the DDS response indica- returned by this ICF return code.
tors with the corresponding WHAT_RECEIVED values for the
MC_RECEIVE_AND_WAIT verb. MC_RECEIVE_IMMEDIATE: Receives any information
that is available from the specified mapped conversation, but
Response Indicators WHAT_RECEIVED Values
does not wait for information to arrive. The information can
RCVCONFIRM CONFIRM, CONFIRM_SEND, be data, mapped conversation status, or a request for confir-
CONFIRM_DEALLOCATE mation. Control is returned to the program with an indication
RCVTRNRND SEND, CONFIRM_SEND, of whether any information was received and, if so, the type
TAKE_COMMIT_SEND of information.

RCVDETACH CONFIRM_DEALLOCATE, There are no ICF operations or functions that map to this
TAKE_COMMIT_DEALLOCATE verb.
RCVCTLDTA CONTROL_DATA_COMPLETE,
CONTROL_DATA_TRUNCATED, MC_REQUEST_TO_SEND: The
CONTROL_DATA_INCOMPLETE MC_REQUEST_TO_SEND verb tells the remote program
that the local program requests to enter send state for the
RCVTKCMT TAKE_COMMIT, TAKE_COMMIT_SEND, conversation. The conversation is changed to send state
TAKE_COMMIT_DEALLOCATE when the local program receives a SEND indication from the
remote program.
Data Received with the Program Start Request: The fol-
lowing list shows ICF return codes with the corresponding The MC_REQUEST_TO_SEND verb is specified by using a
WHAT_RECEIVED values for the MC_RECEIVE_AND_WAIT request-to-write function. The request-to-write function is
verb. These ICF return codes also indicate that data was specified in DDS by using the RQSWRT keyword and in
received with the program start request. system-supplied formats with a $$RCD. The DDS format
ICF Return Code WHAT_RECEIVED Values may also include the INVITE keyword. The system-supplied
format has an implicit invite specified. Note that the invite
0002 CONTROL_DATA_COMPLETE
function also performs the MC_POST_ON_RECEIPT verb.
0006 CONTROL_DATA_COMPLETE, SEND
RESOURCE
00111 CONTROL_DATA_COMPLETE Refer to “Specifying the Resource Parameter” on
0013 CONTROL_DATA_COMPLETE, page C-3.
CONFIRM_SEND
RETURN_CODE
0018 CONTROL_DATA_COMPLETE, CONFIRM Information is returned as follows:
001D CONTROL_DATA_COMPLETE, Ÿ Messages
CONFIRM_DEALLOCATE
Ÿ Return codes in the communications device
0202 CONTROL_DATA_COMPLETE dependent area of the I/O feedback area
0206 CONTROL_DATA_COMPLETE, SEND
02111 CONTROL_DATA_COMPLETE MC_SEND_DATA: The MC_SEND_DATA verb sends
data or control information to the remote program. This oper-
0213 CONTROL_DATA_COMPLETE, ation is verb is used with a write operation.
CONFIRM_SEND
RESOURCE
0218 CONTROL_DATA_COMPLETE, CONFIRM
Refer to “Specifying the Resource Parameter” on
021D CONTROL_DATA_COMPLETE, page C-3.
CONFIRM_DEALLOCATE
DATA
0302 CONTROL_DATA_COMPLETE Application program's data buffer.
0306 CONTROL_DATA_COMPLETE, SEND
LENGTH
03111 CONTROL_DATA_COMPLETE For DDS, implicit by the record format or specified
0313 CONTROL_DATA_COMPLETE, explicitly by the VARLEN keyword.
CONFIRM_SEND For system-supplied formats, the first 4 bytes of the
0318 CONTROL_DATA_COMPLETE, CONFIRM output buffer of the application program contain the
length of data to send.
031D CONTROL_DATA_COMPLETE,
CONFIRM_DEALLOCATE MAP_NAME
Indicates that map name processing is to be performed.
3422 CONTROL_DATA_TRUNCATED
Ÿ For DDS use the FMTNAME keyword and specify

C-8 OS/400 APPC Programming V4R1


*RMTFMT on the ADDICFDEVE or OVRICFDEVE MC_TEST: The MC_TEST verb determines if the
command. requested status information is available. When using ICF
Ÿ Not supported by system-supplied formats. APPC, the application program can check the request-to-
write indicator in the I/O feedback area to determine if a
USER_CONTROL_DATA REQUEST_TO_SEND has been received. This field in the
Indicates that the data record contains user control data. I/O feedback area is only updated on an application I/O
boundary. If a REQUEST_TO_SEND is sent to a program
Ÿ For DDS, use the CTLDTA keyword.
after it has issued its last operation, the field will not be
Ÿ Not supported by system-supplied formats. updated.
RETURN_CODE
Information is returned as follows: RESOURCE
Refer to “Specifying the Resource Parameter” on
Ÿ Messages
page C-3.
Ÿ Return codes in the communications device
dependent area of the I/O feedback area TEST(Request_To_Send_Received)
Indicator in the communications device dependent area
REQUEST_TO_SEND_RECEIVED of the I/O feedback area.
Communications device dependent area of the I/O feed-
back area as follows: TEST(POSTED)
A get-attributes operation. Refer to position 41 in
Ÿ Request-to-write indicator Table C-1 on page C-11 for more information.
Ÿ Minor return code of 10 for major return code of 00 Note: The ICF APPC implementation does not have a func-
tion to perform the MC_TEST verb. Because this
MC_SEND_ERROR: The MC_SEND_ERROR verb function does not exist, the AS/400 system does not
informs the remote transaction program that the local reset the Request_to_Send_Received indicator value
program detected an error. The AS/400 system uses the in the same way as the architecture does when the
FAIL DDS keyword or the $$FAIL system-supplied format to MC_TEST verb is issued.
provide this function.

If the conversation has a synchronization level of commit, the Basic Conversation Verbs
fail function may cause the system to roll back the protected
LUW. If the fail function is in response to a commit operation, ALLOCATE: The LU type 6.2 verb ALLOCATE builds a
the system rolls back the protected LUW. If the fail function conversation (AS/400 transaction) to a named partner
is in response to a prepare-for-commit function, the system program at another logical unit (LU). For the AS/400 APPC
does not roll back the protected LUW. support, it is specified by the combination of the acquire
operation and evoke function.
RESOURCE
Note: Some of the information used by these operations is
Refer to the “Specifying the Resource Parameter” on
specified on commands that run before the applica-
page C-3.
tion program issues these requests.
RETURN_CODE
LU_NAME
Information is returned as follows:
RMTLOCNAME, DEV, RMTNETID, and LCLLOCNAME
Ÿ Messages parameters on the ADDICFDEVE, CHGICFDEVE, and
OVRICFDEVE commands.
Ÿ Return codes in the communications device
dependent area of the I/O feedback area MODE_NAME
MODE parameter on the ADDICFDEVE, CHGICFDEVE,
REQUEST_TO_SEND_RECEIVED
and OVRICFDEVE commands.
Communications device dependent area of the I/O feed-
back area as follows: TPN
For DDS, the remote program and library name are
Ÿ Request-to-write indicator
specified following the EVOKE keyword.
Ÿ Minor return code of 10 for major return code of 00
For system-supplied formats, the remote program name
is in positions 1 through 8 of the data buffer of the
source program and the library name is positions 25
through 32 of the same buffer.

TYPE
(BASIC_CONVERSATION/ MAPPED_CONVERSATION)
To allocate a basic conversation, the CNVTYPE param-

Appendix C. Implementation of the LU Type 6.2 Architecture C-9


eter on the ADDICFDEVE, CHGICFDEVE, and CONFIRM: CONFIRM ends a message and asks the
OVRICFDEVE commands must be specified as *USER. remote transaction program to confirm that no errors have
To allocate a mapped conversation, the CNVTYPE been detected in the message. Support for CONFIRM is pro-
parameter on the ADDICFDEVE, CHGICFDEVE, and vided by the CONFIRM DDS keyword. CONFIRM is not sup-
OVRICFDEVE commands must be specified as *SYS. ported when using system-supplied formats.

RETURN_CONTROL RESOURCE
WHEN_SESSION_ALLOCATED is always used. Refer to “Specifying the Resource Parameter” on
CONVERSATION_GROUP_ID is not supported. page C-3.

SYNC_LEVEL(NONE/CONFIRM/SYNCPT) RETURN_CODE
Information is returned as follows:

Ÿ SYNLVL DDS keyword (*NONE, *CONFIRM, or Ÿ Messages


*COMMIT supported) specified with EVOKE Ÿ Return codes in the communications device
keyword. dependent area of the I/O feedback area
Ÿ For system-supplied format, support is always REQUEST_TO_SEND_RECEIVED
defaulted to NONE. System-supplied formats do Communications device dependent area of feedback
not support CONFIRM or SYNCPT processing. area as follows:
SECURITY Ÿ Request-to-write indicator
SECURITY(NONE) is done by not specifying the SECU-
RITY DDS keyword or by specifying SECURITY(3 Ÿ Minor return code of 10 for major return code 00
*NONE).
SECURITY(SAME) is done by specifying SECURITY(3 CONFIRMED: CONFIRMED sends a confirmation reply to
*USER). If a profile ID was received to start this job, it is the remote program. By sending CONFIRMED, the local
passed on whenever an EVOKE is done by specifying application program takes responsibility for any data it has
SECURITY(3 *USER). received. This verb is only valid in response to a CONFIRM
request.
SECURITY(PGM) is done in the following manner:
DDS SECURITY keyword (user ID, password, and A confirmed response is sent by using a DDS record format
profile ID are all allowed) specified with the EVOKE with the RSPCONFIRM DDS keyword.
keyword. RESOURCE
For system-supplied formats the following can be speci- Refer to “Specifying the Resource Parameter” on
fied in the source program's data buffer: page C-3.

Ÿ Positions 9 through 16, password RETURN_CODE


Information is returned as follows:
Ÿ Positions 17 through 24, user ID
Ÿ Messages
Note: For additional information on how to specify
security refer to “APPC Security Considerations” Ÿ Return codes in the communications device
on page 3-12. dependent area of the I/O feedback area

PIP
DEALLOCATE: An AS/400 program starts deallocation by
For DDS, the parameter data can be specified on the
issuing an output operation with detach function. If the
EVOKE keyword.
program is a source program, then an end-of-session func-
For system-supplied formats, the parameter data is tion, release, or close operation must follow the detach func-
specified in positions 57-xxxx of the source program's tion to complete the deallocation. If the program is a source
data buffer. program and the conversation has a synchronization level of
*COMMIT, a commit operation must follow the detach func-
RESOURCE
tion and precede the end-of-session function, release opera-
Refer to “Specifying the Resource Parameter” on
tion, or close operation.
page C-3.

RETURN_CODE If an AS/400 program receives a return code indicating a


Information is returned as follows: detach function was received, then an end-of-session func-
tion or close operation may be used to complete the deallo-
Ÿ Messages cation. The release operation will deallocate the session, only
Ÿ Return codes in the communications device if the AS/400 program is a source program.
dependent area of the I/O feedback area

C-10 OS/400 APPC Programming V4R1


RESOURCE TYPE(ABEND_PROG)
Refer to “Specifying the Resource Parameter” on An end-of-session function, a close operation (for source
page C-3. program), or the application ended without sending or
receiving a detach indication.
TYPE(LOCAL)
Implicit by issuing an end-of-session function, release, or Ÿ For DDS, use the EOS keyword.
close operation after a detach indication has been Ÿ For system-supplied formats, use $$EOS.
received.
RETURN_CODE
Ÿ For DDS, use the EOS keyword Information is returned as follows:
Ÿ For system-supplied formats, use $$EOS
Ÿ Messages
TYPE(SYNC_LEVEL) Ÿ Return codes in the communications device
Use if conversation was allocated with SYNLVL dependent area of I/O feedback area
(*COMMIT). It can also be used in place of
TYPE(CONFIRM) for SYNLVL (*CONFIRM) conversa-
tions or in place of TYPE(FLUSH) for SYNLVL (*NONE) FLUSH: The FLUSH verb causes all buffered data and
conversations. control information to be sent. FLUSH is requested by using
the FRCDTA DDS keyword. This function is not available
Ÿ For data description specifications (DDS), use the when using system-supplied formats.
TNSSYNLVL keyword.
RESOURCE
Ÿ Not supported for system-supplied formats. Refer to the “Specifying the Resource Parameter” on
TYPE(CONFIRM) page C-3.
Use if conversation was allocated with SYNLVL RETURN_CODE
(*CONFIRM). Information is returned as follows:
Ÿ For data description specifications (DDS), use the Ÿ Messages
CONFIRM keyword.
Ÿ Return codes in the communications device
Ÿ Not supported for system-supplied formats. dependent area of I/O feedback area
TYPE(FLUSH)
This is done implicitly for ICF. Use if conversation was GET_ATTRIBUTES: The GET_ATTRIBUTES verb
allocated with SYNLVL (*NONE). requests information about the conversation that is attached
to the program. This verb is supported by the get-attributes
Ÿ For DDS, use the DETACH keyword.
ICF operation. The values are returned to your record buffer;
Ÿ For system-supplied formats, use $SENDET. the length of the record buffer must be at least 144 bytes. To
receive the entire record, the length of the record buffer must
be at least 444 bytes. The values are returned in the order
specified in Table C-1.

Table C-1 (Page 1 of 3). Attribute Information Fields


Position Value Meaning
1 through 10 Name Program device name: The name the program used to identify the program device in the file it will
read and write from.
11 through 20 Name Device description name: The device description associated with the program device name (speci-
fied during configuration and optionally on the ADDICFDEVE or OVRICFDEVE command).
21 through 30 Name User ID: If the program was started locally, this is the user ID used to sign on the work station. If
the program was started as a result of a program start request, this is the user ID used to start the
target program.
31 IDU The device is an ICF device type. The device is a display device. Unknown.
32 through 37 APPC APPC communications type.
38 YN This is a requesting program device. This is a session acquired by a source program.
39 YN Program device has been acquired. Program device has not been acquired.
40 YN Input is invited for this program device. Input is not invited for this program device.
41 YN Invited input is available for this program device. Invited input is not available for this program
device.
42 through 50 Reserved Not applicable to communications.

Appendix C. Implementation of the LU Type 6.2 Architecture C-11


Table C-1 (Page 2 of 3). Attribute Information Fields
Position Value Meaning
51 YN Session has an active transaction. Session does not have an active transaction.
521 012 Synchronization level is NONE. Synchronization level is CONFIRM. Synchronization level is
COMMIT.
53 MB Mapped conversation. Basic conversation.
54 through 61 Name Remote location name: This is the remote location associated with the program device name (spec-
ified during configuration and on the ADDICFDEVE or OVRICFDEVE command).
62 through 69 Name Local logical unit (LU) name.
70 through 77 Name Local network ID.
78 through 852 Name Remote LU name.
86 through 932 Name Remote network ID.
94 through 1013 Name Mode: This is the mode associated with the program device name (specified during configuration
and optionally on the ADDICFDEVE or OVRICFDEVE command).
102 through 104 Reserved Not applicable to communications.
105 APPC conversation state.
X'00' Reset. No conversation exists.
X'01' Send. Program can send data.
X'02' Defer receive. Program enters receive state after a confirm, flush, or commit operation completes
successfully.
X'03' Defer deallocate. Program enters deallocate state after a commit operation completes successfully.
X'04' Receive. Program can receive data.
X'05' Confirm. Program received a confirmation request.
X'06' Confirm send. Program received a confirmation request and send control.
X'07' Confirm deallocate. Program received a confirmation request and deallocate notification.
X'08' Commit. Program received a commit request.
X'09' Commit send. Program received a commit request and send control.
X'0A' Commit deallocate. Program received a commit request and deallocate notification.
X'0B' Deallocate. Program received a deallocate notification.
X'0C' Rollback required. Program must roll back changes to protected resources.
106 through 113 Name Conversation correlator. The conversation correlator associates the conversation states with the
logical unit of work and is used during resynchronization.
114 through 144 Reserved
145 through 146 Binary ISDN remote number length in bytes, including type and plan.
147 through 148 00 ISDN unknown remote number type.
01 ISDN international remote number type.
02 ISDN national remote number type.
03 ISDN network specific remote number type.
04 ISDN subscriber remote number type.
06 ISDN abbreviated remote number type.
149 through 150 00 ISDN unknown remote number plan.
01 ISDN/telephony remote number plan.
03 ISDN data remote number plan.
04 ISDN Telex** remote number plan.
08 ISDN national standard remote number plan.
09 ISDN private remote number plan.
151 through 154 Reserved
155 through 190 Character ISDN remote number (blank padded EBCDIC).
191 through 194 Reserved

C-12 OS/400 APPC Programming V4R1


Table C-1 (Page 3 of 3). Attribute Information Fields
Position Value Meaning
195 through 196 Binary ISDN remote subaddress length in bytes, including type.
197 through 198 00 ISDN NSAP remote subaddress type.
02 ISDN user defined remote subaddress type.
199 through 238 Character ISDN remote subaddress (0 padded hexadecimal).
239 Reserved
240 0 Incoming ISDN call.
1 Outgoing ISDN call.
2 Non-ISDN connection.
241 through 242 Binary X.25 remote network address length.
243 through 274 Character X.25 remote network address.
275 through 278 Reserved
279 through 280 Binary X.25 remote address extension length.
281 0 Address assigned according to ISO 8348/AD2.
2 Not an ISO 8348/AD2 type of address.
282 through 321 Character Remote address extension.
322 through 325 Reserved
326 0 Incoming X.25 switched virtual circuit (SVC).
1 Outgoing X.25 SVC.
2 Not X.25 SVC.
327 through 390 Character Evoked transaction program name.
391 Binary Length of the protected logical unit of work identifier (LUWID). Must be from 0 to 26.
392 Binary Length of the qualified LU name. Must be from 0 to 17.
393 through 409 Character Network-qualified protected LU name in the following form: netid.luname. netid is the network identi-
fier. luname is the logical unit name. This field may be blank.
410 through 415 Character Protected LUWID instance number.
416 through 417 Binary Protected LUWID sequence number.
Note: The protected LUWID identifies the current logical unit of work for a protected conversation.
418 Binary Length of the unprotected LUWID. Must be from 0 to 26.
419 Binary Length of the qualified LU name. Must be from 0 to 17.
420 through 436 Character Network-qualified unprotected LU name in the following form: netid.luname. netid is the network
identifier. luname is the logical unit name. This field may be blank.
437 through 442 Character Unprotected LUWID instance number.
443 through 444 Binary Unprotected LUWID sequence number.
Note: The unprotected LUWID identifies the current logical unit of work for conversations with a
synchronization level of none or confirm.
Note:
1 This is the SYNC_LEVEL.
2 Remote LU name is the PARTNER_LU_NAME. Remote network ID, when concatenated by a period (.) with the remote LU
name, is the PARTNER_FULLY_QUALIFIED_LU_NAME.
3 This is the MODE_NAME.

RETURN_CODE Ÿ Return codes in the communications device


Information is returned as follows: dependent area of I/O feedback area

Ÿ Messages RESOURCE
Refer to “Specifying the Resource Parameter” on
page C-3.

Appendix C. Implementation of the LU Type 6.2 Architecture C-13


POST_ON_RECEIPT: The POST_ON_RECEIPT verb Ÿ For data description specifications (DDS), use the
causes the LU to post the specified conversation when infor- TNSSYNLVL keyword. The TNSSYNLVL keyword is
mation is available for the program to receive. The informa- not allowed with an invite function if the conversa-
tion can be data, conversation status, or a request for tion was allocated with SYNLVL(*COMMIT).
confirmation. WAIT should be issued after Ÿ Not supported for system-supplied formats.
POST_ON_RECEIPT in order to wait for posting to occur.
For SYNLVL(*COMMIT), the conversation enters defer
APPC uses the invite function to perform this verb. receive state. Defer receive state indicates that this
Note: There is no length parameter on the ICF invite func- program wants to be in receive state after a commit
tion. The AS/400 system does not use a length value operation completes successfully. The only valid oper-
to determine when to perform posting. The AS/400 ations for the conversation in defer receive state are:
system will only perform posting when a complete LL commit, rollback, PRPCMT, and EOS.
is received or when information other than data is TYPE(CONFIRM)
received. Use if conversation was allocated with SYNLVL
RESOURCE (*CONFIRM).
Refer to “Specifying the Resource Parameter” on Ÿ For DDS, use the CONFIRM keyword.
page C-3.
Ÿ Not supported for system-supplied formats.
FILL(LL)
This is the only supported value. TYPE(FLUSH)
Use if conversation was allocated with SYNLVL
PREPARE_FOR_SYNCPT: The (*NONE).
PREPARE_FOR_SYNCPT verb causes a single protected LOCKS(SHORT)
resource to be prepared to advance to the next synchroniza- Implicit when CONFIRM is specified.
tion point. Using this verb allows a program to have its own
logic to respond if its partner cannot complete the commit RETURN_CODE
process. Information is returned as follows:

RESOURCE Ÿ Messages
Refer to “Specifying the Resource Parameter” on Ÿ Return codes in the communications device
page C-3. dependent area of the I/O feedback area
RETURN_CODE
Information is returned as follows: RECEIVE_AND_WAIT: The RECEIVE_AND_WAIT verb
waits for information to arrive on the specified conversation
Ÿ Messages
and then receives the information. If information is already
Ÿ Return codes in the communications device available, the program receives it without waiting. The infor-
dependent area of I/O feedback area mation can be data, conversation status, or a request for
confirmation. To perform a RECEIVE_AND_WAIT the
PREPARE_TO_RECEIVE: The AS/400 program issues a READ operation to a specific
PREPARE_TO_RECEIVE verb changes the conversation program device name.
from send state to receive state so that the program can RESOURCE
receive data. This verb is performed in combination with a Refer to “Specifying the Resource Parameter” on
SEND_DATA operation when an allow write or invite function page C-3.
is specified on a DDS output format, or for a system-supplied
format that also specifies an invite (for example, $$SEND). FILL(LL)
Note that the invite function also performs the VARBUFMGT DDS keyword not specified. Implicit when
POST_ON_RECEIPT verb. using system-supplied formats.

RESOURCE FILL(BUFFER)
Refer to “Specifying the Resource Parameter” on VARBUFMGT DDS keyword specified. Not supported
page C-3. when using system-supplied formats.

TYPE(SYNC_LEVEL) LENGTH
Use if conversation was allocated with Requested length is the length of the record format area.
SYNLVL(*COMMIT). It can also be used in place of Returned length is located in the first 2 bytes of the input
TYPE(CONFIRM) for SYNLVL(*CONFIRM) conversa- buffer and in the communications device dependent area
tions or in place of TYPE(FLUSH) for SYNLVL(*NONE) of the I/O feedback area.
conversations.

C-14 OS/400 APPC Programming V4R1


RETURN_CODE 0300 SEND
Information is returned as follows:
0301 DATA1, DATA_COMPLETE2
Ÿ Messages 0314 CONFIRM_SEND
Ÿ Return codes in the communications device 0315 CONFIRM
dependent area of the I/O feedback area
031C CONFIRM_DEALLOCATE
REQUEST_TO_SEND_RECEIVED
0357 TAKE_COMMIT
Information is returned by the request-to-write indicator
in the communication device dependent area of the I/O 0358 TAKE_COMMIT_SEND
feedback area. 0359 TAKE_COMMIT_DEALLOCATE
DATA 3431 LL_TRUNCATED2
Application program's data buffer.
3471 DATA_INCOMPLETE
WHAT_RECEIVED 1 DATA is returned only when FILL(BUFFER) is
Response indicators and major and minor return codes used with VARBUFMGT.
in communication device dependent area of I/O feed-
2 DATA_COMPLETE and LL_TRUNCATED are
back area. For more information on this parameter, refer
returned only when FILL(LL) is used.
to “MC_RECEIVE_AND_..WAIT” on page C-6.
3 The LU 6.2 architected return code DEALLO-
The following lists contrast WHAT_RECEIVED with the major
CATE is returned by this ICF return code.
and minor return codes and the response indicators. Note
that some major and minor return codes provide more infor- WHAT_RECEIVED Values Mapped to ICF Return Codes:
mation than WHAT_RECEIVED. For example, return code The following list shows the WHAT_RECEIVED values for
0008 is equivalent to DATA_COMPLETE and a the RECEIVE_AND_WAIT verb with the corresponding ICF
RETURN_CODE of DEALLOCATE _NORMAL. return codes.
DATA_INCOMPLETE is supported when *RETAIN is speci-
WHAT_RECEIVED Value ICF Return Codes
fied for the OVRFLWDTA parameter.
DATA1 0000, 0001, 00083, 0010, 0014, 0015, 001C3,
ICF Return Codes Mapped to WHAT_RECEIVED Values: 0200, 0201, 02083, 0214, 0215, 021C3, 0301
The following list shows ICF return codes with the corre-
DATA_COMPLETE2 0000, 0001, 00083, 0010, 0014, 0015,
sponding WHAT_RECEIVED values for the
001C3, 0200, 0201, 02083, 0214, 0215, 021C3,
RECEIVE_AND_WAIT verb.
0301
ICF Return Code WHAT_RECEIVED Values
DATA_INCOMPLETE 3471
0000 DATA1, DATA_COMPLETE2, SEND
LL_TRUNCATED2 3431
0001 DATA1, DATA_COMPLETE2
SEND 0000, 0200, 0300,
00083 DATA1, DATA_COMPLETE2
CONFIRM 0015, 0215, 0315,
0010 DATA1, DATA_COMPLETE2
CONFIRM_SEND 0014, 0214, 0314
0014 DATA1, DATA_COMPLETE2, CONFIRM_SEND
CONFIRM_DEALLOCATE 001C3, 021C3, 031C3,
0015 DATA1, DATA_COMPLETE2, CONFIRM
TAKE_COMMIT 0257, 0357
001C3 DATA1, DATA_COMPLETE2,
TAKE_COMMIT_SEND 0258, 0358
CONFIRM_DEALLOCATE
TAKE_COMMIT_DEALLOCATE 0259, 0359
0200 DATA1, DATA_COMPLETE2, SEND
1 DATA is returned only when FILL(BUFFER) is
0201 DATA1, DATA_COMPLETE2
used with VARBUFMGT.
02083 DATA1, DATA_COMPLETE2
2 DATA_COMPLETE and LL_TRUNCATED are
0214 DATA1, DATA_COMPLETE2, CONFIRM_SEND returned only when FILL(LL) is used.
0215 DATA1, DATA_COMPLETE2, CONFIRM 3 The LU 6.2 architected return code DEALLO-
021C3 DATA1, DATA_COMPLETE2, CATE is returned by this ICF return code.
CONFIRM_DEALLOCATE
Response Indicators Mapped to WHAT_RECEIVED
0257 TAKE_COMMIT Values: The following list shows the DDS response indica-
0258 TAKE_COMMIT_SEND tors with the corresponding WHAT_RECEIVED values for the
RECEIVE_AND_WAIT verb.
0259 TAKE_COMMIT_DEALLOCATE

Appendix C. Implementation of the LU Type 6.2 Architecture C-15


Response Indicators WHAT_RECEIVED Values LENGTH
For DDS with the VARBUFMGT keyword specified,
RCVCONFIRM CONFIRM, CONFIRM_SEND,
implicit by the record format or specified explicitly by the
CONFIRM_DEALLOCATE
VARLEN keyword.
RCVTRNRND SEND, CONFIRM_SEND,
For DDS without the VARBUFMGT keyword specified,
TAKE_COMMIT_SEND
the first 2 bytes in the output buffer of the application
RCVDETACH CONFIRM_DEALLOCATE, program contain the length of data to send.
TAKE_COMMIT_DEALLOCATE
For system-supplied formats, the first 4 bytes in the
RCVTKCMT TAKE_COMMIT, TAKE_COMMIT_SEND, output buffer of the application program contain the
TAKE_COMMIT_DEALLOCATE length of data to send.

RECEIVE_IMMEDIATE: Receives any information that is RETURN_CODE


available from the specified conversation, but does not wait Information is returned as follows:
for information to arrive. The information can be data, con-
Ÿ Messages
versation status, or a request for confirmation. Control is
returned to the program with an indication of whether any Ÿ Return codes in the communications device
information was received and, if so, the type of information. dependent area of the I/O feedback area

There are no ICF operations or functions that map to this REQUEST_TO_SEND_RECEIVED


verb. Communications device dependent area of the I/O feed-
back area as follows:
REQUEST_TO_SEND: The REQUEST_TO_SEND verb Ÿ Request-to-write indicator
tells the remote program that the local program requests to
enter send state for the conversation. The conversation is Ÿ Minor return code of 10 for major return code of 00
changed to send state when the local program receives a
SEND indication from the remote program. SEND_ERROR: The SEND_ERROR verb informs the
remote transaction program that the local program detected
The REQUEST_TO_SEND verb is specified with a request- an error. Use the FAIL DDS keyword or the $$FAIL system-
to-write function. The REQUEST WRITE is specified on a supplied format to provide this function.
DDS specification using the RQSWRT keyword and in
system-supplied formats with a $$RCD. The DDS format If the conversation has a synchronization level of commit, the
may also include the INVITE keyword. The system-supplied fail function may cause the system to roll back the protected
format has an implicit invite specified. Note that the invite LUW. If the fail function is in response to a commit operation,
function also performs the POST_ON_RECEIPT verb. the system rolls back the protected LUW. If the fail function
is in response to a prepare-for-commit function, the system
RESOURCE
does not roll back the protected LUW.
Refer to “Specifying the Resource Parameter” on
page C-3. RESOURCE
Refer to the “Specifying the Resource Parameter” on
RETURN_CODE
page C-3.
Information is returned as follows:
TYPE(PROG)
Ÿ Messages
Implicit. This is the only supported value.
Ÿ Return codes in the communications device
dependent area of the I/O feedback area RETURN_CODE
Information is returned as follows:

SEND_DATA: The SEND_DATA verb sends data or Ÿ Messages


control information to the remote program. Done with a write Ÿ Return codes in the communications device
operation of a format with a data length greater than zero. dependent area of the I/O feedback area
RESOURCE REQUEST_TO_SEND_RECEIVED
Refer to “Specifying the Resource Parameter” on Communications device dependent area of the I/O feed-
page C-3. back area as follows:
DATA Ÿ Request-to-write indicator
Application program's data buffer.
Ÿ Minor return code of 10 with major return code of 00

C-16 OS/400 APPC Programming V4R1

You might also like