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 » How to reload the saved cache every 24 hours

Post new topic  Reply to topic
 How to reload the saved cache every 24 hours « View previous topic :: View next topic » 
Author Message
joemq
PostPosted: Tue May 19, 2015 3:04 pm    Post subject: How to reload the saved cache every 24 hours Reply with quote

Novice

Joined: 18 May 2012
Posts: 10

Hi,
I am using a SHARED ROW to store the database records and to use it further with out interacting with the database from next time onwards. Basically i am storing the records in to a cache.

My questions is if some one did any changes to the dababase how to get those changes and I have a requirement that every 24 hours reload the cache and get the latest database records

How can we achieve this in esql?
Back to top
View user's profile Send private message
Armageddon123
PostPosted: Tue May 19, 2015 6:08 pm    Post subject: Reply with quote

Acolyte

Joined: 11 Feb 2014
Posts: 61

one option is to use TimeoutNotification node
Back to top
View user's profile Send private message
kash3338
PostPosted: Tue May 19, 2015 6:30 pm    Post subject: Reply with quote

Shaman

Joined: 08 Feb 2009
Posts: 709
Location: Chennai, India

If your requirement is constant to reload every 24 Hrs, have a logic in your ESQL to check on previous reload time and when it reaches more than 24 Hrs fetch from DB again and load your cache.
Back to top
View user's profile Send private message Send e-mail
joemq
PostPosted: Tue May 19, 2015 9:57 pm    Post subject: Reply with quote

Novice

Joined: 18 May 2012
Posts: 10

Reload wont happen every 24 hours . I Just have to check database in every 24 hours and reload my cache data with what ever present in database. we are using some logic in shared variables so that it wont hit database again for evey run. Please let me know.
Back to top
View user's profile Send private message
zpat
PostPosted: Tue May 19, 2015 10:53 pm    Post subject: Reply with quote

Jedi Council

Joined: 19 May 2001
Posts: 5866
Location: UK

As he said, just record in the cache the date/time the data was loaded into the cache.

Before you access the cache data, check that date/time, if it's a different date or more than 24 hrs old (whichever you prefer), refresh the cache data from the database.
_________________
Well, I don't think there is any question about it. It can only be attributable to human error. This sort of thing has cropped up before, and it has always been due to human error.
Back to top
View user's profile Send private message
ladman
PostPosted: Wed May 20, 2015 3:42 am    Post subject: Reply with quote

Newbie

Joined: 07 Mar 2012
Posts: 3

I would consider using the TimeoutNotification Node - especially if you're thinking performance and/or have more than one instance of the flow.

Using this node you can (almost) ensure that the cache is always updated when a message arrive, and you will also ensure that you only fetch the data once if you have additional listeners.
Back to top
View user's profile Send private message
Vitor
PostPosted: Wed May 20, 2015 4:54 am    Post subject: Reply with quote

Grand High Poobah

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

If you're using IIBv9, use the inbuilt shared cache & "time to live"
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
joemq
PostPosted: Wed May 20, 2015 5:31 am    Post subject: Reply with quote

Novice

Joined: 18 May 2012
Posts: 10

I am not using IIBv9.
Back to top
View user's profile Send private message
mqjeff
PostPosted: Wed May 20, 2015 5:38 am    Post subject: Reply with quote

Grand Master

Joined: 25 Jun 2008
Posts: 17447

joemq wrote:
I am not using IIBv9.


Have you reviewed the availability of the global cache in the version you are using?
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 » How to reload the saved cache every 24 hours
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.