BAEL-2688 Allow specific app to be run from mvn

This commit is contained in:
pcoates 2019-08-02 17:40:28 +01:00
parent 168cd4a0a4
commit 67356a316f
2 changed files with 24 additions and 0 deletions

View File

@ -21,4 +21,20 @@
</dependency>
</dependencies>
<properties>
<start-class>com.baeldung.springamqp.simple.HelloWorldMessageApp</start-class>
</properties>
<build>
<plugins>
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
<configuration>
<mainClass>${start-class}</mainClass>
</configuration>
</plugin>
</plugins>
</build>
</project>

View File

@ -9,6 +9,14 @@ import org.springframework.context.annotation.Bean;
import static com.baeldung.springamqp.broadcast.BroadcastConfig.*;
/**
* Simple test application to send messages to rabbitMQ.
*
*<p>To run this particular application with mvn you use the following command:</p>
* {@code
* mvn spring-boot:run -Dstart-class=com.baeldung.springamqp.broadcast.BroadcastMessageApp
* }
*/
@SpringBootApplication
public class BroadcastMessageApp {