Uploaded image for project: 'ModeShape'
  1. ModeShape
  2. MODE-2361

FilesystemConnector in EAP doesn't store changes to external properties

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Cannot Reproduce
    • Icon: Major Major
    • 4.1.0.Final
    • 3.8.1.Final
    • Federation

      I add custom type and properties when creating a node at external resource (file system). After session.save(), I want to change custom properties value. However, the previous value does not change.

      External resource configuration:

      /subsystem=modeshape/repository=samplerepository/source=sampleextsource:add(classname="org.modeshape.connector.filesystem.FileSystemConnector",properties=[{"directoryPath"=>"/somewhere"}], readonly="false",projections=["default:/extsource => /"], cacheTtlSeconds="1")
      

      Reading and updating property values:

                      // Creating custom type and property  
            
                      NodeTypeManager ntm = ...  
                      NodeTypeTemplate ntt = ntm.createNodeTypeTemplate();  
                      ntt.setName("sometype");  
                      ntt.setMixin(true);  
            
                      PropertyDefinitionTemplate pdt = ntm.createPropertyDefinitionTemplate();  
                      pdt.setName("someproperty");  
                      pdt.setRequiredType(PropertyType.STRING);  
            
                      ntt.getPropertyDefinitionTemplates().add(pdt);  
                      ntm.registerNodeType(ntt, true);  
                      ...       
                      Node node = ...  
                      node.addMixin("sometype");  
                      node.setProperty("someproperty", "sample");  
                      node.addMixin(JcrConstants.MIX_REFERENCEABLE);  
                      // Changing "someproperty" property value "sample" to "change" in somewhere else.        
                      session = ...        
                      Node node = ...  
                      node.setProperty("someproperty", "change");       
                      session.save();  
      

      However, "someproperty" is still "sample".

              hchiorean Horia Chiorean (Inactive)
              mustafamizrak@gmail.com Mustafa Mizrak (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: