IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Suggestions needed


IBM Mainframe Forums -> JCL & VSAM
Post new topic   This topic is locked: you cannot edit posts or make replies.
View previous topic :: View next topic  
Author Message
Rohit Umarjikar

Global Moderator


Joined: 21 Sep 2010
Posts: 3048
Location: NYC,USA

PostPosted: Tue Mar 05, 2013 1:07 am
Reply with quote

Hi,

Need your suggestion on this one. We have 2 mainframe jobs as below:

Job 1: Creates a file containing email communication to the users. This is one mainframe dataset containing the email matter(From email address, To email address, Subject, Body) for all the users.

Job 2: Takes the above file as input and sends out email communication to each of the users email addresses present in the file using ICEGENER utility.



Issue: During testing in dev/QA, Job 2 would actually send out emails to all the users present in the file. This also happens if somebody accidentally runs Job 2 in dev/QA.

Resolution:

1. We are changing Job 1 to make the email address invalid by replacing @XYZ.COM by invalid characters.

2. Job 2 will now have a program to convert the invalid email address to a valid one only if it is running in production(check the region in the program) and write out the file to SYSOUT=B,SMTP.

3. If Job 2 is running in test/QA, the invalid characters are not converted and file is not written out.



Question:

Is there a better resolution? Testing the above resolution is difficult too.
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8696
Location: Dubuque, Iowa, USA

PostPosted: Tue Mar 05, 2013 1:13 am
Reply with quote

Why not have job 2 execute a program to determine if it is running in test or production and email the development team or the entire list respectively? Converting invalid email addresses to valid email addresses seems to add additonal complexity for no apparent reason.

Or, you could add a program to job 1 to check if it is running in production or test and take appropriate action.
Back to top
View user's profile Send private message
Rohit Umarjikar

Global Moderator


Joined: 21 Sep 2010
Posts: 3048
Location: NYC,USA

PostPosted: Tue Mar 05, 2013 1:25 am
Reply with quote

Right, there is no need of converting email extensions to invalid charachers but by any means can we avoid changing the proc/job?

I just got a clue to have NONE authority to place for that perticular dataset for the number of users. this will avoid changing the proc/job.

Thanks
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8696
Location: Dubuque, Iowa, USA

PostPosted: Tue Mar 05, 2013 1:42 am
Reply with quote

That would depend upon your particular site and its security package. Only someone working at your site could advise you about it; however, if the test region (LPAR?) security data base is ever refreshed from production (or somewhere else) you could lose the protection.
Back to top
View user's profile Send private message
Bill Woodger

Moderator Emeritus


Joined: 09 Mar 2011
Posts: 7309
Location: Inside the Matrix

PostPosted: Tue Mar 05, 2013 2:56 am
Reply with quote

If all your e-mail contact details are in a dataset, you just have a different one in different environments.
Back to top
View user's profile Send private message
Rohit Umarjikar

Global Moderator


Joined: 21 Sep 2010
Posts: 3048
Location: NYC,USA

PostPosted: Tue Mar 05, 2013 3:12 am
Reply with quote

Thank you for the inputs. I will update with what we implemented.
Back to top
View user's profile Send private message
Anuj Dhawan

Superior Member


Joined: 22 Apr 2006
Posts: 6250
Location: Mumbai, India

PostPosted: Tue Mar 05, 2013 5:30 pm
Reply with quote

Rohit Umarjikar wrote:
Issue: During testing in dev/QA, Job 2 would actually send out emails to all the users present in the file. This also happens if somebody accidentally runs Job 2 in dev/QA.
Your question is somewhat site-specific as Robert has also said. On the other hand, how come a file, which is presumably should have a PROD High Level Qualifier (HLQ) for files, is available in test LPAR also? Should not the HLQ of PROD and TEST be different at first place?

As one of the solutions, you can also use symbolic data-set name for the file having e-mail contact details. One of its nodes should be replaced with 'something' which distinguish Test and prod LPARs at your shop that way, a Prod file, will not be referred in Test/QA (which is strange and site-specific, to start with).
Back to top
View user's profile Send private message
Ed Goodman

Active Member


Joined: 08 Jun 2011
Posts: 556
Location: USA

PostPosted: Tue Mar 05, 2013 8:39 pm
Reply with quote

I would caution that invalid email addresses can cause trouble. I put an invalid address on purpose for exactly the same reason, and I managed to hose up the bridge between mainframe and the SMTP server.

The worst part was that it happened at like 6:30 one night, and I KNEW it had happened. I started calling people to let them know I had broken it, but nobody knew who the owners were.

