Platform Explorer / Nuxeo Platform LTS 2017 9.10

Contribution org.nuxeo.ecm.directory.storage--directories

This contribution is part of XML component org.nuxeo.ecm.directory.storage inside nuxeo-runtime-9.10.jar /Users/arnaud/Nuxeo/distrib/nuxeo-server-tomcat-9.10/nxserver/config/default-directories-bundle.xml

Extension Point

Extension point directories of component GenericDirectory.

Contributed Items

  • <directory extends="template-user" name="userDirectory">
    
          <schema>user</schema>
    
          <types>
            <type>system</type>
          </types>
    
          <idField>username</idField>
          <passwordField>password</passwordField>
          <passwordHashAlgorithm>SSHA</passwordHashAlgorithm>
          <autoincrementIdField>false</autoincrementIdField>
          <dataFile>users.csv</dataFile>
          <createTablePolicy>on_missing_columns</createTablePolicy>
          <querySizeLimit>50</querySizeLimit>
    
          <!-- comment <cache* /> tags to disable the cache -->
          <cacheEntryName>user-entry-cache</cacheEntryName>
          <cacheEntryWithoutReferencesName>user-entry-cache-without-references</cacheEntryWithoutReferencesName>
    
          <references>
            <inverseReference directory="groupDirectory" dualReferenceField="members" field="groups"/>
          </references>
    
        </directory>
  • <directory extends="template-group" name="groupDirectory">
    
          <schema>group</schema>
          <types>
            <type>system</type>
          </types>
          <idField>groupname</idField>
          <dataFile>groups.csv</dataFile>
          <createTablePolicy>on_missing_columns</createTablePolicy>
          <autoincrementIdField>false</autoincrementIdField>
    
          <!-- comment <cache* /> tags to disable the cache -->
          <cacheEntryName>group-entry-cache</cacheEntryName>
          <cacheEntryWithoutReferencesName>group-entry-cache-without-references</cacheEntryWithoutReferencesName>
    
          <references>
            <reference dataFile="user2group.csv" directory="userDirectory" field="members" name="user2group" source="groupId" target="userId"/>
            <!-- Warning ! From Nuxeo 5.3.1, a wrong setting has been fixed. See
            http://jira.nuxeo.org/browse/NXP-4401 . Nuxeo upgrades would need a fix in the
            database (inverting parentGroupId and childGroupId in the group2group)  -->
            <reference directory="groupDirectory" field="subGroups" name="group2group" source="parentGroupId" target="childGroupId"/>
            <inverseReference directory="groupDirectory" dualReferenceField="subGroups" field="parentGroups"/>
          </references>
    
        </directory>
  • <directory extends="template-directory" name="digestauth">
          <schema>digestauth</schema>
          <idField>username</idField>
          <passwordField>password</passwordField>
          <types>
            <type>system</type>
          </types>
          <cacheEntryName>digestauth-entry-cache</cacheEntryName>
          <cacheEntryWithoutReferencesName>digestauth-entry-cache-without-references</cacheEntryWithoutReferencesName>
        </directory>

XML Source

<extension point="directories" target="org.nuxeo.ecm.directory.GenericDirectory">

    <directory extends="template-user" name="userDirectory">

      <schema>user</schema>

      <types>
        <type>system</type>
      </types>

      <idField>username</idField>
      <passwordField>password</passwordField>
      <passwordHashAlgorithm>SSHA</passwordHashAlgorithm>
      <autoincrementIdField>false</autoincrementIdField>
      <dataFile>users.csv</dataFile>
      <createTablePolicy>on_missing_columns</createTablePolicy>
      <querySizeLimit>50</querySizeLimit>

      <!-- comment <cache* /> tags to disable the cache -->
      <cacheEntryName>user-entry-cache</cacheEntryName>
      <cacheEntryWithoutReferencesName>user-entry-cache-without-references</cacheEntryWithoutReferencesName>

      <references>
        <inverseReference directory="groupDirectory" dualReferenceField="members" field="groups"/>
      </references>

    </directory>

    <directory extends="template-group" name="groupDirectory">

      <schema>group</schema>
      <types>
        <type>system</type>
      </types>
      <idField>groupname</idField>
      <dataFile>groups.csv</dataFile>
      <createTablePolicy>on_missing_columns</createTablePolicy>
      <autoincrementIdField>false</autoincrementIdField>

      <!-- comment <cache* /> tags to disable the cache -->
      <cacheEntryName>group-entry-cache</cacheEntryName>
      <cacheEntryWithoutReferencesName>group-entry-cache-without-references</cacheEntryWithoutReferencesName>

      <references>
        <reference dataFile="user2group.csv" directory="userDirectory" field="members" name="user2group" source="groupId" target="userId"/>
        <!-- Warning ! From Nuxeo 5.3.1, a wrong setting has been fixed. See
        http://jira.nuxeo.org/browse/NXP-4401 . Nuxeo upgrades would need a fix in the
        database (inverting parentGroupId and childGroupId in the group2group)  -->
        <reference directory="groupDirectory" field="subGroups" name="group2group" source="parentGroupId" target="childGroupId"/>
        <inverseReference directory="groupDirectory" dualReferenceField="subGroups" field="parentGroups"/>
      </references>

    </directory>

    <directory extends="template-directory" name="digestauth">
      <schema>digestauth</schema>
      <idField>username</idField>
      <passwordField>password</passwordField>
      <types>
        <type>system</type>
      </types>
      <cacheEntryName>digestauth-entry-cache</cacheEntryName>
      <cacheEntryWithoutReferencesName>digestauth-entry-cache-without-references</cacheEntryWithoutReferencesName>
    </directory>

  </extension>