Titanium JIRA Archive
Appcelerator Daemon (DAEMON)

[DAEMON-264] Output log messages for specific request

GitHub Issuen/a
Affected Version/sn/a
Fix Version/sn/a
ReporterChris Barber
AssigneeChris Barber


There is no per-request log output. There's a massive log stream accessible via appcd logcat or appcd dump, but they are subject to size limitations and timing. It would be amazing if there was a way to output or write to disk a log messages generated by a single request. However, this task is not straightforward. Given the decoupled architecture of the daemon and its plugins, it's impossible to track log messages without having some sort of request ID. In other words, we can only support this feature with requests coming from WebSocket sessions and not HTTP because the Appc Daemon WebSocket protocol mandates each request have a unique ID. We need to think about how to link that request ID to log messages generated by the request. The log stream is essentially a global object which means there is a single point of entry across the entire daemon. Perhaps it's possible to proxy all log messages per context before they are written to the logger in which we can tag the log messages with the request ID? Its worth noting that ALL logging is performed in the appcd-core. All plugins ship their log messages through the IPC tunnel, so whatever solution works for code running internally in the daemon should also work in plugins.


No comments

JSON Source