Re: Batch connection to CSKL (was: Trigger CICS transaction from Batch Job)

2009-08-14 Thread Gil, Victor x28091
Thanks, Jantje.

I vaguely remember coding a simple child server circa 1997 and having an
issue with the need to start it on a "terminal" to enable password
maintenance via EXEC CICS SIGNON.

But I've never touched the "batch" part. Will take a look.

Thanks again,
-Victor- 

===
Date:Thu, 13 Aug 2009 07:16:24 -0500
From:Jan MOEYERSONS 
Subject: Re: Batch connection to CSKL (was: Trigger CICS transaction
from Batch Job)



You can find the fine manual that describes the CICS side of such at
z/OS 
Communications Server IP CICS Sockets Guide ( 
http://www.elink.ibmlink.ibm.com/publications/servlet/pbi.wss?
CTY=US&FNC=SRX&PBL=SC31-8807-05 ). The batch side of things is described

in z/OS Communications Server IP Sockets Application Programming
Interface 
Guide and Reference ( 
http://www.elink.ibmlink.ibm.com/publications/servlet/pbi.wss?
CTY=US&FNC=SRX&PBL=SC31-8788-07 ).

I did code a child server, but I am afraid I cannot give you that code,
because 
it was developed for a specific customer who paid for it and who
actually owns 
that code. But the documentation is fairly good and there are samples.

The code for the client was for Windows.

The point, however, is that CICS comes with infrastructure (the CSKL 
transaction) that makes managing a listener in CICS quite simple and
effective. 

All you need to do is to code the child server transaction in your
programming 
language of choice. The book gives you guidelines on how to structure
the 
program for this transaction. And you do not have to worry about how to 
listen for an incoming connection (because that is the difficult part
that CICS 
has already done for you...). Your transaction is started by CSKL and
receives 
the socket number that represents the connection. All you need to do is
to 
TAKESOCKET and start receiving (and sending) data over it.

For the batch program, you just do simple sockets programming, again in
the 
programming language of your choice. 

The connection is set up by opening a socket to the port where the CSKL
is 
listening, send the trancode plus some security-related information (if
you 
need it). CICS is listening for incoming connections, spawns the
transaction, 
corresponding to the trancode you ask for and GIVESOCKET the socket to
it.

Then your batch program and your CICS transaction engage in a TCP 
conversation and can pass data back and forth among them without 
restriction.

Do read the book; it is all in there.

If you need more information, please ask me specific, detailed questions
off-
list.

Cheers,

Jantje.
This message and any attachments are intended only for the use of the addressee 
and
may contain information that is privileged and confidential. If the reader of 
the 
message is not the intended recipient or an authorized representative of the
intended recipient, you are hereby notified that any dissemination of this
communication is strictly prohibited. If you have received this communication in
error, please notify us immediately by e-mail and delete the message and any
attachments from your system.


--
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


Re: Batch connection to CSKL (was: Trigger CICS transaction from Batch Job)

2009-08-13 Thread Jan MOEYERSONS
On Wed, 12 Aug 2009 16:52:42 -0400, Gil, Victor x28091 
 wrote:

>Jantje,
>
>I am intrigued. Can you elaborate a bit on this idea?
>[Doc pointers, code samples, etc.]

You can find the fine manual that describes the CICS side of such at z/OS 
Communications Server IP CICS Sockets Guide ( 
http://www.elink.ibmlink.ibm.com/publications/servlet/pbi.wss?
CTY=US&FNC=SRX&PBL=SC31-8807-05 ). The batch side of things is described 
in z/OS Communications Server IP Sockets Application Programming Interface 
Guide and Reference ( 
http://www.elink.ibmlink.ibm.com/publications/servlet/pbi.wss?
CTY=US&FNC=SRX&PBL=SC31-8788-07 ).

I did code a child server, but I am afraid I cannot give you that code, because 
it was developed for a specific customer who paid for it and who actually owns 
that code. But the documentation is fairly good and there are samples.

The code for the client was for Windows.

The point, however, is that CICS comes with infrastructure (the CSKL 
transaction) that makes managing a listener in CICS quite simple and effective. 

All you need to do is to code the child server transaction in your programming 
language of choice. The book gives you guidelines on how to structure the 
program for this transaction. And you do not have to worry about how to 
listen for an incoming connection (because that is the difficult part that CICS 
has already done for you...). Your transaction is started by CSKL and receives 
the socket number that represents the connection. All you need to do is to 
TAKESOCKET and start receiving (and sending) data over it.

For the batch program, you just do simple sockets programming, again in the 
programming language of your choice. 

The connection is set up by opening a socket to the port where the CSKL is 
listening, send the trancode plus some security-related information (if you 
need it). CICS is listening for incoming connections, spawns the transaction, 
corresponding to the trancode you ask for and GIVESOCKET the socket to it.

Then your batch program and your CICS transaction engage in a TCP 
conversation and can pass data back and forth among them without 
restriction.

Do read the book; it is all in there.

If you need more information, please ask me specific, detailed questions off-
list.

Cheers,

Jantje.

--
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


Batch connection to CSKL (was: Trigger CICS transaction from Batch Job)

2009-08-12 Thread Gil, Victor x28091
Jantje,

I am intrigued. Can you elaborate a bit on this idea?
[Doc pointers, code samples, etc.]

TIA,
-Victor- 

==
Date:Mon, 10 Aug 2009 05:40:50 -0500
From:Jan MOEYERSONS 
Subject: Re: Trigger CICS transaction from Batch Job



But instead of connecting to a 3270 terminal, the connection should be
made 
to the CICS listener CSKL. Works like a charm. With security if you need
it and 
no sweat exchanging information back and forth between the batch program

and the CICS transaction.

Cheers,
Jantje.
This message and any attachments are intended only for the use of the addressee 
and
may contain information that is privileged and confidential. If the reader of 
the 
message is not the intended recipient or an authorized representative of the
intended recipient, you are hereby notified that any dissemination of this
communication is strictly prohibited. If you have received this communication in
error, please notify us immediately by e-mail and delete the message and any
attachments from your system.


--
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