feat: hybrid ConfigReportCommand with static metadata and runtime values#15426
Open
jamesfredley wants to merge 7 commits into7.0.xfrom
Open
feat: hybrid ConfigReportCommand with static metadata and runtime values#15426jamesfredley wants to merge 7 commits into7.0.xfrom
jamesfredley wants to merge 7 commits into7.0.xfrom
Conversation
Add a comprehensive Application Properties reference page under
ref/Configuration/ listing all Grails-specific configuration keys
with descriptions and default values. Covers core framework, GORM,
DataSource, Hibernate, Database Migration Plugin, Cache Plugin,
Asset Pipeline Plugin, Spring Security Plugin, and MongoDB GORM Plugin.
All external links use doc variables ({springBootVersion},
{hibernate5Reference}) for version-safe URLs.
Assisted-by: OpenCode <opencode@opencode.ai>
Assisted-by: Claude <claude@anthropic.com>
Merge curated property metadata from the Application Properties documentation with runtime-collected values from the Spring Environment. The command now outputs a 3-column AsciiDoc table (Property, Description, Default) organized by functional category (Core Properties, Web & Controllers, CORS, GORM, etc.). Runtime values override static defaults for known properties. Properties not found in the metadata appear in a separate Other Properties section. - Add config-properties.yml with ~160 properties across 21 categories - Modify ConfigReportCommand to load YAML metadata and merge with runtime - Update unit tests for 3-column hybrid format - Update integration tests for hybrid category-based layout Assisted-by: Claude Code <Claude@Claude.ai>
Contributor
Author
Add Apache license headers to config-properties.yml and logback.xml that were missing required ASF headers, causing CI RAT audit failure. Assisted-by: Claude Code <Claude@Claude.ai>
Contributor
There was a problem hiding this comment.
Pull request overview
Adds a hybrid ConfigReportCommand to Grails that merges curated configuration-property metadata (from a new classpath YAML file) with runtime-resolved values from Spring’s ConfigurableEnvironment, and includes a new grails-test-examples/config-report sample app to validate the output format end-to-end.
Changes:
- Introduces
ConfigReportCommandto generate a categorized AsciiDoc report using static metadata + runtime overrides, with an “Other Properties” section for non-metadata keys. - Adds
META-INF/grails/config-properties.ymlcontaining categorized property metadata (descriptions + defaults). - Adds/updates unit + integration tests, including a new
grails-test-examples/config-reportmodule wired intosettings.gradle.
Reviewed changes
Copilot reviewed 13 out of 13 changed files in this pull request and generated 7 comments.
Show a summary per file
| File | Description |
|---|---|
| settings.gradle | Adds the new grails-test-examples-config-report included build project. |
| grails-core/src/main/groovy/grails/dev/commands/ConfigReportCommand.groovy | Implements the hybrid config report generator (runtime collection + metadata merge + AsciiDoc output). |
| grails-core/src/main/resources/META-INF/grails/config-properties.yml | Supplies categorized metadata used to render known properties. |
| grails-core/src/test/groovy/grails/dev/commands/ConfigReportCommandSpec.groovy | Unit tests for property collection, metadata loading, escaping, and report layout. |
| grails-test-examples/config-report/** | New sample application + integration spec validating runtime config capture and report structure. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
grails-core/src/main/groovy/grails/dev/commands/ConfigReportCommand.groovy
Show resolved
Hide resolved
grails-core/src/main/groovy/grails/dev/commands/ConfigReportCommand.groovy
Show resolved
Hide resolved
grails-core/src/main/groovy/grails/dev/commands/ConfigReportCommand.groovy
Show resolved
Hide resolved
grails-core/src/main/groovy/grails/dev/commands/ConfigReportCommand.groovy
Show resolved
Hide resolved
...ig-report/src/integration-test/groovy/configreport/ConfigReportCommandIntegrationSpec.groovy
Outdated
Show resolved
Hide resolved
Add instanceof Map guard after Yaml.load() in loadPropertyMetadata() to prevent NPE when the YAML resource is empty or contains a non-Map root. Remove unused @tempdir field and its import from the integration test. Assisted-by: Claude Code <Claude@Claude.ai>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Combines the curated property metadata from #15407 with the runtime environment collection from the
configuration-commandbranch into a single hybridConfigReportCommand.What it does
config-properties.yml(descriptions, defaults for ~160 known Grails properties across 21 categories)ConfigurableEnvironmentProperty | Description | Default) organized by functional categoryChanges
ConfigReportCommand.groovy- Modified to load YAML metadata and merge with runtime valuesconfig-properties.yml- New metadata file with ~160 properties across 21 categories (Core, Web & Controllers, CORS, Views & GSP, GORM, DataSource, Spring Security, MongoDB, etc.)ConfigReportCommandSpec.groovy- Updated unit tests for 3-column hybrid formatConfigReportCommandIntegrationSpec.groovy- Updated integration tests for category-based layoutBased on
configuration-commandbranch (jdaugherty's ConfigReportCommand proof-of-concept)Test results