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

FilesystemConnector in EAP doesn't store changes to external properties

    Details

      Description

      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".

        Gliffy Diagrams

          Attachments

            Activity

              People

              • Assignee:
                hchiorean Horia Chiorean
                Reporter:
                mustafamizrak Mustafa Mizrak
              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: