Push an audit event to the export buffer.
(&self, entry: AuditEntry)
| 81 | |
| 82 | /// Push an audit event to the export buffer. |
| 83 | pub fn push_audit(&self, entry: AuditEntry) { |
| 84 | let mut buf = self.audit_buffer.write().unwrap_or_else(|p| p.into_inner()); |
| 85 | if buf.len() >= self.config.buffer_size { |
| 86 | buf.pop_front(); |
| 87 | } |
| 88 | buf.push_back(entry); |
| 89 | } |
| 90 | |
| 91 | /// Push an auth event to the export buffer. |
| 92 | pub fn push_auth(&self, entry: AuditEntry) { |