![]() |
Telelogic DOORS (steve huntington) | ![]() |
new topic :
profile :
search :
help :
dashboard :
calendar :
home
|
||
Latest News:
|
|
Topic Title: How to free DOORS Memory Topic Summary: Created On: 20-Aug-2007 09:20 Status: Post and Reply |
Linear : Threading : Single : Branch |
![]() |
![]()
|
![]() |
|
I am trying to export 'N' number of modules to word format. After exporting each module I am closing the module, But I could found that DOORS is not releasing the memory associated with that module. ffice In the exporting process what exactly I am doing is 1) Opening the module and getting the default view. 2) Changing the default view to the view from which I need to extract the data. 3) Close the module and again open it...(Default view will get effect only if we close and open the module) 4) Now the required view gets loaded and now I export the data to word. 5) Finally I am setting the default view which I got from the Step 1) and closing the module. I could find the memory status from the task manager which goes on growing and finally I am getting an error like 93% of memory has been used and the Script gets stopped.This memory gets freed only when in close the DOORS. Can any one suggest me a solution like how to free DOORS memory during the execution of script, like after exporting a module to word or exporting a couple of modules to word. |
|
![]() |
|
![]() |
|
Unfortunately, there is no way (at least that I know of) to free memory consumed by DOORS, hence all the threads on properly deleting Skip lists, etc.
However, closing a module should free the memory which was consumed for reading it, so there must be something else going on: - are you sure your modules do not open additional modules, e.g. via a layoutDXL column in the default view? Those modules would not be closed by your routine - or, do you have memory intensive stuff going on, e.g. in layoutDXL or attributeDXL, with unnecessary strings, undeleted Skip lists, etc? This might also cause memory leaks. Regards, Peter |
|
![]() |
|
![]() |
|
Due to the inherent problem with DOORS releasing memory, I've found for my larger scripts that parse through a large portion of the database (some 200+ modules), it's best to split the "Run" up a little. I do this by usint a Batch file that uses the command line entry to start DOORS, run a script then close DOORS. Each line in the batch file calls the script, passing a specific directory. The script will run on those 10 - 20 modules, then close. Rinse, Repeat....lol ------------------------- Scott Boisvert Engineering Tools Administrator L-3 Communications - Avionics Systems scott.boisvert@l-3com.com |
|
![]() |
|
![]() |
|
Why cannot you just open the module, load the view you want, extract, then close? Opening 3 times seems hopeless. See attached.
Anyway, the problem isn't that module memory isn't released, the problem is that the exporter is string intensive and the string space isn't getting released. A great deal of wasted string-table space gets released when the DXL that uses it ends, but the sad reality of DOORS is that a lot of DXL processing will eventually cause permanant memory leak that's only released when DOORS ends. Don't know what to do about that. - Louie |
|
![]() |
|
![]() |
|
Hi Louie thank you for you suggestion but can the following can be done by your suggestion of load the view instead of opening the module setting default view and closing the module and again opening the module... ffice Open a module loop through all the objects in the module If an object has link traverse through the link and open the module and extract attribute details for three different views .....
|
|
![]() |
|
![]() |
|
Looks like all you want is the value of attribute 'ABC', if it exists, of objects that are targets of links. You don't need views at all. However, if you must keep the 'load(view)' stuff then this applies: you must keep track of which module is 'current'. Put a current = m_trg before the load and a current = m_src when you are done with that module.
[1] Change your 'edit' to 'read' since you don't want to open the target module exclusive, you are just going to read some data. [2] change your "O_tgt = object(targetAbsNo(lnk))" to simply "o_trg = target(lnk)". [3] I'd save all the open modules in a Skip list and then close them at the very end. Revised code is attached. [4] understand that the 'for o in m_src do' loop only consideres currently displayed objects. Since the current display is nebulous the vast majoriy of my loops find all objects in the 'entire' module and then explicitely exclude the ones I don't want, almost always excluding deleted objects. [5] probeAttr_ is the worst kept secret function and is routinely used to extract attribute values. It returns null when the attr doesn't exist, which is better than "Value = o.NameAttr" which will abort if the attribute doesn't exist for objects. Your 'm_src = current' at the top of the script is highly desirable and should be routine for ALL scripts that deal with a current module. [1] Add some sort of "if (null m_src) {ack("Run from open module"); halt} right after it [2] there are many commands that presume the current module (such as attribute 'exists' and 'creates') and you'll need to explicitly define current if you figure to open modules along the way since the 'current' module changes rather abruptly and often unpredictably and its hard to code around without explicit 'current = ...' commands. - Louie |
|
![]() |
|
![]() |
|
String manipulation is a huge memory leak in DOORS. If your scripts (or the views) are using stings (esp concatenation) use buffers instead.
If you are opening modules with display = false, the only way to get object information from a particular view, is to make it the default view. However, if the information you need is always the same (i.e. follow links, grab specific attribute) it would be better to do it through code rather than loading views. ------------------------- Bruce Tuskey Sr. Principle Engineer Tuskey@gmail.com "All that is gold does not glitter, not all those who wander are lost:..." - Gandalf the Grey (JRR Tolkien) Edited: 24-Aug-2007 at 00:28 by Bruce Tuskey |
|
![]() |
Telelogic DOORS
» DXL Exchange
»
How to free DOORS Memory
|
![]() |
FuseTalk Standard Edition v3.2 - © 1999-2009 FuseTalk Inc. All rights reserved.