[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: [tor-bugs] #13089 [Onionoo]: use an embedded web server/servlet engine for Onionoo



#13089: use an embedded web server/servlet engine for Onionoo
-----------------------------+--------------------------
     Reporter:  iwakeh       |      Owner:
         Type:  enhancement  |     Status:  needs_review
     Priority:  minor        |  Milestone:
    Component:  Onionoo      |    Version:
   Resolution:               |   Keywords:
Actual Points:               |  Parent ID:
       Points:               |
-----------------------------+--------------------------

Comment (by karsten):

 {{{
 <?xml version="1.0"?>
 <!DOCTYPE Configure PUBLIC "-//Jetty//Configure//EN"
   "http://www.eclipse.org/jetty/configure.dtd";>

 <Configure id="server" class="org.eclipse.jetty.server.Server" >
   <Set name="dumpAfterStart">false</Set>

   <Set name="threadPool">
     <New class="org.eclipse.jetty.util.thread.QueuedThreadPool">
       <Set name="minThreads">10</Set>
       <Set name="maxThreads">250</Set>
       <Set name="detailedDump">false</Set>
     </New>
   </Set>

   <New id="webAppContext" class="org.eclipse.jetty.webapp.WebAppContext">
     <Set name="logUrlOnStart">true</Set>
     <Set name="war">
       <Call class="java.lang.System" name="getProperty">
         <Arg>java.class.path</Arg>
       </Call>
     </Set>
   </New>

   <Call name="addConnector">
     <Arg>
       <New class="org.eclipse.jetty.server.nio.SelectChannelConnector">
         <Set name="port">8080</Set>
       </New>
     </Arg>
   </Call>

   <Set name="handler">
     <!-- maybe add more handlers (statistics, logging, etc.) later -->
     <New
 class="org.eclipse.jetty.server.handler.ContextHandlerCollection">
       <Call name="addHandler">
         <Arg>
           <Ref id="webAppContext"/>
         </Arg>
       </Call>
     </New>
   </Set>

 </Configure>
 }}}

 (I switched back to Tomcat a few hours ago in the context of deploying
 #13135, but I can rebase and re-deploy this branch at any time.)

--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/13089#comment:22>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online
_______________________________________________
tor-bugs mailing list
tor-bugs@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs