[clouchdb-cvs] CVS clouchdb/src

peddy peddy at common-lisp.net
Fri Jul 17 00:26:32 UTC 2009


Update of /project/clouchdb/cvsroot/clouchdb/src
In directory cl-net:/tmp/cvs-serv23604/src

Modified Files:
	tests.lisp package.lisp clouchdb.lisp clouchdb.asd 
	changelog.txt 
Log Message:
Added get-uuids function, doc for it, and incremented *couchdb-version*


--- /project/clouchdb/cvsroot/clouchdb/src/tests.lisp	2009/07/15 02:22:59	1.24
+++ /project/clouchdb/cvsroot/clouchdb/src/tests.lisp	2009/07/17 00:26:31	1.25
@@ -586,6 +586,16 @@
                "http://google.com"))
 
 (addtest (clouchdb-doc-api-tests)
+  (:documentation "Test UUID default function invocation")
+  uuid-default-test
+  (ensure-same 1 (length (document-property :|uuids| (get-uuids)))))
+
+(addtest (clouchdb-doc-api-tests)
+  (:documentation "Test UUID default function invocation")
+  uuid-count-test
+  (ensure-same 3 (length (document-property :|uuids| (get-uuids :count 3)))))
+
+(addtest (clouchdb-doc-api-tests)
   (:documentation "Test encoding and decoding of utf-8 document IDs")
   encode-document-utf-8-ids
   (ensure 
--- /project/clouchdb/cvsroot/clouchdb/src/package.lisp	2009/07/15 02:22:59	1.15
+++ /project/clouchdb/cvsroot/clouchdb/src/package.lisp	2009/07/17 00:26:32	1.16
@@ -77,6 +77,7 @@
    :get-couchdb-info
    :get-db-info
    :get-document
+   :get-uuids
    :id-missing
    :id-or-revision-conflict
    :illegal-database-name
--- /project/clouchdb/cvsroot/clouchdb/src/clouchdb.lisp	2009/07/15 02:22:59	1.41
+++ /project/clouchdb/cvsroot/clouchdb/src/clouchdb.lisp	2009/07/17 00:26:32	1.42
@@ -644,6 +644,13 @@
 ;; CouchDB Document Management API
 ;;
 
+(defun get-uuids (&key (count 1))
+  "Returns one or more new UUID from the current database."
+  (values (db-request "_uuids" 
+                     :parameters 
+                     (list (cons "count" (value-as-string count)))
+                     :method :get)))
+
 (defun get-all-documents (&rest options &key key keys start-key
                         start-key-docid end-key end-key-docid limit
                         stale descending skip group group-level reduce
--- /project/clouchdb/cvsroot/clouchdb/src/clouchdb.asd	2009/06/06 17:56:25	1.7
+++ /project/clouchdb/cvsroot/clouchdb/src/clouchdb.asd	2009/07/17 00:26:32	1.8
@@ -29,7 +29,7 @@
 
 (in-package :clouchdb-asd)
 
-(defvar *clouchdb-version* "0.0.2"
+(defvar *clouchdb-version* "0.0.12"
   "The current version of clouchdb")
 
 (export '*clouchdb-version*)
--- /project/clouchdb/cvsroot/clouchdb/src/changelog.txt	2009/07/15 02:22:59	1.12
+++ /project/clouchdb/cvsroot/clouchdb/src/changelog.txt	2009/07/17 00:26:32	1.13
@@ -2,6 +2,8 @@
 0.0.12: 
   - Added missing conflicts keyword parameter to get-document, tests
   - Added error handling in create-db for illegal database names
+  - Added get-uuids function and related doc
+  - Remembered to increment *couchdb-version* for the first time in a long time
 
 0.0.11:
 





More information about the clouchdb-cvs mailing list