topic hubAL Developmentofficial - Microsoftreviewed - checked by Opus

Rules, guidelines, and best practices

Rules, guidelines, and best practices for Business Central extension development: how to obsolete AL objects, methods and symbols, how to deprecate external business events, and a Best practices subtopic on AL conventions, testing, performance, security, telemetry and Marketplace preparation.

Path: Development > Rules, guidelines, and best practices · tier official · system development · narrative reviewed (checked by Opus)

Overview

This section collects the rules developers follow when building and maintaining Business Central extensions. Two pages sit directly in the hub and deal with lifecycle changes. One covers marking AL objects, methods and symbols as obsolete. The other covers deprecating external business events so that integrations are informed and move to replacement events.

The Best practices subtopic (17 pages) covers the wider craft: AL code conventions and restrictions, testing, performance, security, telemetry, connectivity app requirements and documenting user scenarios. It also helps with preparing an extension for Marketplace validation.

Start with the obsolete AL page if you need to retire code in an extension. Use the external business events page if the change affects outside integrations. Go to Best practices for general questions on writing, testing, securing and publishing extensions.

Key points

  • Obsoleting in AL uses the ObsoleteState, ObsoleteReason and ObsoleteTag properties or the [Obsolete] attribute.
  • Analyzer rules enforce obsoletion, and preprocessor directives are part of the obsoletion guidance.
  • External business events are deprecated by first marking them obsolete pending, then removing them in a future version.
  • Deprecating an external business event involves the Obsolete and ExternalBusinessEvent attributes, a DisplayName prefix and event versioning. The page references version 27.0.
  • The deprecation process is meant to keep external integrations informed and moving to replacement events.
  • Best practices (17 pages) covers AL code conventions, restrictions, testing, performance, security and telemetry.
  • Best practices also covers connectivity app requirements, user scenario documentation and preparing for Marketplace validation.

Subtopics

More Learn pages

Videos, posts and code changes

Linked by a Haiku matcher with a grounding quote from the item’s summary (link/topics.ts); machine-generated.

Source: Microsoft Learn (CC BY 4.0). Descriptions are Learn’s own.

What Learn documents here 8 of 19 Learn pages

Show 11 more