Process 进程以exec maven插件块mvn verify启动

Process 进程以exec maven插件块mvn verify启动,process,block,exec-maven-plugin,Process,Block,Exec Maven Plugin,我正在使用exec maven插件启动服务器,如下所示: <plugin> <groupId>org.codehaus.mojo</groupId> <artifactId>exec-maven-plugin</artifactId> <version>1.2.1</version> <executions> <execution>

我正在使用exec maven插件启动服务器,如下所示:

<plugin>
    <groupId>org.codehaus.mojo</groupId>
    <artifactId>exec-maven-plugin</artifactId>
    <version>1.2.1</version>
    <executions>
        <execution>
            <id>start-server</id>
            <phase>pre-integration-test</phase>
            <goals>
                <goal>exec</goal>
            </goals>
            <configuration>
                <executable>java</executable>
                <arguments>
                    <argument>-classpath</argument>
                    <!-- automatically creates the classpath using all project dependencies, 
                        also adding the project build directory -->
                    <classpath />
                    <argument>MyGroup.MyServer.MyServerpjki</argument>
                    <argument>-batch</argument>
                    <argument>-port</argument>
                    <argument>1025</argument>
                </arguments>
            </configuration>
        </execution>
    </executions>
</plugin>

org.codehaus.mojo
和。是否有一个独立于平台的解决方案来解决此问题

我还有一个额外的问题:通过execmaven插件再次关闭应用程序startet的最佳方式是什么