[PATCH v2 4/6] docs: Add events to usage guide

Stephen Finucane stephen at that.guru
Tue Jan 31 10:04:12 AEDT 2017


Signed-off-by: Stephen Finucane <stephen at that.guru>
---
 docs/usage/overview.md | 115 +++++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 115 insertions(+)

diff --git a/docs/usage/overview.md b/docs/usage/overview.md
index af72092..6be673b 100644
--- a/docs/usage/overview.md
+++ b/docs/usage/overview.md
@@ -178,6 +178,121 @@ for merge to the tree.
 
 Patchwork users can store a TODO list of patches.
 
+## Events
+
+Events are raised whenever patches are created or modified.
+
+All events have a number of common properties, along with some event-specific
+properties:
+
+<dl>
+    <dt>category</dt>
+    <dd>The type of event</dd>
+    <dt>project<dt>
+    <dd>The project this event belongs to</dd>
+    <dt>date</dt>
+    <dd>When this event was created</dd>
+</dl>
+
+**NOTE:** Checks can only be created and read through the Patchwork APIs. Refer
+to the [API documentation][doc-api] for more information.
+
+### Patch Created
+
+Sent when a patch is created.
+
+<dl>
+    <dt>category</dt>
+    <dd><code>patch-created</code></dd>
+    <dt>patch<dt>
+    <dd>Created patch</dd>
+</dl>
+
+### Patch Dependencies Met
+
+Sent when a patch in a series has its dependencies met.
+
+<dl>
+    <dt>category</dt>
+    <dd><code>patch-dependencies-met</code></dd>
+    <dt>patch<dt>
+    <dd>Affected patch</dd>
+</dl>
+
+### Patch Delegate Changed
+
+Sent when a patch's delegate is changed.
+
+<dl>
+    <dt>category</dt>
+    <dd><code>delegate-changed</code></dd>
+    <dt>patch<dt>
+    <dd>Affected patch</dd>
+    <dt>previous</dt>
+    <dd>Previous delegate, if any</dd>
+    <dt>current</dt>
+    <dd>Current delegate, if any</dd>
+</dl>
+
+### Patch State Changed
+
+Sent when a patch's state is changed.
+
+<dl>
+    <dt>category</dt>
+    <dd><code>state-changed</code></dd>
+    <dt>patch<dt>
+    <dd>Affected patch</dd>
+    <dt>previous</dt>
+    <dd>Previous state</dd>
+    <dt>current</dt>
+    <dd>Current state</dd>
+</dl>
+
+### Cover Letter Created
+
+Sent when a cover letter is created.
+
+<dl>
+    <dt>category</dt>
+    <dd><code>cover-letter-created</code></dd>
+    <dt>cover<dt>
+    <dd>Created cover letter</dd>
+</dl>
+
+### Series Created
+
+Sent when a series is created.
+
+<dl>
+    <dt>category</dt>
+    <dd><code>series-created</code></dd>
+    <dt>series<dt>
+    <dd>Created series</dd>
+</dl>
+
+### Check Created
+
+Sent when a patch check is created.
+
+<dl>
+    <dt>category</dt>
+    <dd><code>check-created</code></dd>
+    <dt>check<dt>
+    <dd>Created check</dd>
+</dl>
+
+### What's Not Exposed
+
+* Bundles
+
+  We don't expose an "added to bundle" event as it's unlikely that this will
+  be useful to either users or CI setters.
+
+* Comments
+
+  Like Bundles, there likely isn't much value in exposing these via the API.
+
 [doc-api]: rest.md
 [doc-autodelegation]: delegation.md
 [ref-kernel-submission]: https://www.kernel.org/doc/Documentation/SubmittingPatches
-- 
2.9.3



More information about the Patchwork mailing list