I kept calling the next morning and still had no luck finding the right people. However, there were about fifty open tickets for missing email from production jobs.

Of course, three days later, I get a screaming phone call from the owner trying to get me fired for doing this. Luckily I had written docs from the moment of failure that I had been trying to reach him.
Back to top
View user's profile Send private message
Rohit Umarjikar

Global Moderator


Joined: 21 Sep 2010
Posts: 3048
Location: NYC,USA

PostPosted: Thu Mar 07, 2013 12:43 am
Reply with quote

Anuj : Yes the first HLQ is available in every region/LPAR. on the other note even if we use the symbolic parameter then by chance if someone gives production HLQ then again emails going to send out.

But currently I can refer every prod file in TEST/QA region. icon_sad.gif
Back to top
View user's profile Send private message
Rohit Umarjikar

Global Moderator


Joined: 21 Sep 2010
Posts: 3048
Location: NYC,USA

PostPosted: Thu Mar 07, 2013 12:45 am
Reply with quote

Ed Goodman:

icon_smile.gificon_smile.gif

Btw,

Currently, I have requested system people to restrict the access to NONE for that perticular dataset for the development users till further notice. Now as long as testing goes on none of us can send emails to production people icon_smile.gif
Back to top
View user's profile Send private message
Anuj Dhawan

Superior Member


Joined: 22 Apr 2006
Posts: 6250
Location: Mumbai, India

PostPosted: Thu Mar 07, 2013 11:52 am
Reply with quote

Quote:
Currently, I have requested system people to restrict the access to NONE for that perticular dataset for the development users till further notice. Now as long as testing goes on none of us can send emails to production people
What if someone requests to execute the Job using scheduler, e.g. CA7? Okay, that's again site-specifc but that possiblity might exist.
Back to top
View user's profile Send private message
Rohit Umarjikar

Global Moderator


Joined: 21 Sep 2010
Posts: 3048
Location: NYC,USA

PostPosted: Thu Mar 07, 2013 11:56 am
Reply with quote

Yes, if they do so then they need to have all the approval process, where they will get catch icon_smile.gif, and the request will be rejected and warned for further such requests.
Back to top
View user's profile Send private message
Anuj Dhawan

Superior Member


Joined: 22 Apr 2006
Posts: 6250
Location: Mumbai, India

PostPosted: Thu Mar 07, 2013 12:17 pm
Reply with quote

Fine. However, I don't see that as a good foolproof method. Also, at all the sites I've been to, there was never a way to refer a file from Prod in Test LPAR as-it-is, unless of-course you XMIT the file. Are the Jobs in question using ROUTE XEQ? icon_confused.gif

With all those site-specifc stuff, suggestion form Bill looks best that you just have a different file for different environments

I need to learn a lot more, looks like.
Back to top
View user's profile Send private message
Rohit Umarjikar

Global Moderator


Joined: 21 Sep 2010
Posts: 3048
Location: NYC,USA

PostPosted: Thu Mar 07, 2013 12:24 pm
Reply with quote

Quote:
With all those site-specifc stuff, suggestion form Bill looks best that you just have a different file for different environments


We do have this in place for dev-T*, QA-#*,prod-P* as first qualifier but in every across the regions these files are accessible. This is purely site specific tho.

Also this is needed in case if I have to generate some reports in dev based on the production data then I either I should be having a access to prod(P*) files in dev region or copy data from P* to T* and use T* file in dev to generate the reports.So better make P* available in every region directly.

Quote:
I need to learn a lot more, looks like.


No way, you are already top of all of us...icon_smile.gificon_smile.gif
Back to top
View user's profile Send private message
Bill Woodger

Moderator Emeritus


Joined: 09 Mar 2011
Posts: 7309
Location: Inside the Matrix

PostPosted: Thu Mar 07, 2013 2:23 pm
Reply with quote

Jeez, I don't want to know about your accessing Production data outside of a Production environment. Fix it, quick, as the consequences for the company/companies involved can be rapid and severe.

Have a dataset for Text. Have a dataset for E-mail addresses. Have a process which puts the two together.

Then you can use "whatever" combination of inputs for these as suit your requirement at the time. You can have multiple "dev" datasets, multiple "prod" datasets, you can use the prod datasets from test if/when necessary.

Or have I just not grasped your problem accurately?
Back to top
View user's profile Send private message
Rohit Umarjikar

Global Moderator


Joined: 21 Sep 2010
Posts: 3048
Location: NYC,USA

PostPosted: Thu Mar 07, 2013 7:20 pm
Reply with quote

