Skip to content

Is there support for creating partitioned databases? #60

@davidgeary

Description

@davidgeary

I need to create a partitioned database, with the structure being defined using the 'CouchDB Filesystem Mapping'. I can't find any specific documentation showing an example of how this would be represented, but my guess has been to create a file in the folder representing the database called partitioned containing the value true (following the example in https://github.com/jo/couchdb-compile/tree/main/test/fixtures/full for specifying the language property).

However, if I then run couchdb-bootstrap via the CLI, I get:

C:\Dvt\devops\node_modules\couchdb-bootstrap\index.js:130
              if (!('_id' in doc)) doc._id = id
                          ^

TypeError: Cannot use 'in' operator to search for '_id' in true
    at C:\Dvt\devops\node_modules\couchdb-bootstrap\index.js:130:27
    at Array.reduce (<anonymous>)
    at C:\Dvt\devops\node_modules\couchdb-bootstrap\index.js:103:14
    at C:\Dvt\devops\node_modules\async\dist\async.js:243:13
    at eachOfArrayLike (C:\Dvt\devops\node_modules\async\dist\async.js:500:13)
    at eachOf (C:\Dvt\devops\node_modules\async\dist\async.js:551:16)
    at awaitable (C:\Dvt\devops\node_modules\async\dist\async.js:208:32)
    at _asyncMap (C:\Dvt\devops\node_modules\async\dist\async.js:241:16)
    at Object.map (C:\Dvt\devops\node_modules\async\dist\async.js:594:16)
    at Object.awaitable [as map] (C:\Dvt\devops\node_modules\async\dist\async.js:208:32)

So it looks like it's trying to interpret the file contents as a JSON document, rather than a property value.

Does couchdb-bootstrap (15.0.0) support creating partitioned databases and if so, what is the required file/folder structure to represent that?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions