What is Structured logging?
Last updated: July 14, 2025
Structured logging makes Liquibase operation data readily available and machine-readable. In automated workflows, you can use monitoring and analysis tools to read, query, and act upon this data. Liquibase not only does the tricky work of database schema versioning and management, it also helps you understand the data around these operations and how they fit into your overall DevOps and CI/CD performance.
Tools you can use with Liquibase Structured Logging include AWS Cloudwatch, Grafana, Opensearch, Sematext, Splunk, ElasticSearch and other analysis instruments. Monitoring and analysis tools can easily determine and act upon both real-time and long-term trend data for Liquibase usage with Structured Logging. Other data that Liquibase can use are performance, errors, security, tracking for auditability and outcomes, and even standard DORA DevOps metrics.
Liquibase uses a Mapped Diagnostic Context (MDC) to generate structured logs in a JSON format.
This feature is available in Liquibase 4.21.0 and later. Additional functionality is available in later releases.
Examples
[2023-02-27 16:37:00] FINE [liquibase.integration] Performance monitoring disabled
[2023-02-27 16:37:00] FINE [liquibase.configuration] No configuration value for liquibase.outputFile found
[2023-02-27 16:37:00] FINE [liquibase.configuration] No configuration value for liquibase.strict found
Tip: For example dashboards using tools like AWS CloudWatch, Datadog, Elastic, and Splunk, see the GitHub repository liquibase/Observability-Dashboards.
Supported commands
You can get structured logs from the output of the following commands:
changelog-sync
dbcl-history
diff
anddiff-changelog
flow
history
rollback
,rollback-count
,rollback-one-changeset
,rollback-one-update
,rollback-to-date
status
update
,update-count
,update-one-changeset
,update-testing-rollback
,update-to-tag
--version
global argument
Note: Structured Logging affects log output, not command output. Commands like status
, history
, and diff
deliver command output directly in the console. Log output is fine-grained and often related to code or metadata.
Also, not all commands are yet structured. These commands will still produce a structured log, but there will not be additional data or content in these log objects. The new content that is available in structured logs includes things like deploymentID, command parameters, label filter settings, nested objects, and more.
Keys
For a list of keys that Liquibase includes in the JSON output, see Structured Logging Keys.