Ignore:
Timestamp:
01/09/11 20:28:15 (13 years ago)
Author:
vronk
Message:

mainly added new API-function: scanIndex
(group.xsl used for aggregating)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • MDRepository/trunk/xquery/README

    r958 r1045  
    1212        c) set admin pwd
    1313       
    14         ...?
     14        d) you may want to add memory to the JVM
     15           under bin/functions.d/eXist-settings.sh#set_java_options()
     16       
     17        e) you may also want to grow the cache in conf.xml
     18                 <db-connection cacheSize="48M" collectionCache="24M" database="native"       
     19                  where @cacheSize could be around 512M
     20      and @collectionCache should be around one third of the @cacheSize
     21
    1522
    16231. add scripts to: /db/clarin
     
    1825                + cmd-model.xqm has all the logic
    1926                + cmd-model.xql is the script being called as the interface
    20                 + cmd-stats.xql is meant for testing purposes, but not integrated yet
    21                 + init-cache.xql is meant for refreshing the cache with some long-running (resource-intensive) queries, meant to run once upon dataset change
     27         (+) cmd-stats.xql is meant for testing purposes, but not integrated yet
     28         (+) init-cache.xql is meant for refreshing the cache with some long-running (resource-intensive) queries, meant to run once upon dataset change
    2229
    23 2. add data to  /db/cmdi-mirror
    24          (the file-system structure will be reflected in the "collection"-structure within exist,
    25          however this is irrelevant for the MDRepository methods.
    26          Those rely on the linking via handles in MdSelfLink/ResourceRef and IsPartOf elements of the MDRecords.
    27          The handles in IsPartOf are redundant (necessary for faster collection-constraint search)
    28          and can be derived from the ResourceRef/MdSelfLink link.
    29          This can be done before storing the data in the repository,
    30          or after the import directly in the repository (scripts for this will be available soon)
    3130
    32 3. add a clarin-user in /db/system/users.xml
     312. add a clarin-user in /db/system/users.xml
    3332   (needed for writing into the cache)
    3433   + /db/clarin/writer.xml with given user, like this:
     
    3938
    4039
    41 4. create a collection for caching,
    42         eg: /db/common/clarin/freqs
     403. create a collection for caching,
     41        eg: /db/cache
    4342        this has to correspond to the entry in cmd-model.xqm:
    44         declare variable $cmd-model:commonFreqsPath as xs:string := "/db/common/clarin/freqs";
     43        declare variable $cmd-model:commonFreqsPath as xs:string := "/db/cache";
    4544       
    4645        If you change something, you have to manually clear the cache-collection.
     
    5049          for getCollections: collection{maxdepth}-{hash({collection-handle})}
    5150          for queryModel:   values{maxdepth}-{hash({simple xpath from q-param})}
     51
    5252       
    53 5. depending on your server-setup you should be able to get your first query under somewhere like:             
     534. define indices
     54         copy cmdi-mirror.xconf into /db/system/config/db/cmdi-mirror
     55         
     56         
     575. add data to  /db/cmdi-mirror
     58         (the file-system structure will be reflected in the "collection"-structure within exist,
     59         however this is irrelevant for the MDRepository methods.
     60         Those rely on the linking via handles in MdSelfLink/ResourceRef and <IsPartOf> elements of the MDRecords.
     61         The handles in <IsPartOf> are redundant (necessary for faster collection-constraint search)
     62         and can be derived from the ResourceRef/MdSelfLink link.
     63         This can be done before storing the data in the repository,
     64         or after the import directly in the repository (XUpdate-scripts for this will be available soon)
     65
     66         The top level collection record is by convention called colleciton_root.cmdi
     67         and is marked with: <IsPartOf>root</IsPartOf>
     68         (So every dataset (olac, lrt, imdi) has one such MDRecord.)
     69
     706. depending on your server-setup (port) you should be able to get your first query under somewhere like:               
    5471               
    5572        http://localhost:8680/exist/rest/db/clarin/cmd-model.xql?q=Components
     
    6178        Avoid starting multiple times.
    6279        You can see in the cache-collection, if the results are ready.
    63        
     80
     81
    6482       
    6583== test suite ==
Note: See TracChangeset for help on using the changeset viewer.