| Summary: | PERF: dead code in AbstractRecord | ||||||
|---|---|---|---|---|---|---|---|
| Product: | z_Archived | Reporter: | Martin JANDA <jandam> | ||||
| Component: | Eclipselink | Assignee: | James Sutherland <jamesssss> | ||||
| Status: | RESOLVED FIXED | QA Contact: | |||||
| Severity: | minor | ||||||
| Priority: | P2 | CC: | jamesssss, tom.ware | ||||
| Version: | unspecified | Keywords: | performance | ||||
| Target Milestone: | --- | Flags: | jamesssss:
iplog+
|
||||
| Hardware: | All | ||||||
| OS: | All | ||||||
| Whiteboard: | |||||||
| Attachments: |
|
||||||
Setting target and priority. See the following page for the meanings of these fields: http://wiki.eclipse.org/EclipseLink/Development/Bugs/Guidelines Observation seems correct. Fixing in 2.3. Created attachment 196450 [details]
patch
Fixed in 2.3 The Eclipselink project has moved to Github: https://github.com/eclipse-ee4j/eclipselink |
Build Identifier: 2.2 revision 8831 - 01/14/2011 03:10 AM DatabaseField.setIndex is never called in methods: *) public Object get(DatabaseField key) *) public Object getIndicatingNoEntry(DatabaseField key) --- Original code index = this.fields.indexOf(key); if (index >= 0) { // PERF: If the fields index was not set, then set it. if (index == -1) { key.setIndex(index); } return this.values.get(index); } else { return null; } --- Intended code index = this.fields.indexOf(key); if (index >= 0) { // PERF: If the fields index was not set, then set it. ! if (key.getIndex() == -1) { key.setIndex(index); } return this.values.get(index); } else { return null; } --- Impact Access to record values are made through DatabaseFields with index already set. According to my observation 'setIndex' should be called in ParameterExpression and in AbstractTransformationMapping. Reproducible: Always