couchdb-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Apache Wiki <wikidi...@apache.org>
Subject [Couchdb Wiki] Trivial Update of "HTTP_view_API" by SebastianCohnen
Date Thu, 08 Apr 2010 17:43:55 GMT
Dear Wiki user,

You have subscribed to a wiki page or wiki category on "Couchdb Wiki" for change notification.

The "HTTP_view_API" page has been changed by SebastianCohnen.
The comment on this change is: added syntax-hl, minor changes, cleanup.
http://wiki.apache.org/couchdb/HTTP_view_API?action=diff&rev1=37&rev2=38

--------------------------------------------------

  
  A design document that defines ''all'', ''by_lastname'', and ''total_purchases'' views might
look like this:
  
- {{{
+ {{{#!highlight javascript
  {
    "_id":"_design/company",
    "_rev":"12345",
@@ -154, +154 @@

  curl -X GET http://localhost:5984/databasename/_design/test/_info
  }}}
  will produce something like this:
- {{{
+ {{{#!highlight javascript
  {
      "name": "test", 
      "view_index": {
@@ -193, +193 @@

  
  As of r660140 there is a log function available in the views, which logs to the couch.log.
It can be helpful for debugging but hinders performance, so it should be used sparingly in
production systems.
  
- {{{
+ {{{#!highlight javascript
  {
    "map": "function(doc) { log(doc); }"
  }
@@ -253, +253 @@

  
  Could result in the following response:
  
- {{{
+ {{{#!highlight javascript
  {
    "total_rows": 1,
    "offset": 0,

Mime
View raw message