WTO from JAVA

General discussion on the JZOS batch launcher and toolkit
Post Reply
hagai2003
Posts: 3
Joined: Thu May 18, 2006 1:54 am

WTO from JAVA

Post by hagai2003 »

Hi,
I'm interested in writing WTO messages from a JAVA program.
I know JZOS has this option but I'm not allowed to use it in our facilities so I've written a JNI program in C that uses the function _console() to write WTO messages.
When I run a C program that calls this procedure on a batch JOB I see the message I write to the _console() on the JESMSGLG DD card of the job and on the SYSLOG.

When I run a java program on batch that calls the same C procedure using JNI the message is NOT written to the JESMSGLG but only to the SYSLOG.

I'm interested in writing the messages to the JESMSGLG, I wanted to know if anyone encountered this problem or if anyone has any other method to write WTO messages from Java.

I think the solution might be using _console2() but i'm not sure...

thanks,
Hagai.
    dovetail
    Site Admin
    Posts: 2022
    Joined: Thu Jul 29, 2004 12:12 pm

    Post by dovetail »

    The alphaworks version of JZOS uses assembler code and a call to SVC 35. The next release of JZOS uses _console2(), which works fine from a batch job.
    hagai2003
    Posts: 3
    Joined: Thu May 18, 2006 1:54 am

    source

    Post by hagai2003 »

    Thanks,
    Is there any way to get a source for this code or an example of using console2() ?
    I've written a _console2() program that works when I compile and use it on batch but when i do it on omvs (to create a dll) it doesnt work, there isn't much documentation about it i could find.

    regards,
    Hagai.
    dovetail
    Site Admin
    Posts: 2022
    Joined: Thu Jul 29, 2004 12:12 pm

    Post by dovetail »

    I'm sorry, but I don't have any source code samples that I am able to provide.

    Hopefully, you will be able to use JZOS in the near future. For more information on IBM's announced plans:

    http://www-03.ibm.com/servers/eserver/z ... press.html
    Post Reply