Examples: Using the Eventing Service
This page contains examples of how to use the Eventing Service, using the Couchbase Web Console.
Detailed Examples: These tutorial-like guides are ideal for a novice to learn the basics of Eventing, via complete detailed step by step start-to-finish instructions.
Basic KV Handlers: The following Scriptlets are essentially handler only examples, and introduce more use cases. Here we assume the reader has a good understanding of the Eventing System and requires little guidance.
Basic N1QL Handlers: The following Scriptlets demonstrate using N1QL or the Query Service from within an Eventing handler.
Generic Manipulation Handlers The following Scriptlets are more advanced use cases which focus on mutating documents without knowledge of the document’s schema.
Advanced Accessor Handlers: The following Scriptlets demonstrate using Advanced Accessors which allow the use of CAS, ability to set expirations (or TTLs) and the use of distributed atomic counters to increment or decrement counts. Couchbase Server 6.6.1
Binary Document Support: The following Scriptlets demonstrate support for binary documents in Eventing. Only a Function with “language compatibility” of 6.6.2 or above in its settings will pass binary documents to the OnUpdate(doc,meta) handler.
Performance Handlers The following Scriptlets are performance oriented and/or benchmarks.