Azure / Azure/azure-functions-host
Logs missed due to length
- Dominant language
- C#
- Stars
- 2k
- Forks
- 482
- Avg merge
- 2d 12h
- Merged PRs (30d)
- 38
Description
I believe Kusto logging has length constraints such that if you try to log too large a string, the log won't show. For example, in some investigations, I see the log message written [here](https://github.com/Azure/azure-functions-host/blob/7c6ae82f215282c3d936cf9bb21b897d971933a0/src/WebJobs.Script.WebHost/Management/FunctionsSyncManager.cs#L566) isn't written, while the following "SyncTriggers call succeeded." log is.
We should break the log up to ensure the important details are logged - perhaps log the request URI and details on one line, and the payload on another, truncating as necessary. We can have a helper method to do the log truncation to proper length, so we can reuse elsewhere.
I believe the Kusto length limit for a column is 10,244.
Contributor guide
Research direction
Start at src/WebJobs.Script.WebHost/Management/FunctionsSyncManager.cs around line 566 and inspect the log that is missing while "SyncTriggers call succeeded." appears. Confirm the Kusto length constraint and trace how the request URI, details, and payload are logged; done means the important details remain visible for oversized messages, with truncation or separate log lines as described.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- csharp
- Domain
- observability
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 52/100