ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » IIB Timer Node used as scheduler - EXTRACT esql function

Post new topic  Reply to topic
 IIB Timer Node used as scheduler - EXTRACT esql function « View previous topic :: View next topic » 
Author Message
riteshprasad1
PostPosted: Mon May 04, 2020 6:20 am    Post subject: IIB Timer Node used as scheduler - EXTRACT esql function Reply with quote

Apprentice

Joined: 31 Jul 2014
Posts: 25

Hi I am posting this to seek help for implementation of the IIB Timer node as a scheduler, I understand this is not a good option to implement when compared to an external scheduler, but using the timeout notification node and the timeout control node is the only option given to me.

The flow needs to be triggered once a week - every friday at 5PM. Has anyone used the EXTRACT DAYOFWEEK esql function ? Please suggest.
Back to top
View user's profile Send private message
Vitor
PostPosted: Mon May 04, 2020 7:21 am    Post subject: Re: IIB Timer Node used as scheduler - EXTRACT esql function Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

riteshprasad1 wrote:
using the timeout notification node and the timeout control node is the only option given to me.


Why? It's implausible in the extreme that the OS you're using (never mind the site you're on) doesn't have an external scheduler. Why are you being restricted to this? If it's simply management not wanting to get involved in the paperwork of involving whoever owns the scheduler, that's not a restriction.

In any event, does whoever's imposing this restriction understand the implications of using what you yourself describe as "not a good option"

riteshprasad1 wrote:
Has anyone used the EXTRACT DAYOFWEEK esql function ?


Yes thank you; are you asking if it works? It does.

Are your asking how you can stop the flow burning through a bunch of resources spinning round and round every few seconds checking to see if it's 5pm on a Friday yet? You can't.
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
riteshprasad1
PostPosted: Mon May 04, 2020 7:55 am    Post subject: Re: IIB Timer Node used as scheduler - EXTRACT esql function Reply with quote

Apprentice

Joined: 31 Jul 2014
Posts: 25

Thanks Victor, do not want to comment on the management limitations. If I am able to extract the day and time I can write a condition to kick of the flow.
Back to top
View user's profile Send private message
Vitor
PostPosted: Mon May 04, 2020 8:54 am    Post subject: Re: IIB Timer Node used as scheduler - EXTRACT esql function Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

riteshprasad1 wrote:
Thanks Victor


Why do people think there's a "c" in my name?

riteshprasad1 wrote:
do not want to comment on the management limitations.


You likewise don't want them to comment on the implementation of a non-optimal solution being your fault and you never told them

riteshprasad1 wrote:
If I am able to extract the day and time I can write a condition to kick of the flow.


Did you seriously worry the function didn't work as described in the InfoCenter? Did you actually post here to make sure it would work?

Of course you can write ESQL that checks to see if it's 5pm on a Friday. That's not what makes this:

Quote:
not a good option

_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
riteshprasad1
PostPosted: Mon May 04, 2020 9:01 am    Post subject: Re: IIB Timer Node used as scheduler - EXTRACT esql function Reply with quote

Apprentice

Joined: 31 Jul 2014
Posts: 25

I tried to use -

DECLARE dayoftheweek Integer;
SET OutputLocalEnvironment.dayoftheweek = EXTRACT (DAYOFWEEK FROM CURRENT_DATE);

It gave me the day of the week. Need to now work on the time and put a propagate condition.
Back to top
View user's profile Send private message
riteshprasad1
PostPosted: Mon May 04, 2020 9:08 am    Post subject: Re: IIB Timer Node used as scheduler - EXTRACT esql function Reply with quote

Apprentice

Joined: 31 Jul 2014
Posts: 25

Vitor wrote:
Why do people think there's a "c" in my name?


Oops Sorry Vitor.

Vitor wrote:
Did you seriously worry the function didn't work as described in the InfoCenter? Did you actually post here to make sure it would work?


Posted it here just to get some reference if someone has already implemented something similar, hope it doesn't hurt.
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Mon May 04, 2020 10:39 am    Post subject: Reply with quote

Grand High Poobah

Joined: 18 Nov 2003
Posts: 20696
Location: LI,NY

It still isn't a good solution. What happens if at Friday 5 pm the eg / broker is not running. What happens if you need to bounce the broker/eg middle of the week?
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
riteshprasad1
PostPosted: Mon May 04, 2020 7:09 pm    Post subject: Reply with quote

Apprentice

Joined: 31 Jul 2014
Posts: 25

fjb_saper wrote:
It still isn't a good solution. What happens if at Friday 5 pm the eg / broker is not running. What happens if you need to bounce the broker/eg middle of the week?


Explained a lot to the Architect, can't do much...he came back with showing me couple of links where they suggest using timeout notification as scheduler

https://ibmbpmstuffs.wordpress.com/2016/10/18/job-scheduling-in-iib9-using-timeout-nodesfiles/

https://blogs.perficient.com/2016/04/27/setting-up-scheduler-for-auto-triggering-of-applications-in-iib/

Going ahead with -

SET OutputLocalEnvironment.dayoftheweek = EXTRACT (DAYOFWEEK FROM CURRENT_DATE);
SET OutputLocalEnvironment.houroftheday = EXTRACT (HOUR FROM CURRENT_TIME);

and then propagating with if.

-- "It is what it is" --
Back to top
View user's profile Send private message
Vitor
PostPosted: Tue May 05, 2020 5:58 am    Post subject: Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

riteshprasad1 wrote:
Explained a lot to the Architect, can't do much...he came back with showing me couple of links where they suggest using timeout notification as scheduler


Tell your architect, from me, that using 2 personal blogs from 4 years ago to support his position is not swaying my view.

Also going to the architect is not the point. You need to explain to whatever branch of management expects this to work in production flawlessly for the next n years that it's "not a good option" because when this fails, it won't be the architect on the block for it.

riteshprasad1 wrote:
-- "It is what it is" --




<rant>
This sound bite annoys me more than almost anything. It's the weary resignation that you're stuck in a bad situation with no options and the best that the downtrodden can hope for is that the kicking will stop soon; the best way to stop the kicking is to make no fuss whatsoever.

There are always options. There is no reason to accept a bad solution (or situation) quietly and without a fuss especially when you're the one who will face the consequences. Yes, maybe nothing can be done and eventually what was going to happen will happen, but at least you have the satisfaction of knowing you tried to do something. History would have been very different if the conversation between the Wright brothers had been:

Orville: you know, it would be great if there was a flying machine to transport people & goods.
Wilbur: yeah, but what are the odds the wagon makers wouldn't sue? It is what it is
Orville: yeah, you're right, you want a hand with that bike wheel?

Or if when Alexander Fleming had asked for budget to investigate this mold he'd noticed, he'd accepted his boss's claim that no-one would spend money on mold with "oh well, it is what it is" and gone back to developing soaps?

</rant>
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
joebuckeye
PostPosted: Wed May 06, 2020 5:47 am    Post subject: Reply with quote

Partisan

Joined: 24 Aug 2007
Posts: 364
Location: Columbus, OH

You should set up a test flow using the ideas in those blog posts and just have it send you and the architect an email at whatever time is decided. Do it in a test environment.

Then once the flow is up and running you can do all sorts of things to it. Stop the flow around the time selected and restart it after that time. Restart the flow. Restart the execution group. Restart the broker. Restart the server.

Do all sorts of things to see if the timing capability of the flow actually works as expected.

We only ever use the timer functionality for relative time checks and when it doesn't matter if it misses an interval or fires more than once over the desired interval.

For things that require exact timing to fire off we use a simple cronjob that drops a slug message (ie the arrival of the message is what is important, not the contents of the message) to kick start the flow.
Back to top
View user's profile Send private message
Vitor
PostPosted: Wed May 06, 2020 6:16 am    Post subject: Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

joebuckeye wrote:
For things that require exact timing to fire off we use a simple cronjob that drops a slug message (ie the arrival of the message is what is important, not the contents of the message) to kick start the flow.



_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
gbaddeley
PostPosted: Wed May 06, 2020 3:04 pm    Post subject: Reply with quote

Jedi

Joined: 25 Mar 2003
Posts: 2492
Location: Melbourne, Australia

Vitor wrote:
joebuckeye wrote:
For things that require exact timing to fire off we use a simple cronjob that drops a slug message (ie the arrival of the message is what is important, not the contents of the message) to kick start the flow.


In effect, you are using a job scheduling system to do this, namely cron. If you need to stop / start flows (mqsi commands) or any other time critical actions (eg. put a control MQ message), cron can do this reliably. Likewise, Task Scheduler on Windows, and various other 3rd party vendor offerings that cover all enterprise OS platforms with one product.
_________________
Glenn
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » IIB Timer Node used as scheduler - EXTRACT esql function
Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.