barrel_rep_filter (barrel_docdb v1.0.0)
View SourceWire codec for replication filters (paths, query, channel).
Query conditions are Erlang tuples; on the wire they become tagged JSON arrays whitelisted 1:1 against the engine forms, e.g. ["path", ["type"], "user"] or ["compare", ["rank"], ">", 3]. Decoding uses explicit clauses only: no atoms are created from wire input, unknown tags reject with {bad_filter, _}. The one lossy spot: the wildcard path component `*'' rides as the string "*" (a doc field literally named "*" cannot be addressed through a wire filter).
The same codec serializes filters for replication-task persistence.