jetty.xml 3.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687
  1. <?xml version="1.0"?>
  2. <!DOCTYPE Configure PUBLIC "-//Mort Bay Consulting//DTD Configure 1.2//EN" "http://jetty.mortbay.org/configure_1_2.dtd">
  3. <!-- $Id$ -->
  4. <!-- =============================================================== -->
  5. <!-- Configure the Jetty Server -->
  6. <!-- =============================================================== -->
  7. <Configure class="org.mortbay.jetty.Server">
  8. <!-- =============================================================== -->
  9. <!-- Configure the Request Listeners -->
  10. <!-- =============================================================== -->
  11. <!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -->
  12. <!-- Add and configure a HTTP listener to port 8080 -->
  13. <!-- The default port can be changed using: java -Djetty.port=80 -->
  14. <!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -->
  15. <Call name="addListener">
  16. <Arg>
  17. <New class="org.mortbay.http.SocketListener">
  18. <Set name="Port"><SystemProperty name="jetty.port" default="8080"/></Set>
  19. <Set name="MinThreads">5</Set>
  20. <Set name="MaxThreads">50</Set>
  21. <Set name="MaxIdleTimeMs">30000</Set>
  22. <Set name="LowResourcePersistTimeMs">1000</Set>
  23. <Set name="ConfidentialPort">8443</Set>
  24. <Set name="IntegralPort">8443</Set>
  25. <Set name="PoolName">main</Set>
  26. </New>
  27. </Arg>
  28. </Call>
  29. <Call name="instance" class="org.mortbay.util.Log">
  30. <Call name="add">
  31. <Arg>
  32. <New class="org.mortbay.util.OutputStreamLogSink">
  33. <Set name="filename"><SystemProperty name="jetty.home" default="."/>/logs/yyyy_mm_dd.jetty.log</Set>
  34. <Set name="retainDays">90</Set>
  35. <Set name="append">true</Set>
  36. <Set name="logLabels">true</Set>
  37. <Set name="logStackSize">true</Set>
  38. <Set name="logStackTrace">false</Set>
  39. <Set name="logOneLine">false</Set>
  40. <Set name="logTimeZone">GMT</Set>
  41. <Call name="start"/>
  42. </New>
  43. </Arg>
  44. </Call>
  45. </Call>
  46. <!-- =============================================================== -->
  47. <!-- Configure the Contexts -->
  48. <!-- =============================================================== -->
  49. <!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -->
  50. <!-- Add a all web application within the webapps directory. -->
  51. <!-- + No virtual host specified -->
  52. <!-- + Look in the webapps directory relative to jetty.home or . -->
  53. <!-- + Use the webdefault.xml resource for the defaults descriptor -->
  54. <!-- + Upack the war file -->
  55. <!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -->
  56. <Set name="rootWebApp">root</Set>
  57. <Call name="addWebApplications">
  58. <Arg></Arg>
  59. <Arg><SystemProperty name="jetty.home" default="."/>/webapps/</Arg>
  60. <Arg><SystemProperty name="jetty.home" default="."/>/etc/webdefault.xml</Arg>
  61. <Arg type="boolean">true</Arg>
  62. </Call>
  63. <!-- =============================================================== -->
  64. <!-- Configure the Other Server Options -->
  65. <!-- =============================================================== -->
  66. <Set name="requestsPerGC">2000</Set>
  67. <Set name="statsOn">false</Set>
  68. <Call name="addRealm">
  69. <Arg>
  70. <New class="net.sf.acegisecurity.adapters.jetty.JettyAcegiUserRealm">
  71. <Arg>Spring Powered Realm</Arg>
  72. <Arg>my_password</Arg>
  73. <Arg>etc/acegisecurity.xml</Arg>
  74. </New>
  75. </Arg>
  76. </Call>
  77. </Configure>