I am sure your suggestions would certainly be bullet proof for the issue I have mentioned, but this is an existing process in place and just for testing purpose this change they would never be accepting proc/jcl.

But moreover I am just trying to understand how would
Quote:

Have a dataset for Text. Have a dataset for E-mail addresses. Have a process which puts the two together.


avoid sending emails from test env.?
Back to top
View user's profile Send private message
Bill Woodger

Moderator Emeritus


Joined: 09 Mar 2011
Posts: 7309
Location: Inside the Matrix

PostPosted: Thu Mar 07, 2013 7:56 pm
Reply with quote

If no e-mail messages are needed for the task, then the list of e-mail messages for the task will be empty, so no e-mail messages will be created (if the e-mail generation is "clever enough"..

If you want "no" e-mail messages, I'd put one, just so you know it's working anyway.

I get the feeling I'm missing something :-)
Back to top
View user's profile Send private message
Rohit Umarjikar

Global Moderator


Joined: 21 Sep 2010
Posts: 3048
Location: NYC,USA

PostPosted: Thu Mar 07, 2013 8:59 pm
Reply with quote

Quote:
I get the feeling I'm missing something :-)

Yeah, Bill I too think the same...icon_smile.gif but thanks for your time as always..icon_smile.gif
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


Joined: 23 Nov 2006
Posts: 19244
Location: Inside the Matrix

PostPosted: Fri Mar 08, 2013 7:55 am
Reply with quote

Hello,

Suggest you consider creating an address file for each environment. For a given process there might be a different distribution list depending on the environment.

The member name for each environment would be the same so that the proper people received each email and there would be no need to customize for each run.
Back to top
View user's profile Send private message
Rohit Umarjikar

Global Moderator


Joined: 21 Sep 2010
Posts: 3048
Location: NYC,USA

PostPosted: Fri Mar 08, 2013 10:03 pm
Reply with quote

Dick,

Thanks for the inputs, Addres file means something like this,

Code:
INPUT-OUTPUT SECTION.
       FILE-CONTROL.
           SELECT NAME-ADDRESS-FILE
                ASSIGN TO "C:\TMP\SAMPIN.TXT"
                ORGANIZATION IS LINE SEQUENTIAL.
?

if so then it will be changing of entire design, but good idea.
Back to top
View user's profile Send private message
enrico-sorichetti

Superior Member


Joined: 14 Mar 2007
Posts: 10872
Location: italy

PostPosted: Fri Mar 08, 2013 10:05 pm
Reply with quote

Code:
ASSIGN TO "C:\TMP\SAMPIN.TXT"


do You realize that what You posted is NOT mainframe related ???
Back to top
View user's profile Send private message
Rohit Umarjikar

Global Moderator


Joined: 21 Sep 2010
Posts: 3048
Location: NYC,USA

PostPosted: Fri Mar 08, 2013 10:55 pm
Reply with quote

I take it back that part, my only intention was just to know more on "an address file for each environment" term.
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


Joined: 23 Nov 2006
Posts: 19244
Location: Inside the Matrix

PostPosted: Sun Mar 10, 2013 10:13 am
Reply with quote

Hello,

The code in the program would be the same for all.

The dataset referenced would vary from one environment to another - preferable by using a symbolic parameter for the dataset name. Hopefully, all of the member names would be the same across environments.
Back to top
View user's profile Send private message
Rohit Umarjikar

Global Moderator


Joined: 21 Sep 2010
Posts: 3048
Location: NYC,USA

PostPosted: Wed Mar 13, 2013 11:54 am
Reply with quote

Dick, currently it is in place, but if I use production qualifier in test region then I still be able to send emails and I want to restrict that.
Back to top
View user's profile Send private message
Nic Clouston

Global Moderator


Joined: 10 May 2007
Posts: 2455
Location: Hampshire, UK

PostPosted: Wed Mar 13, 2013 11:58 am
Reply with quote

In a proper establishment your production qualifier woud not even be defined in a test environment and if it was only a very few people should have any access to it at all.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   This topic is locked: you cannot edit posts or make replies. View Bookmarks
All times are GMT + 6 Hours
Forum Index -> JCL & VSAM Goto page 1, 2  Next

 


Similar Topics
Topic Forum Replies
No new posts Mainframe Programmer with CICS Skill... Mainframe Jobs 0
No new posts Data Backup suggestions DB2 5
No new posts Help needed to assemble IMS sample co... ABENDS & Debugging 4
No new posts RABBIT HOLE NEEDED - "Live"... All Other Mainframe Topics 0
No new posts Mainframe profiles needed @ Cognizant Mainframe Jobs 0
Search our Forums:

Back to Top