Space Cloud stores the event logs related to Event Triggers in the event_logs
table/collection. If there are lots of events, the event_logs
table can get huge, and you may want to prune them. You can use any of the following options to prune your event logs depending on your need.
Note: You can even change the table and database where Space Cloud stores its event logs from the
Configure
section.
The event_logs
table managed by Space Cloud has the following structure:
Field | Type | Description |
---|---|---|
_id |
String | Unique identifier of an event. |
batchid |
Number | Unique identifier of a batch of an event. Used for internal Space Cloud events. |
type |
Number | Event type |
token |
String | Authorization token |
timestamp |
Number | Timestamp of when the event should get executed. |
event_ts |
String | DateTime string specifying when the event was queued. |
payload |
String | Event data stringified. |
status |
String | Status of event - staged , processed or failed . |
retries |
Number | Number of retries performed. |
url |
String | Webhook URL. |
remark |
String | Reason of failure. |
DELETE from event_logs where status = "failed";
db.event_logs.remove({ status: "failed" })
DELETE from event_logs where status = "processed";
db.event_logs.remove({ status: "processed" })
DELETE from event_logs where status = "failed" or status = "processed";
db.event_logs.remove({ status: { $in: ["failed", "processed"]} })