Maven設定Jetty並修改埠號
阿新 • • 發佈:2019-02-18
<plugin> <groupId>org.mortbay.jetty</groupId> <artifactId>maven-jetty-plugin</artifactId> <version>6.1.26</version> <configuration> <scanIntervalSeconds>2</scanIntervalSeconds><!-- 每2秒的間隔掃描一次,實現熱部署 --> <connectors> <connector implementation="org.mortbay.jetty.nio.SelectChannelConnector"> <port>8012</port><!--埠號--> </connector> </connectors> <scanTargetPatterns> <scanTargetPattern> <directory>src/main/webapp/WEB-INF</directory> <excludes> <exclude>**/*.jsp</exclude> </excludes> <includes> <include>**/*.properties</include> <include>**/*.xml</include> </includes> </scanTargetPattern> </scanTargetPatterns> </configuration> </plugin>