/******************************************************************************/

/* Version: MM1
*/
/******************************************************************************/
/*
*/
/* Program:
STRPROD
*/
/* Description: Source for user written program to start the production
*/
/*
environment after switching the data groups and prior to
*/
/*
starting them.
*/
/*
*/
/*----------------------------------------------------------------------------*/
/*
*/
/* (C) Copyright 2009 Vision Solutions
*/
/*
*/
/* Disclaimer: This material contains program source code for your use as a */
/* template for creating exit programs for use with MIMIX Switch Framework. */
/* These programs HAVE NOT BEEN THOROUGHLY TESTED UNDER ALL CONDITIONS.
*/
/* The source code in these programs is part of the MIMIX Monitor software */
/* product and is covered by the warranty and support provisions contained */
/* in the license agreements covering the MIMIX Monitor product. HOWEVER, */
/* any additional source code added to this template is EXCLUDED from the */
/* warranty and support provisions.
*/
/*
*/
/* Lakeview Technology, Inc., therefore cannot guarantee or imply
*/
/* reliability, serviceability, performance or function of these programs */
/* once they have been changed. All programs contained herein are provided */
/* to you "AS IS". THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
*/
/* FOR A PARTICULAR PURPOSE ARE EXPRESSLY DISCLAIMED.
*/
/*
*/
/*----------------------------------------------------------------------------*/
/*
*/
/* Assumptions:
*/
/*
*/
/*
o This program is a sample template for a CL program that will
*/
/*
start the production environment after switching the data
*/
/*
groups and prior to starting them.
*/
/*
o This program will be compiled with the CRTCLPGM command and
*/
/*
placed into any user library on both the production and backup
*/
/*
systems.
*/
/*
o The parameter list MUST NOT be changed. These variables can be
*/
/*
renamed inside this program but the order and type of the
*/
/*
parameters is required to stay the same.
*/
/*
o The result of this program is to be stored in the local data
*/
/*
area (*LDA) in positions 1-10 with values of either 'SUCCESSFUL' */
/*
or 'FAILED'. If you use values other than these, the switch
*/
/*
framework will interpret it as a failure of the program and end */
/*
the processing with an error message.
*/
/*
o It is recommended that this source code be copied from the
*/
/*
MMTEMPLSRC file into another source file so if there is a new
*/
/*
version of this program shipped in the future the changes to
*/
/*
this program will not be lost.
*/
/*
*/
/*----------------------------------------------------------------------------*/
/******************************************************************************/
/*
*/
/* NOTE: Whenever you see a section of comments marked by exclamation
*/
/*
points (!!!!), this is where you should add your customized code
*/
/*
that will control the starting of the production environment.
*/
/*
*/
/******************************************************************************/

