Thank you Jan & ermouth for the fast replies.

Thought it's a feature I shouldn't rely to solve the issue.

I found a more obvious solution to prevent unintended edits: vdu checks
whether the current _rev is repeated in the doc as a validation token.
At least it prevents mindless editing via the admin interface, that's good
enough for my case.

regards,
Stefan Klein

Am Mi., 26. Mai 2021 um 11:02 Uhr schrieb ermouth <[email protected]>:

> > Or can I?
>
> You better not unless you clearly understand how it works and what it
> depends on. However if you do, this bizzare feature can be invaluable for
> ie a sort of volatile cache, or (with a certain config) for altering params
> of a running filtered replication.
>
> Anyway, those tricks are very far from being conventional: they are nice to
> play with, but are no good for production.
>
> ermouth
>
>
> ср, 26 мая 2021 г. в 11:17, Stefan Klein <[email protected]>:
>
> > Hi all,
> >
> > i'm trying to prevent unintended changes to some documents.
> >
> > While toying around with update & validate_doc_update functions, I found
> > that, if i add a property to the `this` context of an update function,
> the
> > `this` context of the validate_doc_update running after the update
> contains
> > that property.
> >
> > If I understand the couchdb & query server architecture correct I can not
> > rely on this behavior. Or can I?
> >
> > Thanks & regards,
> > Stefan Klein
> >
>

Reply via email to