= spring-cloud-dataflow-apps-generator-plugin
Maven plugin for generating https://github.com/spring-cloud/stream-applications[Spring Cloud Stream Applications].
It generates a separate maven project for every configured binder.
Plugin `Application` section helps to configure the application project independently form the Binders that can be used.
The `Binders` section helps to define the Binder specific configurations, that are merged to the `Application` configurations to generate the binder specific maven projects.
The `Global` section (e.g. `global.application` and `global.binders`) helps to define configurations sharable between many Applications and Binders.
As the following diagram illustrates, both the `Application` and the
`Binder` allow configuring various application and maven properties:
image::src/main/resources/doc/MojoConfiguration.jpg[]
== Build
Java 17 required.
[source, bash]
----
mvn clean package
----
== Sample Configuration
In the parent POM define the `Application` and `Binder` configurations common for all applications to be generated.
Do this under the `pluginManagement` pom section and use the plugin's `global` configuration:
[source, xml]
----
org.springframework.cloud
spring-cloud-dataflow-apps-generator-plugin
1.1.0-SNAPSHOT
app-gen
package
generate-app
${basedir}/apps
${spring-boot.version}
yourOrgNameGoesHere
true
1.1.0-SNAPSHOT
org.springframework.cloud
spring-cloud-stream-binder-kafka
org.springframework.cloud
spring-cloud-stream-binder-rabbit
----
Above global configurations will be reused by all children applications.
In addition, the child application can add application specific configurations, contributed to the inherited from
to the global:
[source, xml]
----
org.springframework.cloud
spring-cloud-dataflow-apps-generator-plugin
1.1.0-SNAPSHOT
syslog
source
${project.version}
org.springframework.cloud.fn.supplier.syslog.SyslogSupplierConfiguration.class
org.springframework.cloud.fn
syslog-supplier
org.springframework.cloud.stream.app
stream-applications-composite-function-support
${stream-apps-core.version}
----