Author |
Message
|
chris boehnke |
Posted: Mon Jul 06, 2015 8:19 am Post subject: storing data in shared variables |
|
|
 Partisan
Joined: 25 Jul 2006 Posts: 369
|
Hi All,
We are using wmb in our project to call a webservice and transform the response from webservice to the client specific response format.
The response we are getting from webservice doesnt have the UI data. So we are planning to store the UI data in a file, access the file thru message broker and cache it in shared variables.
But the size of the file is 0.5 MB- 1MB. I am wondering if there will be any performance impact by storing this large data.
Let me know if there are any other best options.
Thanks |
|
Back to top |
|
 |
inMo |
Posted: Mon Jul 06, 2015 11:13 am Post subject: Re: storing data in shared variables |
|
|
 Master
Joined: 27 Jun 2009 Posts: 216 Location: NY
|
chris boehnke wrote: |
The response we are getting from webservice doesnt have the UI data.
|
What does this mean? What is the UI data? |
|
Back to top |
|
 |
nelson |
Posted: Mon Jul 06, 2015 12:45 pm Post subject: |
|
|
 Partisan
Joined: 02 Oct 2012 Posts: 313
|
|
Back to top |
|
 |
smdavies99 |
Posted: Mon Jul 06, 2015 10:08 pm Post subject: Re: storing data in shared variables |
|
|
 Jedi Council
Joined: 10 Feb 2003 Posts: 6076 Location: Somewhere over the Rainbow this side of Never-never land.
|
inMo wrote: |
chris boehnke wrote: |
The response we are getting from webservice doesnt have the UI data.
|
What does this mean? What is the UI data? |
User Identifier?
Or a Username/password in the SOAP header. _________________ WMQ User since 1999
MQSI/WBI/WMB/'Thingy' User since 2002
Linux user since 1995
Every time you reinvent the wheel the more square it gets (anon). If in doubt think and investigate before you ask silly questions. |
|
Back to top |
|
 |
chris boehnke |
Posted: Tue Jul 07, 2015 4:58 am Post subject: |
|
|
 Partisan
Joined: 25 Jul 2006 Posts: 369
|
UI elements - User Interface elements.
We are using WMB v8.
The size of file to be cached is 500KB -1 MB.
Is it ok performance wise to cache huge data?
Are there any other options? |
|
Back to top |
|
 |
inMo |
Posted: Tue Jul 07, 2015 7:33 am Post subject: |
|
|
 Master
Joined: 27 Jun 2009 Posts: 216 Location: NY
|
Quote: |
UI elements - User Interface elements
...
The size of file to be cached is 500KB -1 MB
|
If you don't mind backing up into some design questions... What I'm trying to figure out is WHY and WHEN you are caching a file. Is this static data that needs to be loaded once at startup or is this dynamic data you are storing with each execution. What is happening design wise that this data needs to be cached? |
|
Back to top |
|
 |
mqjeff |
Posted: Tue Jul 07, 2015 7:43 am Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
I might tend to use a global cache rather than a shared variable and configure a standalone (and otherwise unused) EG to hold the store. that way you aren't filling up the EG's memory that's trying to do work, except as it needs the memory to do the work.
But it really isn't clear why you want do put this kind of data here.
Are you trying to use an HTTPInput node to serve a full webpage, with JSON/AJAX/etc UI elements, rather than just a data stream?
You should really put a real webserver in front of the integration node instead. |
|
Back to top |
|
 |
chris boehnke |
Posted: Tue Jul 07, 2015 8:14 am Post subject: |
|
|
 Partisan
Joined: 25 Jul 2006 Posts: 369
|
All,
The current architecture is as below.
1.The exisiting java webservice hosts both plan and UI data.
2. WMB calls the existing webservice and sends the response(with plan + UI data) to client.
The new architecture is as below.
1. The new webservice is built with plan data only.
2. The UI data will be placed in a file. This is a kind of static file. It changes once in a year or 6 months.
3. From WMB, i have to call the new webservice, get the plan data, aggregate the data with UI data and send the response back to client. |
|
Back to top |
|
 |
ganesh |
Posted: Tue Jul 07, 2015 11:55 am Post subject: |
|
|
Master
Joined: 18 Jul 2010 Posts: 294
|
chris boehnke wrote: |
All,
2. The UI data will be placed in a file. This is a kind of static file. It changes once in a year or 6 months.
|
If it is a static file why don't you use a FILE READ node and read it every time. |
|
Back to top |
|
 |
chris boehnke |
Posted: Tue Jul 07, 2015 12:04 pm Post subject: |
|
|
 Partisan
Joined: 25 Jul 2006 Posts: 369
|
[quote="ganesh"]
chris boehnke wrote: |
If it is a static file why don't you use a FILE READ node and read it every time. |
I think reading file for every transaction is expensive.
I want to know the best way of caching , so that it doesnt efefct the performance |
|
Back to top |
|
 |
ganesh |
Posted: Tue Jul 07, 2015 12:08 pm Post subject: |
|
|
Master
Joined: 18 Jul 2010 Posts: 294
|
[quote="chris boehnke"]
ganesh wrote: |
chris boehnke wrote: |
If it is a static file why don't you use a FILE READ node and read it every time. |
I think reading file for every transaction is expensive.
I want to know the best way of caching , so that it doesnt efefct the performance |
Embeded global cache is something you should try. |
|
Back to top |
|
 |
chris boehnke |
Posted: Tue Jul 07, 2015 12:59 pm Post subject: |
|
|
 Partisan
Joined: 25 Jul 2006 Posts: 369
|
I am seeing global cache configured at Broker level and EG level.
Is it like, if configured at beoker level all EG's can use cache and if configured for EG's only the specified eg's can use the cache? |
|
Back to top |
|
 |
|