Bearbeiten

Freigeben über


Analyzing Extension Upload Validation Telemetry

APPLIES TO: Business Central online

Note

Azure Active Directory is now Microsoft Entra ID. Learn more

In the Business Central service, when a user/administrator uploads a per-tenant extension to an environment from the Extension Management page, we proactively validate it against the environment.

With this telemetry, partners can monitor these attempts for customers and setup alerts on failures so that they know up-front which customers will need help.

Failed operations result in a trace log entry that includes a reason for the failure.

The validation flow is as follows:

The PTE submission validation flow is as follows:

PTE submission validation request started (LC0200). This includes the main extension to be validated and a list of extensions it depends on.
For each extension (main + dependent extensions)
        Extension validation started (LC0204)

        Either 
                Extension validation completed successfully (LC0205)
        or
                Validation diagnostic reported (LC0210)
                Extension validation completed with failures (LC0206)

Then either 
        PTE submission validation request completed successfully (LC0202)
or
        PTE submission validation request completed with failures (LC0203)

Per-tenant extension (PTE) validation started (LC0200)

Occurs when a new per-tenant extension (PTE) validation attempt is started on the environment.

General dimensions

Dimension Description or value
message PTE validation started: request {submissionId}

{submissionId} indicates the identifier for the validation attempt.

Custom dimensions

Dimension Description or value
eventId LC0200
environmentId

Note

Azure Active Directory is now Microsoft Entra ID. Learn more

Specifies the Microsoft Entra tenant ID used for Microsoft Entra authentication. For on-premises, if you aren't using Microsoft Entra authentication, this value is common.
environmentName Specifies the name of the tenant environment. Learn more in Managing Environments.
environmentType Specifies the environment type for the tenant, such as Production or Sandbox. Learn more in Environment Types.
mainExtension A json structure that contains information about the extension that is being uploaded.
submissionOperationId A unique identifier (GUID) for the validation attempt.

Extension validation started (LC0204)

Occurs for each extension in the upload.

General dimensions

Dimension Description or value
message Extension validation started: extension {extensionName} version {extensionVersion} by {extensionPublisher} ({extensionId})

{extensionName} indicates the name of the extension.

{extensionVersion} indicates the version of the extension.

{extensionPublisher} indicates the publisher of the extension.

{extensionId} indicates the id of the extension.

Custom dimensions

Dimension Description or value
eventId LC0204
environmentId

Note

Azure Active Directory is now Microsoft Entra ID. Learn more

Specifies the Microsoft Entra tenant ID used for Microsoft Entra authentication. For on-premises, if you aren't using Microsoft Entra authentication, this value is common.
environmentName Specifies the name of the tenant environment. Learn more in Managing Environments.
environmentType Specifies the environment type for the tenant, such as Production or Sandbox. Learn more in Environment Types.
extensionName Specifies the name of the extension that was to be validated.
extensionId Specifies the ID of the extension/app.
extensionPublisher Specifies the publisher of the extension/app.
extensionVersion Specifies the version of the extension.
submissionOperationId A unique identifier (GUID) for the validation attempt.

Extension validation completed successfully (LC0205)

Occurs if the extension can compile against the environment.

General dimensions

Dimension Description or value
message Extension validation completed successfully: extension {extensionName} version {extensionVersion} by {extensionPublisher} ({extensionId})

{extensionName} indicates the name of the extension.

{extensionVersion} indicates the version of the extension.

{extensionPublisher} indicates the publisher of the extension.

{extensionId} indicates the id of the extension.

Custom dimensions

Dimension Description or value
eventId LC0205
environmentId

Note

Azure Active Directory is now Microsoft Entra ID. Learn more

Specifies the Microsoft Entra tenant ID used for Microsoft Entra authentication. For on-premises, if you aren't using Microsoft Entra authentication, this value is common.
environmentName Specifies the name of the tenant environment. Learn more in Managing Environments.
environmentType Specifies the environment type for the tenant, such as Production or Sandbox. Learn more in Environment Types.
extensionName Specifies the name of the extension that was to be validated.
extensionId Specifies the ID of the extension/app.
extensionPublisher Specifies the publisher of the extension/app.
extensionVersion Specifies the version of the extension.
submissionOperationId A unique identifier (GUID) for the validation attempt.

Extension Validation diagnostic reported (LC0210)

Occurs if something was not right when validating the extension on the environment.

General dimensions

Dimension Description or value
message Validation diagnostic reported: extension {extensionName} version {extensionVersion} by {extensionPublisher} ({extensionId})

{extensionName} indicates the name of the extension.

{extensionVersion} indicates the version of the extension.

{extensionPublisher} indicates the publisher of the extension.

{extensionId} indicates the id of the extension.

Custom dimensions

Dimension Description or value
eventId LC0210
environmentId

Note

Azure Active Directory is now Microsoft Entra ID. Learn more

Specifies the Microsoft Entra tenant ID used for Microsoft Entra authentication. For on-premises, if you aren't using Microsoft Entra authentication, this value is common.
environmentName Specifies the name of the tenant environment. Learn more in Managing Environments.
environmentType Specifies the environment type for the tenant, such as Production or Sandbox. Learn more in Environment Types.
extensionName Specifies the name of the extension that was to be validated.
extensionId Specifies the ID of the extension/app.
extensionPublisher Specifies the publisher of the extension/app.
extensionVersion Specifies the version of the extension.
diagnosticCode Specifies a diagnostics code emitted by the AL compiler. For more information, see AL compiler diagnostics
diagnosticMessage Specifies a diagnostics message emitted by the AL compiler.
diagnosticSeverity Specifies the severity of diagnostics message emitted by the AL compiler, such as Error or Warning.
diagnosticSourceLocation Specifies where in the app code the AL compiler emitted the diagnostics.
diagnosticSourcePath Specifies where in a file in the app the AL compiler emitted the diagnostics.
submissionOperationId The operation ID for the validation submission of the app.

