history command selects all changes inside a graph based on the given criteria.
Whenever changes are detected by Resoto, a dedicated change event is written as separate entity. Following changes are supported:
node_created: a node is added to the graph that has not been seen before.
node_updated: a node is delivered and is different to the one in the graph.
node_deleted: a node is no longer reported and gets deleted from the graph.
history [--before <timestamp>] [--after <timestamp>] [--change <change>] [search-statement]
|Search filter statement to filter the list of changes.||❌|
|Only include changes before the ISO 8601 timestamp||❌|
|Only include changes after the ISO 8601 timestamp||❌|
|Filter changes by type||❌|
> history --after 2022-01-01T03:00:
change=node_updated, changed_at=2022-01-01T03:00:59Z, kind=kubernetes_config_map, id=73616434 name=leader, cloud=k8s
change=node_deleted, changed_at=2022-01-01T04:40:59Z, kind=aws_vpc, id=vpc-1, name=resoto-eks, cloud=aws
> history --change node_created --after 2022-01-01T03:00:00Z --before 2022-01-02T06:00:00Z
change=node_created, changed_at=2022-01-01T05:40:59Z, kind=aws_iam_role, id=AROA, name=some-role, cloud=aws
> history is(kubernetes_resource) and namespace=kube-system
change=node_created, changed_at=2022-11-18T12:00:49Z, kind=kubernetes_role, name=eks, namespace=kube-system
change=node_updated, changed_at=2022-11-18T12:00:50Z, kind=kubernetes_config_map, name=cert, namespace=kube-system
The event history is only kept for a limited amount of time. The default retention time is 14 days. All changes that are older than that time are deleted from the database.