this program will always return a 'SUCCESSFUL' value in the */ /* *LDA so the switch framework will continue processing. */ /******************************************************************************/ DCL VAR(&BKUPSYS) TYPE(*CHAR) LEN(8) VALUE(MXMGT) DCL VAR(&PRODSYS) TYPE(*CHAR) LEN(8) VALUE(MXNET) DCL VAR(&LISTID) TYPE(*DEC) LEN(3 0) DCL VAR(&MSFLIB) TYPE(*CHAR) LEN(10) VALUE(JFLMSF) DCL VAR(&RMTSYS) TYPE(*CHAR) LEN(8) DCL VAR(&SAVF) TYPE(*CHAR) LEN(10) /*********************************************************************/ /* START OF MAINLINE CODE */ /*********************************************************************/ /*!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!*/ /* */ /* This is where the user should include code that will start their */ /* production environment on the system.Update variable &MSFLIB with the library where the Switch Framework */ /* exit programs exist. local and remote system names IF COND(&SYSDFN *EQ &PRODSYS) THEN(DO) CHGVAR VAR(&RMTSYS) VALUE(&BKUPSYS) ENDDO ELSE CMD(DO) CHGVAR VAR(&RMTSYS) VALUE(&PRODSYS) ENDDO */ /* Enable STRTCPIFC MONMSG CHGTCPIFC */ and start the source system IP interface(s) INTNETADR(&INTNETADR) MSGID(TCP1B12) INTNETADR(&INTNETADR) AUTOSTART(*YES) /* Start QSPL subsystem and writers STRSBS SBSD(QSPL) MONMSG MSGID(CPF1010) */ . varying on lines/controllers/devices. backup. This could include things such as */ /* starting selected subsystems. */ /* */ /*!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!*/ /* The following line is an example of how to set the result to 'FAILED' */ /* CHGDTAARA DTAARA(*LDA (1 10)) VALUE('FAILED') */ /* Retrieve the production. */ /* */ /* By default.16. etc.4') /******************************************************************************/ /* MXTOOLJSE V1.0 */ /* */ /* Variables for managing the IBM job scheduler entries */ /* .4.PGM PARM(&PRDLIB &SYSDFN &SWTFWK &SWTTYPE) DCL VAR(&PRDLIB) TYPE(*CHAR) LEN(10) /* DCL VAR(&SYSDFN) TYPE(*CHAR) LEN(8) /* /* DCL VAR(&SWTFWK) TYPE(*CHAR) LEN(10) /* /* DCL VAR(&SWTTYPE) TYPE(*CHAR) LEN(1) /* /* /* MIMIX product library name System definition where program is being run Switch framework this program is being called for Switch type being performed U = *UNPLANNED switch P = *PLANNED switch */ */ */ */ */ */ */ */ DCL VAR(&INTNETADR) TYPE(*CHAR) LEN(15) VALUE('172.

This may include subsystems. interactive and communication subsystems STRSBS SBSD(QBATCH) MONMSG MSGID(CPF0000) STRSBS SBSD(QINTER) MONMSG MSGID(CPF0000) STRSBS SBSD(QCMN) MONMSG MSGID(CPF0000) */ /* Bring up SNA communications STRSBS SBSD(QSNADS) MONMSG MSGID(CPF1010) VRYCFG CFGOBJ(*APPN) CFGTYPE(*CTL) STATUS(*ON) */ /*===========================================================================*/ /* RESTORE IBM JOB SCHEDULE ENTRIES */ /*---------------------------------------------------------------------------*/ IF COND(&SYSDFN *EQ &BKUPSYS) THEN(DO) CHGVAR VAR(&SAVF) VALUE(JSESRCP1) ENDDO IF COND(&SYSDFN *EQ &PRODSYS) THEN(DO) CHGVAR VAR(&SAVF) VALUE(JSESRCP3) ENDDO IF COND(&SWTTYPE *EQ 'U') THEN(DO) CHGVAR VAR(&SAVF) VALUE(JSESRCU1) ENDDO RSTOBJ OBJ(*ALL) SAVLIB(QUSRSYS) DEV(*SAVF) + OBJTYPE(*JOBSCD) SAVF(&MSFLIB/&SAVF) /*===========================================================================*/ /* START MASTER MONITOR */ /*---------------------------------------------------------------------------*/ STRMSTMON MONMSG MSGID(LVE4021) /* CHANGE THE SYSTEM ROLE TO SOURCE CHGDTAARA DTAARA(&MSFLIB/MXSYSROLE) VALUE(SRC) */ /* SET STATUS RESULTS CHGDTAARA DTAARA(*LDA (1 10)) VALUE('SUCCESSFUL') */ ENDPGM: ENDPGM =================*/ /* START MASTE . STRSBS SBSD(JFLMSF/JFLAPP) MONMSG MSGID(CPF0000) */ /* Start the batch.STRPRTWTR DEV(*ALL) STRRMTWTR OUTQ(*ALL) /* Start Production applications.

Sign up to vote on this title
UsefulNot useful