About This Page
This page is part of the Azure documentation. It contains code examples and configuration instructions for working with Azure services.
Bias Analysis
Bias Types:
⚠️
windows_first
⚠️
powershell_heavy
⚠️
windows_tools
Summary:
The documentation page shows some Windows bias in the .NET/C# section: Windows/PowerShell/ETW instructions are presented before Linux/dotnet-trace instructions, and the Windows workflow is described in more detail, including specific PowerShell scripts and links to Windows-specific tools. There is also a focus on Event Tracing for Windows (ETW) and PowerShell, which are not cross-platform. Other language sections (Java, Python, Node.js, Embedded C) are generally OS-neutral or provide examples that work on both Windows and Linux.
Recommendations:
- Present Linux and Windows instructions in parallel or in a more balanced order (e.g., 'On Windows' and 'On Linux' subsections, or a table).
- Ensure equal detail and prominence for Linux tooling (e.g., provide as much explanation for dotnet-trace as for ETW/PowerShell).
- Where possible, mention cross-platform tools first, or highlight them as preferred for portability.
- Add explicit notes about how to perform similar actions on macOS, if supported.
- Avoid assuming PowerShell or ETW are the default or primary mechanisms; clarify their OS specificity.
- Where Windows file paths or conventions are shown (e.g., in Java logging config), provide Linux equivalents or note differences.
Create pull request
Flagged Code Snippets
.\iot_stoplog.ps1 -TraceName IotTrace
.\iot_startlog.ps1 -Output iot.etl -ProviderFile .\iot_providers.txt -TraceName IotTrace
#include <azure/core/az_log.h>
...
static void write_log_message(az_log_classification, az_span);
...
int main(void)
{
az_log_set_message_callback(write_log_message);
...
}
static void write_log_message(az_log_classification classification, az_span message)
{
(void)classification;
printf("TRACE:\t\t%.*s\n", az_span_size(message), az_span_ptr(message));
}
status = error
name = Log4j2PropertiesConfig
# Log file location - choose a suitable path for your OS
property.filePath = c/temp/logs
appenders = console,file
appender.console.type = Console
appender.console.name = LogToConsole
appender.console.layout.type = PatternLayout
appender.console.layout.pattern = %d %p (%t) [%c] - %m%n
appender.file.type = File
appender.file.name = LogToFile
appender.file.fileName = ${filePath}/device.log
appender.file.layout.type = PatternLayout
appender.file.layout.pattern = %d %p (%t) [%c] - %m%n
loggers.file
logger.file.name = com.microsoft.azure.sdk.iot
logger.file.level = debug
logger.file.appenderRefs = logfile
logger.file.appenderRef.logfile.ref = LogToFile
rootLogger.level = debug
rootLogger.appenderRefs = stdout
rootLogger.appenderRef.stdout.ref = LogToConsole