nickva commented on pull request #3947: URL: https://github.com/apache/couchdb/pull/3947#issuecomment-1057477904
@lostnet yeah, it might be nice, in general, to have a schema we can export or publish from an endpoint so then Fauxton could use it to validate input. Specifically for the replicator's VDU, an improvement could be to port the BDU (the Erlang VDU) approach from `main`. There we have a single module which both validates and parses the replication job. That reduce duplication, so we don't validate it twice, and, as a bonus, it avoids having to auto-inject the VDU design doc. https://github.com/apache/couchdb/blob/main/src/couch_replicator/src/couch_replicator_parse.erl @rnewson One way we could allow replicated changes and disallow interactive edits is by using `_revisions` field as a heuristic. VDU functions don't get the `replicated_changes | interactive_edit` flag passed in, but in most cases, we could detect the replicated changes by the presence of a `_revisions = {"start":N, "ids: [Rev1, Rev2, ...]}` field. A bit too hackish perhaps? -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
