This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 46346 - Indexes in MdrStorage waste memory
Summary: Indexes in MdrStorage waste memory
Status: CLOSED FIXED
Alias: None
Product: java
Classification: Unclassified
Component: Unsupported (show other bugs)
Version: 4.x
Hardware: PC All
: P4 blocker (vote)
Assignee: Martin Matula
URL:
Keywords: PERFORMANCE
Depends on:
Blocks:
 
Reported: 2004-07-20 16:26 UTC by _ rkubacki
Modified: 2006-03-24 09:43 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description _ rkubacki 2004-07-20 16:26:39 UTC
MdrStorage.getContextAssocEndIndexName produces
highly ineffective names used as a keys for a
hashtable references from NameIndex. They typicaly
look like:
ae:1CCBE232-D0DE-11D8-ACAD-208A06A3AA77:000000000000008C:1CCBE232-D0DE-11D8-ACAD-208A06A3AA77:00000000000000931

It means that they contains twice the same
storageId  as a part of MofId string represantion.
I found 460 instances if these String in my IDE
(nb20040719) with two projects opened containg 6
files running on JDK1.5.0b55. Each one is 112
characters so we have more than 100kB occupied by
them.

Probably we can squeeze them significantly.
Comment 1 Martin Matula 2004-07-21 23:05:14 UTC
Fixed.

Checking in src/org/netbeans/mdr/storagemodel/MdrStorage.java;
/cvs/mdr/src/org/netbeans/mdr/storagemodel/MdrStorage.java,v  <-- 
MdrStorage.java
new revision: 1.62; previous revision: 1.61
done
Comment 2 _ rkubacki 2004-07-22 11:08:01 UTC
Thanks, now they are 472 string with values like 'ae:2183:2195:2'

Perhaps you can fix also other indexes. Although it is not big benefit
now it will not cause creating of string version of mofid for them.

34 instances of
ai:4AD8D42A-DBBE-11D8-8F69-963C2051AA77:0000000000000EB3:Java.Resource.name
21 insatnces of aibn:4778E02A-DBBE-11D8-8F69-963C2051AA77:0000000000000B0A
21 instances of aicp:4778E02A-DBBE-11D8-8F69-963C2051AA77:0000000000000B0A

Number of instances depends on numbers of classpath entries I guess.
Comment 3 Martin Matula 2004-07-22 11:46:14 UTC
You are right. Now it is fixed.

Checking in src/org/netbeans/mdr/storagemodel/MdrStorage.java;
/cvs/mdr/src/org/netbeans/mdr/storagemodel/MdrStorage.java,v  <-- 
MdrStorage.java
new revision: 1.63; previous revision: 1.62
done