jdaugherty commented on code in PR #15409:
URL: https://github.com/apache/grails-core/pull/15409#discussion_r2824651514
##########
grails-core/src/main/groovy/grails/plugins/GrailsPlugin.java:
##########
@@ -263,6 +263,19 @@ public interface GrailsPlugin extends
ApplicationContextAware, Comparable, Grail
*/
String getDependentVersion(String name);
+ /**
+ * Returns the plugin's configuration as a {@link PropertySource}, looked
up from the
+ * Spring {@link org.springframework.core.env.Environment} by naming
convention.
+ *
+ * <p>Plugin configuration is loaded early in the Spring Boot lifecycle by
+ * {@link org.grails.config.GrailsPluginEnvironmentPostProcessor} and
registered as a
+ * property source named {@code <pluginName>-plugin.yml} or {@code
<pluginName>-plugin.groovy}.
+ * This method retrieves that property source from the application
context's environment.</p>
+ *
+ * @return the plugin's property source from the environment, or {@code
null} if the
+ * GrailsApplication main context is not yet available or no
matching property source exists
+ */
+ @Deprecated(forRemoval = true)
Review Comment:
I was proposing this be removed because I don't see a usage for it - you can
fetch the configuration but when would it be valid to look at the shipped
config? btw, i had marked this as draft to see what @matrei thinks of this.
This is a rather large change for 7.0.x so we may want to do some further
testing.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]