incubator-couchdb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Max Ogden <...@maxogden.com>
Subject Re: Update the document without current version
Date Thu, 13 Oct 2011 07:59:07 GMT
Hi Alexander,

I think that the reason that force_update/delete_conflicts doesn't exist is
because it's assumed that since HTTP is a stateless protocol that
applications built using Couch will keep state on the client. For instance,
if you update a document Couch will hand you back the new revision so you
don't have to fetch it separately.

In your case you seem to be somehow replacing documents without first
knowing about them, which seems weird to me. Can you shed some more light on
what application level features depend on the force_update/delete_conflicts
API?

Max

On Thu, Oct 13, 2011 at 12:26 AM, Alexander Uvarov <
alexander.uvarov@gmail.com> wrote:

> I would prefer a parameter like "force_update=true" and
> "delete_conflicts=true" to purge all existing versions and conflicts and
> just save new one. Would be useful for cases when user need to overwrite
> existing versions or when conflicts are resolved. Thoughts?
>
> On Oct 13, 2011, at 1:14 PM, Michael Zedeler wrote:
>
> > On 2011-10-13 00:58, Panop Suvaphrom wrote:
> >> I know that it is not possible to update the document without current
> version.
> >>
> >> But anyway, I would like to make sure about this.
> >> Is there a way to update a document without knowing its current
> revision?
> >> I would like to avoid first GETting current version…
> > Did you look at CouchDB document update handlers?
> > --
> > Michael Zedeler
> > 70 25 19 99 | LinkedIn <http://dk.linkedin.com/in/mzedeler> | Twitter <
> http://twitter.com/#%21/mzedeler> | Github <https://github.com/mzedeler>
>
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message