Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit9aafb5c

Browse files
CouchDB documentation added
1 parent46d7c11 commit9aafb5c

File tree

1 file changed

+32
-1
lines changed

1 file changed

+32
-1
lines changed

‎README_Notebook.md‎

Lines changed: 32 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,9 +35,40 @@ The notebook should work as a standalone plugin, you just need to put the folder
3535

3636
The Old API was used due to the documentation was more thorought.
3737

38-
#How to use it:
38+
##How to use it:
3939
Click on the create menu button at the left top corner of the creen and create a notebook object.
4040
After you saved it you can start to create new entries, either clicking inside of the drag area or dragging an especific object to a new entry or an entry already created.
4141

4242
Once you have created the snapshot of the object, you can make annotations over it. Also you can create whichever snapshots per entry as you consider,
4343

44+
##CouchDB Persistence storage
45+
46+
Open MCT is packaged along with a few general-purpose plugins among them the CouchDB plugin:
47+
48+
*`openmct.plugins.CouchDB` is an adapter for using CouchDB for persistence
49+
of user-created objects. This is a constructor that takes the URL for the
50+
CouchDB database as a parameter, e.g.
51+
```javascript
52+
openmct.install(openmct.plugins.CouchDB('url-to-your-CouchDB-database'))
53+
```
54+
You can install and host your DB or use services like cloudanthttps://www.ibm.com/cloud/cloudant.com
55+
56+
To manage the DB you can use tools like Fauxton:http://couchdb.apache.org/fauxton-visual-guide/, it commonly comes bundled with CouchDB installation.
57+
58+
To avoid Cross-Origin Resource Sharing (CORS) on remote servers connections please config your CORS settings and add your domain. For instance on Cloudant:
59+
60+
![CORS](https://www.dropbox.com/s/zwtin8zxcx3omev/cors1.png?dl=0)
61+
62+
You have to create a database for the app and then create an user or API Key to grant database permissions for writing/reading it.
63+
64+
![CORS](https://www.dropbox.com/s/do5twl9ksoq2d5y/cors2.png?dl=0)
65+
66+
if you have the LocalStorage plugin enabled you have to remove its call from index.html and replace it for the CouchDB plugin.
67+
68+
After that you have to copy the url of your DB and paste it as an argument of the CouchDB plugin call:
69+
```javascript
70+
openmct.install(openmct.plugins.CouchDB('CouchDB-host/database-name'))
71+
```
72+
73+
Any config issue you can refer to CouchDBhttp://docs.couchdb.org/en/2.1.1/.
74+

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp