Uploaded image for project: 'Nuxeo Platform'
  1. Nuxeo Platform
  2. NXP-19175

Generic Directory and directory templating

    XMLWordPrintable

    Details

    • Type: New Feature
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 8.2
    • Component/s: Directory
    • Upgrade notes:
      Hide

      Generic Directories have been introduced, along with the possibility to make regular directories be "templates".

      First, register a template directory (template="true"):

      <extension target="org.nuxeo.ecm.directory.sql.SQLDirectoryFactory" point="directories">
      <directory name="template-dir" template="true">
      <dataSource>java:/nxsqldirectory</dataSource>
      <createTablePolicy>always</createTablePolicy>
      <querySizeLimit>100</querySizeLimit>
      </directory>
      </extension>

      Then use a generic directory to provide specific customizations over the extended template (extends="template-dir"):

      <extension target="org.nuxeo.ecm.directory.GenericDirectory" point="directories">
      <directory name="my-directory" extends="template-dir">
      <schema>myschema</schema>
      <table>mytable</table>
      <idField>id</idField>
      <passwordField>password</passwordField>
      <passwordHashAlgorithm>SSHA</passwordHashAlgorithm>
      <substringMatchType>subany</substringMatchType>
      <cacheTimeout>3600</cacheTimeout>
      <cacheMaxSize>1000</cacheMaxSize>
      </directory>
      </extension>

      The Generic Directory descriptor only supports a generic subset of the configuration of the directories in general (see org.nuxeo.ecm.directory.BaseDirectoryDescriptor for the exact fields).

      Show
      Generic Directories have been introduced, along with the possibility to make regular directories be "templates". First, register a template directory (template="true"): <extension target="org.nuxeo.ecm.directory.sql.SQLDirectoryFactory" point="directories"> <directory name="template-dir" template="true"> <dataSource>java:/nxsqldirectory</dataSource> <createTablePolicy>always</createTablePolicy> <querySizeLimit>100</querySizeLimit> </directory> </extension> Then use a generic directory to provide specific customizations over the extended template (extends="template-dir"): <extension target="org.nuxeo.ecm.directory.GenericDirectory" point="directories"> <directory name="my-directory" extends="template-dir"> <schema>myschema</schema> <table>mytable</table> <idField>id</idField> <passwordField>password</passwordField> <passwordHashAlgorithm>SSHA</passwordHashAlgorithm> <substringMatchType>subany</substringMatchType> <cacheTimeout>3600</cacheTimeout> <cacheMaxSize>1000</cacheMaxSize> </directory> </extension> The Generic Directory descriptor only supports a generic subset of the configuration of the directories in general (see org.nuxeo.ecm.directory.BaseDirectoryDescriptor for the exact fields).
    • Sprint:
      nxFG 8.2.1
    • Story Points:
      5

      Description

      We want to be able to define a generic directory (name, "table", schema, id fields etc.) whose actual implementation (SQL, LDAP, ...) is delegated to a centrally defined template.

      This will allow redefining with one change a whole set of directories in the platform (for example, all vocabularies). This is important in order to be able to switch easily the backend storage of all directories, for instance from SQL to MongoDB

        Attachments

          Issue Links

            Activity

              People

              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: