Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Fuschia is a graphical document browser for CouchDB

branch: master
README.textile

Overview

Fuschia is a graphical document browser for CouchDB. It’s built on prefuse and Flex. Screenshot.

Using

Clone this repo git clone gitgithub.com:paulcarey/fuschia.git@, then run ./upload_binaries.sh $your_db_name. This will create a design document named fuschia containing views that, for a given document, retrieve all documents that it points to, and all documents that point to it.

Now direct your browser at http://localhost:5984/mydb/_design/fuschia/Fuschia.html, enter a full database uri (e.g. http://localhost:5984/mydb), seed document id and click load. You should be able to browse through your database.

Fushica is at its best when it colors document nodes and displays document summaries. To have this happen, create a document at /mydb/fuschia based on the following example. You can upload it easily with curl, for example, curl -T fuschia.json localhost:5984/mydb/fuschia.


// classProperty is used to distinguish doc types. 
//  For RelaxDB this would be 'class', for CouchRest::Model, 'couchrest-type' etc.
// fillColor represents the document node color. The first two characters specify an alpha value.
// summaryProperty should specify the most descriptive property of the document.
{
  "_id" : "fuschia",
  "classProperty" : "class",
  "User" : {
    "fillColor" : "0xff3355cc",
    "summaryProperty" : "name"
  },
  "Post" : {
    "fillColor" : "0xffcc5533",
    "summaryProperty" : "contents"
  },
  "Comment" : {
    "fillColor" : "0xff33cc55",
    "summaryProperty" : "contents"
  }
}

Note: If your database doesn’t use standard UUIDs, modify isDocId in src/fuschia_queries.js as necessary and overwrite bin/fuschia_queries.json with your own version.

Hacking

The flare tutorial is the best place to get started with flare. If you’re new to CouchDB, the wiki is a great place to begin.

Instructions on developing with flare in textmate.

Quirks

  • prefuse doesn’t support edges with bi-directional arrows, so documents containing mutual references are represented by arrow-free edges.

Example

The example directory contains a script that feeds some sample data into CouchDB using RelaxDB. However, following the instructions in the ‘Using’ section above, you should be able to explore any CouchDB database that contains inter-document references.

Something went wrong with that request. Please try again.