zoukankan      html  css  js  c++  java
  • maven热部署插件-jetty

    作者:小勇Oo

    关于maven-jetty-plugin的说明:

    pom文件中:

    1. <build>  
    2.     <finalName>freemarker</finalName>  
    3.   
    4.     <pluginManagement>  
    5.         <plugins>  
    6.             <plugin>  
    7.                 <groupId>org.mortbay.jetty</groupId>  
    8.                 <artifactId>maven-jetty-plugin</artifactId>  
    9.                 <version>6.1.22</version>  
    10.                 <configuration>  
    11.                     <scanIntervalSeconds>10</scanIntervalSeconds>  
    12.                     <useTestClasspath>true</useTestClasspath>  
    13.                     <webAppConfig>  
    14.                         <contextPath>/freemarker</contextPath>  
    15.                     </webAppConfig>  
    16.                     <connectors>  
    17.                         <connector implementation="org.mortbay.jetty.nio.SelectChannelConnector">  
    18.                             <port>8080</port>  
    19.                         </connector>  
    20.                     </connectors>  
    21.                 </configuration>  
    22.             </plugin>  
    23.         </plugins>  
    24.     </pluginManagement>  
    25. </build>  


    说明:

    1.<scanIntervalSeconds>10</scanIntervalSeconds>  表示热部署时间

    2.<useTestClasspath>true</useTestClasspath>  默认为fasle,true表示web.xml读取配置文件都是从src/test/resources中读取

    3.<contextPath>/freemarker</contextPath>访问项目名为freemarker,若不需要项目名则直接为 /

    启动maven命令为:  jetty:run

  • 相关阅读:
    在Flex (Flash)中嵌入HTML 代码或页面—Flex IFrame
    让Android App启动更协调
    最短路+状态压缩dp(旅行商问题)hdu-4568-Hunter
    weblogic 内存 及 内存溢出
    Mysql或者Hive数据行变成列
    使用sphinx生成美观的文档
    adb 功能大全
    Problem B: Excuses, Excuses!
    2014acm亚洲区域赛陕西赛总结
    Cookie的写入,和读取
  • 原文地址:https://www.cnblogs.com/lxl57610/p/7442009.html
Copyright © 2011-2022 走看看