cancel
Showing results for 
Search instead for 
Did you mean: 

How does one make wise use dictionaries in ESP?

Former Member
0 Kudos

Folks,

I have a project with several Flex windows, wherein I have a significant dependency on use of dictionaries.

In most cases I am modifying the contents of the dictionaries on a frequent basis to maintain a notion

of "most recent" information.  This information is then used to enrich, map or derive other content on the

way through the Flex window.

My project grows in memory fast.....out of control actually.  I suspect [now] that I am being wreckless

with my dictionary use.  What rules of thumb should I follow?   Do I need to do some kind of periodic

"cleanup" of my dictionaries (copy, delete, recreate)?

Looking for advice on best practices here from people who have been there and faced this.

Thanks,

Michael

Accepted Solutions (0)

Answers (2)

Answers (2)

JWootton
Advisor
Advisor
0 Kudos

I agree with Alice - you may want to have a look at Event Cache.  You can also reference the output window that a Flex is creating from within the Flex - to look at previous values, for example.

As for using dictionaries,  yes you do need to do clean up - and remember that the memory isn't released until the flex 'exits'.  So if you create and delete lots of dictionaries in the flex, the delete won't take effect until the flex completely finishes processing the event.

Also:  don't just keep adding things to the dictionary without ever deleting  - or you will have an infinitely growing dictionary.

If you thing you are following all those rules and still having problems, give us more details or share a sample of the CCL.  Or conversely,  describe what you need to do and someone may be able to show you an example of a "safe" (and efficient) way to do it.

Former Member
0 Kudos

Thanks Jeff.  I have stayed with dictionaries for now (just too far down the road to rework using Event Cache strategy) and I am being a better citizen about adhering to use of "remove" function

on dictionary members prior to replacing them.  I've also moved as much as I can away from windows and toward use of streams.

Lastly, I've upgraded to ESP 5.1 SP04 PL03 on the server side of things (but not my Studio on Windows) and am getting messages about copyRecord being deprecated.  What's the replacement for this function going forward?

Thanks,

Michael

former_member217348
Participant
0 Kudos

Hi Michael,

Please start a new post for your copyRecord question, as it is a totally different topic. That way if anyone else has the same question, they will be able to search for it easily.

Thanks,

Alice

former_member217348
Participant
0 Kudos