Writing metainfo.xml
metainfo.xml is the declarative service descriptor. Its top-level service identifies the service with name, displayName, and version, and describes components, osSpecifics, commandScript, requiredServices, configuration-dependencies, and an optional configuration-dir.
Components
Each component has a unique name, display name, category (MASTER, SLAVE, or CLIENT), and cardinality. It may advertise a version, allow reassignment, declare dependencies, define custom commands, and provide component-specific scripts and logs.
Commands and Configuration
commandScript identifies the Python script and timeout used for service or component operations. configuration-dependencies lists the configuration types required by the service or component; when a dependency changes, Ambari can mark the affected component for restart. configFiles identifies generated XML, environment, or properties files and their dictionary names.
Packages and Platforms
osSpecifics maps an operating-system family to the packages needed to deploy a service. Package names are consumed by the platform package manager. A service can also declare required services and dependency conditions, including cluster- or host-scoped dependencies and auto-deploy behavior.
Lifecycle
Scripts implement the component lifecycle. Standard operations include install, start, stop, status, and configure; customCommands adds service-specific operations. The versionAdvertised flag tells Ambari whether a component participates in version-aware upgrade processing.
Example
The descriptor should remain focused on service metadata and executable contracts. Keep provider-specific telemetry in telemetry.json; retain metrics.json for Ambari control-plane metrics. Refer to the current BIGTOP HDFS metainfo.xml for a concrete descriptor.