-
Notifications
You must be signed in to change notification settings - Fork 4
Description
Specification
The Audit domain was added to the Polykey library and is being used for the polykey website dashboard. But we haven't yet exposed it to the CLI. It will be useful for auditing connection and discovery events. But also any other types of events when they are added into the audit domain.
The audit command will be generic to handling all kinds of audit events. Event types to iterate over will be selected by the event path. We should allow the ability to specify multiple paths as a varidic in a dot path format of a.b.c. It will be possible to specify a subpath, parent path or duplicate paths at the same time so we'll need to trim the list to the minimal relevant paths. A union of a duplicate is the same path, A union of a child and parent path is just the parent path.
When iterating over the multiple paths we're going to use a iterator zipper method. Where each path has it's own iterator. Each select from each iterator to be read from based on the strict ordering of the AuditEventId which is a monotonic logical ordering based on time.
Further features and formatting needs to be specced out.
Additional context
- Related: Discovery background processing feedback #162 - Started creating the audit domain but that work is being split to a new PR.
Tasks
- expand this spec.