Implement telemetry system with data collection and reporting
Signed-off-by: Dmitrii <computer@yawaflua.tech> Took 20 minutes
This commit is contained in:
@@ -0,0 +1,19 @@
|
||||
using MongoDB.Bson;
|
||||
|
||||
namespace SpMega.Backend.Persistent.Models.Telemetry;
|
||||
|
||||
public class BackendRequestTelemetryDocument
|
||||
{
|
||||
public ObjectId Id { get; set; }
|
||||
public string RequestId { get; set; } = string.Empty;
|
||||
public string Method { get; set; } = string.Empty;
|
||||
public string Path { get; set; } = string.Empty;
|
||||
public string Scheme { get; set; } = string.Empty;
|
||||
public string Host { get; set; } = string.Empty;
|
||||
public string? ClientIp { get; set; }
|
||||
public string? UserAgent { get; set; }
|
||||
public int StatusCode { get; set; }
|
||||
public long DurationMs { get; set; }
|
||||
public string? UserId { get; set; }
|
||||
public DateTimeOffset Timestamp { get; set; } = DateTimeOffset.UtcNow;
|
||||
}
|
||||
Reference in New Issue
Block a user