tomcat-debug.bat 1.3 KB

1234567891011121314151617181920212223242526272829303132333435
  1. @echo off
  2. echo [INFO] Use maven tomcat-plugin run the project.
  3. cd %~dp0
  4. cd ..
  5. rem call mvn clean compile -e
  6. call mvn clean compile -e -o
  7. echo --------------------- Set Jrebel ---------------------
  8. set REBEL_HOME=.\bin
  9. set REBEL_CLASS_PATH=.\target\classes
  10. set MAVEN_OPTS=%MAVEN_OPTS% -javaagent:%REBEL_HOME%\jrebel.jar -noverify -Drebel.spring_plugin=true -Drebel.hibernate_plugin=true
  11. set MAVEN_OPTS=%MAVEN_OPTS% -Drebel.dirs=%REBEL_CLASS_PATH%
  12. echo %MAVEN_OPTS%
  13. echo --------------------- Set Jmxremote ---------------------
  14. set JMX_OPTS=
  15. set JMX_OPTS=%JMX_OPTS% -Dcom.sun.management.jmxremote=true
  16. set JMX_OPTS=%JMX_OPTS% -Dcom.sun.management.jmxremote.port=9090
  17. set JMX_OPTS=%JMX_OPTS% -Dcom.sun.management.jmxremote.ssl=false
  18. set JMX_OPTS=%JMX_OPTS% -Dcom.sun.management.jmxremote.authenticate=false
  19. echo %JMX_OPTS%
  20. echo --------------------- Set Maven Debug ---------------------
  21. rem MAVEN_OPTS=%JMX_OPTS% %MAVEN_OPTS% -XX:MaxPermSize=256m -Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=5005
  22. set MAVEN_OPTS=%JMX_OPTS% %MAVEN_OPTS% -XX:MaxPermSize=256m -Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=8000
  23. echo %MAVEN_OPTS%
  24. echo --------------------- RUN ---------------------
  25. call mvn tomcat:run -Dmaven.test.skip=true -e -o
  26. cd bin
  27. pause