Okay thankx I'll run under TSO TEST AND CHECK the exception bit pattern I assume for the original socket number ...
Thsnkx again -----Original Message----- From: IBM Mainframe Discussion List [mailto:ibm-m...@bama.ua.edu] On Behalf Of Rob Scott Sent: Sunday, October 25, 2009 1:07 PM To: IBM-MAIN@bama.ua.edu Subject: Re: Return Code from EZASMI macro Select Service There is a good section in the IP Sockets Application Programming Guide on the design of a concurrent server program including a high-level flow diagram. (1) Your listener should close the original socket when the SELECT returns with an exception ("TPIMASK TEST" for ERROR_STATUS is valid for the socket number). Normally this involves looping thru all sockets from 0 to your MAXSOC value. (2) When your handler subtask is done with the current conversation it should issue the CLOSE of the socket that it received. Depending on the design of your handler code - this might be immediate (ie some sort of ask+answer thing) or it might stay around for while and then only close after a client-initiated "close" call or some time-out. Rob Scott Developer Rocket Software 275 Grove Street * Newton, MA 02466-2272 * USA Tel: +1.617.614.2305 Email: rsc...@rs.com Web: www.rocketsoftware.com -----Original Message----- From: IBM Mainframe Discussion List [mailto:ibm-m...@bama.ua.edu] On Behalf Of Joe Reichman Sent: 25 October 2009 16:01 To: IBM-MAIN@bama.ua.edu Subject: Re: Return Code from EZASMI macro Select Service I am the only one on the machine when I was testing this out I'll double check all rc Just a couple of more questions I issue the close on the original socket Not the one generated by the GIVESOCKET right?? And when do I CLOSE the original after I am notified by the subtask that it has done a TAKESOCKET Or when the Select Service issues an exception..... thankx -----Original Message----- From: IBM Mainframe Discussion List [mailto:ibm-m...@bama.ua.edu] On Behalf Of Rob Scott Sent: Sunday, October 25, 2009 11:27 AM To: IBM-MAIN@bama.ua.edu Subject: Re: Return Code from EZASMI macro Select Service Is it possible that another task/ASID is attempting to connect on the same port? What happens when your listener task performs the second givesocket? I have always found it useful when debugging EZASMI applications to have a debug option in the program so that the service name, rc and errno can be WTO'ed out for all callers (even when completely successful). Rob Scott Developer Rocket Software 275 Grove Street * Newton, MA 02466-2272 * USA Tel: +1.617.614.2305 Email: rsc...@rs.com Web: www.rocketsoftware.com -----Original Message----- From: IBM Mainframe Discussion List [mailto:ibm-m...@bama.ua.edu] On Behalf Of Joe Reichman Sent: 25 October 2009 12:23 To: IBM-MAIN@bama.ua.edu Subject: Re: Return Code from EZASMI macro Select Service Yes there is ..... Its waiting for a read However I gave a did a GiveSocket and the Subtask did a TakeSocket caused which caused an exception... Then I closed the Orignal Socket used for the Select Service That should Finish off processing in the Main program I tested this out under TSO TEST got return code 0 from the CLOSE service.... -----Original Message----- From: IBM Mainframe Discussion List [mailto:ibm-m...@bama.ua.edu] On Behalf Of Rob Scott Sent: Sunday, October 25, 2009 7:54 AM To: IBM-MAIN@bama.ua.edu Subject: Re: Return Code from EZASMI macro Select Service If SELECT is giving you a positive return code then there is some sort of pending action required on the socket. Have you determined what sort of action it is ? (READ, WRITE or EXCEPTION) ? Rob Scott Developer Rocket Software 275 Grove Street * Newton, MA 02466-2272 * USA Tel: +1.617.614.2305 Email: rsc...@rs.com Web: www.rocketsoftware.com -----Original Message----- From: IBM Mainframe Discussion List [mailto:ibm-m...@bama.ua.edu] On Behalf Of Joe Reichman Sent: 25 October 2009 05:57 To: IBM-MAIN@bama.ua.edu Subject: Return Code from EZASMI macro Select Service Hi, The way I read the EZASMI Select Service macro description in the communication server guide and reference if the return code is > 0 then there are active connections If I receive a connection post a subtask issue GIVESOCKET and have been notified by the Subtask that it has has done a Takesocket I can now close this new socket (returned to me by the accept macro) and when I issue my select again the return code should be 0 Even though the socket is active for the subtask I seem to be always getting a return of 1 After the first connection... Thankx ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html