[jira] [Assigned] (OAK-249) Add support for auto created properties

2012-10-25 Thread Marcel Reutegger (JIRA)

 [ 
https://issues.apache.org/jira/browse/OAK-249?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Marcel Reutegger reassigned OAK-249:


Assignee: Marcel Reutegger

 Add support for auto created properties
 ---

 Key: OAK-249
 URL: https://issues.apache.org/jira/browse/OAK-249
 Project: Jackrabbit Oak
  Issue Type: Sub-task
  Components: jcr
Affects Versions: 0.5
Reporter: Chetan Mehrotra
Assignee: Marcel Reutegger

 While trying to run Sling with Oak PathNotFoundException are seen with  
 properties like jcr:createdBy, jcr:created etc while accessing a node of type 
 nt:file. It appears that current node creation logic is not generating the 
 default properties as defined in the nodetype.
 {code:java}
   @Test
 public void testDefaultProperties() throws RepositoryException {
 Node testRootNode = getNode(TEST_PATH);
 Node fileNode = testRootNode.addNode(foo.png,nt:file);
 Binary b = 
 testRootNode.getSession().getValueFactory().createBinary(new 
 ByteArrayInputStream(abcdefgh.getBytes()));
 Node contentNode = fileNode.addNode(jcr:content,nt:resource);
 contentNode.setProperty(jcr:data,b);
 testRootNode.getSession().save();
 Node cn = testRootNode.getNode(foo.png);
 assertNotNull(cn.getProperty(jcr:createdBy));
 assertNotNull(cn.getProperty(jcr:created));
 }
 {code}
 Above testcase fails with oak but passes with Jackrabbit. Most probably the 
 logic present in 
 org.apache.jackrabbit.core.NodeTypeInstanceHandler#computeSystemGeneratedPropertyValues
  has to be ported to Oak

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Assigned] (OAK-395) Inconsistency in Node#setProperty in case of null value

2012-10-25 Thread angela (JIRA)

 [ 
https://issues.apache.org/jira/browse/OAK-395?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

angela reassigned OAK-395:
--

Assignee: angela

 Inconsistency in Node#setProperty in case of null value
 ---

 Key: OAK-395
 URL: https://issues.apache.org/jira/browse/OAK-395
 Project: Jackrabbit Oak
  Issue Type: Bug
  Components: jcr
Reporter: angela
Assignee: angela

 Setting a null value to a single valued property will result
 in 'null' being returned while executing the same on a multivalued
 property will return the removed property.
 jr2 returned the removed property in both cases as far as i 
 remember and i would suggest that we don't change that behavior. in
 particular since the specification IMO doesn't allow to return
 null-values for these methods.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Created] (OAK-395) Inconsistency in Node#setProperty in case of null value

2012-10-25 Thread angela (JIRA)
angela created OAK-395:
--

 Summary: Inconsistency in Node#setProperty in case of null value
 Key: OAK-395
 URL: https://issues.apache.org/jira/browse/OAK-395
 Project: Jackrabbit Oak
  Issue Type: Bug
  Components: jcr
Reporter: angela


Setting a null value to a single valued property will result
in 'null' being returned while executing the same on a multivalued
property will return the removed property.

jr2 returned the removed property in both cases as far as i 
remember and i would suggest that we don't change that behavior. in
particular since the specification IMO doesn't allow to return
null-values for these methods.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Created] (OAK-403) PropertyIndexLookup does not find indexes

2012-10-25 Thread Marcel Reutegger (JIRA)
Marcel Reutegger created OAK-403:


 Summary: PropertyIndexLookup does not find indexes
 Key: OAK-403
 URL: https://issues.apache.org/jira/browse/OAK-403
 Project: Jackrabbit Oak
  Issue Type: Bug
  Components: core
Affects Versions: 0.5
Reporter: Marcel Reutegger
Assignee: Marcel Reutegger


The PropertyIndexLookup tries to locate the index by child node name instead of 
matching the name of the property with the values of the 'propertyNames' 
property on the index node.

In addition the paths returned by the find() method are not absolute. This will 
result in an IllegalArgumentException when the path is turned into a Tree.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira