Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 366450 - Handling of List/Map that return null when iterators or Sets are expected
Summary: Handling of List/Map that return null when iterators or Sets are expected
Status: RESOLVED FIXED
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: Eclipselink (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Blaise Doughan CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-12-12 14:23 EST by Blaise Doughan CLA
Modified: 2022-06-09 10:15 EDT (History)
0 users

See Also:


Attachments
MOXy - Test Cases (11.85 KB, patch)
2011-12-12 14:24 EST, Blaise Doughan CLA
no flags Details | Diff
Core - Fix (761 bytes, patch)
2011-12-12 14:24 EST, Blaise Doughan CLA
no flags Details | Diff
MOXy - Fix (1.83 KB, patch)
2011-12-12 14:25 EST, Blaise Doughan CLA
no flags Details | Diff
MOXy - Test Cases (Part 2) (5.82 KB, patch)
2011-12-12 17:06 EST, Blaise Doughan CLA
no flags Details | Diff
Core - Fix (Part 2) (20.63 KB, patch)
2011-12-12 17:06 EST, Blaise Doughan CLA
no flags Details | Diff
MOXy - Test Cases (Part 2) (7.14 KB, patch)
2011-12-12 17:30 EST, Blaise Doughan CLA
no flags Details | Diff
Core - Fix (Part 2) (24.48 KB, patch)
2011-12-12 17:31 EST, Blaise Doughan CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Blaise Doughan CLA 2011-12-12 14:23:01 EST
There appear to be some implementations of List & Map out there that can return null iterators or entry/key sets.  This bug is to add tolerance into MOXy for these types of containers.
Comment 1 Blaise Doughan CLA 2011-12-12 14:24:13 EST
Created attachment 208280 [details]
MOXy - Test Cases
Comment 2 Blaise Doughan CLA 2011-12-12 14:24:52 EST
Created attachment 208281 [details]
Core - Fix
Comment 3 Blaise Doughan CLA 2011-12-12 14:25:50 EST
Created attachment 208282 [details]
MOXy - Fix
Comment 4 Blaise Doughan CLA 2011-12-12 15:38:09 EST
Fix checked into trunk at revision:  10546

Code reviewed by:  Denise Smith

Fix Details:
Check to see if the iterator returned from a List, or the entrySet/keySet returned from a Map is not null before processing it.
Comment 5 Blaise Doughan CLA 2011-12-12 17:00:41 EST
This issue is also occuring for Lists mapped with @XmlAnyElement, @XmlElements, and @XmlList.
Comment 6 Blaise Doughan CLA 2011-12-12 17:06:06 EST
Created attachment 208293 [details]
MOXy - Test Cases (Part 2)
Comment 7 Blaise Doughan CLA 2011-12-12 17:06:26 EST
Created attachment 208294 [details]
Core - Fix (Part 2)
Comment 8 Blaise Doughan CLA 2011-12-12 17:30:27 EST
Created attachment 208297 [details]
MOXy - Test Cases (Part 2)
Comment 9 Blaise Doughan CLA 2011-12-12 17:31:10 EST
Created attachment 208298 [details]
Core - Fix (Part 2)
Comment 10 Blaise Doughan CLA 2011-12-12 17:48:22 EST
Fix checked into trunk at rev:  10549

Code reviewed by:  Rick Barkhouse

Fix Details:
Extended original fix to cover @XmlElements, @XmlAnyElement, and @XmlList for both Marshaller and Binder
Comment 11 Eclipse Webmaster CLA 2022-06-09 10:09:14 EDT
The Eclipselink project has moved to Github: https://github.com/eclipse-ee4j/eclipselink
Comment 12 Eclipse Webmaster CLA 2022-06-09 10:15:59 EDT
The Eclipselink project has moved to Github: https://github.com/eclipse-ee4j/eclipselink