How is your experience with the OutSystems Community?
AzureInsightsConnector

AzureInsightsConnector (ODC)

Stable version 0.2.0 (Compatible with ODC)
Uploaded on 29 Sep by Xeridia
AzureInsightsConnector

AzureInsightsConnector (ODC)

Details
Detailed Description

Azure Insights Connector configures a TelemetryClient using a connection string, logs messages at different severity levels, and manages errors. Designed for seamless integration with ODC, it provides real-time monitoring and performance tracking.


Azure Application Insights is a monitoring service provided by Microsoft Azure. Its primary purpose is to help developers track, analyze, and diagnose the performance and usage of their applications, whether they are hosted in Azure, on-premises, or in other cloud environments.

Release notes 

What's new


New actions

- LogTrace: log traces with custom properties (customDimensions), correlation context, custom timestamp and sampling.

- TrackEvent: track business events (customEvents) with properties and numeric measurements.

- TrackException: track handled exceptions (exceptions) with type, message, stack trace and severity.

- TrackMetric: track custom metric values (customMetrics).

- TrackDependency: track calls to external APIs, databases or services (dependencies) with duration, result code and success.

- TrackBatch: send traces, events, exceptions, metrics and dependencies together in a single call (up to 1,000 items in total). Much faster than calling the individual actions in a loop. Each item can have its own timestamp and properties. If any item is invalid, nothing is sent and the error message tells you which list and position failed.


New structures

- TelemetryProperty (Key, Value): custom metadata that you can query in KQL as customDimensions.

- TelemetryMetric (Name, Value): numeric measurements for events.

- TelemetryContext: OperationId, ParentId, OperationName, UserId, SessionId, CloudRoleName and AppVersion. Use it to correlate all telemetry of the same flow and to show your app in the Application Map.

- TraceItem, EventItem, ExceptionItem, MetricItem and DependencyItem: the items of each list in TrackBatch.


Optional parameters

- timestamp: record when something actually happened instead of when it was sent.

- samplingPercentage: keep only a share of the telemetry in high-traffic apps. Telemetry with the same OperationId is kept or discarded together, and Application Insights still shows the real volume in its counts. Metrics are never sampled.


Improvements

- Better performance and stability.

- Input validation with clear error messages (missing connection string, invalid severity level, missing required fields).

- Error messages now keep their full context.


Limitations

- ODC limits the total input of any external library action to 5.5 MB, including all parameters, texts and serialization overhead. This mostly affects TrackBatch: 1,000 items with long messages, stack traces or many properties can exceed it, and ODC then rejects the call before it reaches the extension. With large payloads, split the data into several smaller TrackBatch calls (for example, a few hundred items each).

- Application Insights truncates property keys longer than 150 characters and property values longer than 8,192 characters.


Compatibility

- The existing Log action keeps the same signature, so apps that already use it don't need changes.

- Behavior change: Log now returns ok = False with an error message when severityLevel is outside 0-4. Previously such values were silently logged as Information.