8:05, EEST
April 17, 2015
Hi,
I am connecting to a server using an Information Model. Everything works fine, I get my generated classes returned and can access the values conveniently. The only problem is, that is becomes slow to access all the values I need which are a couple of dozens. The problem seems to be, that with every ‘get’ method a call of the UA server is needed.
Is there any way to fetch the data in a bulk read style but still using the Information Model? Or something similar to an eager and lacy loading of hibernate would be create.
Regards,
Thomas
10:24, EEST
December 21, 2011
Yes, this is a known problem at the moment. There is a NodeCache in the background, it is just configured by default with a short timeout, to ensure that the nodes are always up to date.
You can try to increase the timeout, for example with
or with an even bigger value (in milliseconds).
The effect is that the nodes are no longer read again and again from the server. Just note that the Value is also not refreshed any more. The Value refresh is the reason why we currently define the timeout to be just 1000 ms by default; so we can “guarantee” that the latest value is available from the node, but it also means that the complete nodes are re-read all the time.
We will need to figure out a way to keep the nodes in the cache and still read the value from the server whenever it needs to be, to guarantee that it is up to date.
Reading several nodes with a single read – or enabling some kind of lazy loading would be good ideas for future development as well.
11:14, EEST
April 17, 2015
Most Users Ever Online: 1919
Currently Online:
23 Guest(s)
Currently Browsing this Page:
1 Guest(s)
Top Posters:
Heikki Tahvanainen: 402
hbrackel: 144
rocket science: 88
pramanj: 86
Francesco Zambon: 83
Ibrahim: 78
Sabari: 62
kapsl: 57
gjevremovic: 49
Xavier: 43
Member Stats:
Guest Posters: 0
Members: 738
Moderators: 7
Admins: 1
Forum Stats:
Groups: 3
Forums: 15
Topics: 1524
Posts: 6451
Newest Members:
jonathonmcintyre, fannielima, kristiewinkle8, rust, christamcdowall, redaahern07571, nigelbdhmp, travistimmons, AnnelCib, dalenegettingerModerators: Jouni Aro: 1026, Pyry: 1, Petri: 0, Bjarne Boström: 1026, Jimmy Ni: 26, Matti Siponen: 346, Lusetti: 0
Administrators: admin: 1