Sample KQL code (Extension Validation diagnostic reported)

This KQL code can help you get started analyzing validation failures for an extension/app:

// Extension Validation diagnostic reported (LC0210)
traces 
| where customDimensions has "LC0210"
| where customDimensions.eventId == "LC0210"
| where timestamp > ago(30d) // adjust as needed
| project timestamp
// which environment is being validated
, aadTenantId = customDimensions.environmentId
, environmentName = customDimensions.environmentName
, environmentType = customDimensions.environmentType 
// which extension/app is being validated
, extensionId = customDimensions.extensionId
, extensionPublisher = customDimensions.extensionPublisher
, extensionVersion = customDimensions.extensionVersion
, extensionName = customDimensions.extensionName
, mainExtension = customDimensions.mainExtension 
// validation info
, diagnosticSourceLocation = customDimensions.diagnosticSourceLocation
, diagnosticMessage = customDimensions.diagnosticMessage
, diagnosticSourcePath = customDimensions.diagnosticSourcePath
, diagnosticCode = customDimensions.diagnosticCode
, diagnosticSeverity = customDimensions.diagnosticSeverity
, submissionOperationId = customDimensions.submissionOperationId

Extension validation completed completed with failures (LC0206)

Occurs if the extension could not compile against the environment.

General dimensions

Dimension Description or value
message Extension validation completed with failures: extension {extensionName} version {extensionVersion} by {extensionPublisher} ({extensionId})

{extensionName} indicates the name of the extension.

{extensionVersion} indicates the version of the extension.

{extensionPublisher} indicates the publisher of the extension.

{extensionId} indicates the id of the extension.

Custom dimensions

Dimension Description or value
eventId LC0206
environmentId

Note

Azure Active Directory is now Microsoft Entra ID. Learn more

Specifies the Microsoft Entra tenant ID used for Microsoft Entra authentication. For on-premises, if you aren't using Microsoft Entra authentication, this value is common.
environmentName Specifies the name of the tenant environment. Learn more in Managing Environments.
environmentType Specifies the environment type for the tenant, such as Production or Sandbox. Learn more in Environment Types.
extensionName Specifies the name of the extension that was to be validated.
extensionId Specifies the ID of the extension/app.
extensionPublisher Specifies the publisher of the extension/app.
extensionVersion Specifies the version of the extension.
submissionOperationId A unique identifier (GUID) for the validation attempt.
failureReason The overall reason that the extension failed to validate.

Per-tenant extension (PTE) validation completed successfully (LC0202)

Occurs when a per-tenant extension (PTE) validation attempt is completed successfully on the environment (so that the extension was uploaded).

General dimensions

Dimension Description or value
message PTE submission validation request completed successfully: request {submission id}

{submissionId} indicates the identifier for the validation attempt.

Custom dimensions

Dimension Description or value
eventId LC0202
environmentId

Note

Azure Active Directory is now Microsoft Entra ID. Learn more

Specifies the Microsoft Entra tenant ID used for Microsoft Entra authentication. For on-premises, if you aren't using Microsoft Entra authentication, this value is common.
environmentName Specifies the name of the tenant environment. Learn more in Managing Environments.
environmentType Specifies the environment type for the tenant, such as Production or Sandbox. Learn more in Environment Types.
mainExtension A JSON structure that contains information about the extension that was uploaded.
submissionOperationId A unique identifier (GUID) for the validation attempt.

Per-tenant extension (PTE) validation completed with failures (LC0203)

Occurs when a new per-tenant extension (PTE) validation attempt completed with failures on the environment (so that the extension was not uploaded).

General dimensions

Dimension Description or value
message PTE validation completed with failures: request {submissionId}

{submissionId} indicates the identifier for the validation attempt.

Custom dimensions

Dimension Description or value
eventId LC0203
environmentId

Note

Azure Active Directory is now Microsoft Entra ID. Learn more

Specifies the Microsoft Entra tenant ID used for Microsoft Entra authentication. For on-premises, if you aren't using Microsoft Entra authentication, this value is common.
environmentName Specifies the name of the tenant environment. Learn more in Managing Environments.
environmentType Specifies the environment type for the tenant, such as Production or Sandbox. Learn more in Environment Types.
mainExtension A json structure that contains information about the extension that is being uploaded.
submissionOperationId A unique identifier (GUID) for the validation attempt.
failureReason The overall reason that the extension failed to upload.

Sample KQL code (Per-tenant extension (PTE) validation completed with failures)

This KQL code can help you get started analyzing validation failures for uploading an extension to the environment:

// PTE submission validation request completed with failures: request <submission id>	
traces 
| where customDimensions has "LC0203"
| where customDimensions.eventId == "LC0203"
| where timestamp > ago(30d) // adjust as needed
| extend mainExtension = parse_json(tostring( customDimensions.mainExtension ))
| project timestamp
// in which environment is the extension being validated
, aadTenantId = case(
  isnotempty(customDimensions.aadTenantId), customDimensions.aadTenantId  
, isnotempty(customDimensions.environmentId), customDimensions.environmentId
, 'Unknown'
)
, environmentName = customDimensions.environmentName
// which extension/app is being validated
, mainExtensionId = mainExtension.Id
, mainExtensionPublisher = mainExtension.Publisher
, mainExtensionVersion = mainExtension.Version 
, mainExtensionName = mainExtension.Name 
, dependentExtensions = customDimensions.dependentExtensions
// validation info
, submissionOperationId = customDimensions.submissionOperationId  
, failureReason = customDimensions.failureReason

Monitoring and Analyzing Telemetry
Enable Sending Telemetry to Application Insights