[dna-issues] [JBoss JIRA] Updated: (DNA-374) Multiplicity of some properties may change when saved and reloaded from the graph
Randall Hauch (JIRA)
jira-events at lists.jboss.org
Mon Apr 27 14:42:46 EDT 2009
[ https://jira.jboss.org/jira/browse/DNA-374?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Randall Hauch updated DNA-374:
------------------------------
Attachment: DNA-374.patch
Added a patch that fixes this issue by maintaining a hidden property to store the names of the properties that use multi-valued definitions but that have only one value. This property is persisted as required, but is also cleaned up if it is empty or no longer needed.
The patch also moves the "dna:nodeDefinition" and this new property into a new "dnaint" namespace. This allows some of the code to just check the namespace to know whether properties should be hidden from the JCR view.
> Multiplicity of some properties may change when saved and reloaded from the graph
> ---------------------------------------------------------------------------------
>
> Key: DNA-374
> URL: https://jira.jboss.org/jira/browse/DNA-374
> Project: DNA
> Issue Type: Bug
> Components: JCR
> Reporter: Randall Hauch
> Assignee: Randall Hauch
> Priority: Blocker
> Fix For: 0.4
>
> Attachments: DNA-374.patch
>
>
> This problem arises when a client uses the multi-valued setter methods in the JCR API to create on a node a new property with a single value, to save the node, and then to continue working with the property (again, using the multi-valued setter or getter methods). When the property is created, an appropriate multi-valued property definition will be chosen from those available on the node's primary type (and mixin types, if there are any). However, after the save, the property may node have a single-valued property definition. And since JCR does not allow a single-valued property to be changed via the multi-valued setters, the result is an exception when the client attempts to set the property using the multi-valued setters.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the dna-issues
mailing list