← 返回 perplexity 的题目列表Log Processing (Parsing & Aggregation)
类型:online_judge
Log Processing (Parsing & Aggregation)
You are given line-based text logs. Each line contains multiple fields (e.g., timestamp, request id, user id, event type, status code, latency). You must parse, clean, and compute the required aggregations or output filtered records.
Typical tasks (the interviewer will specify)
Per-user/per-endpoint success rate, P95/P99 latency, error counts
Identify endpoints/users with the highest failure rates
Time-windowed aggregations (per minute / per 5 minutes)
Group by trace/request id and output anomalous flows
Input/Output
Input: multiple log lines (some may be malformed).
Output: aggregated results (map/table/sorted list/printed report).
Constraints
Explain handling of malformed lines, missing fields, out-of-order events, and large scale (streaming vs in-memory).
Note: Original details are missing; this is the interview-pattern summary.