Jetty does not want to listen on port 80 -


i want change default port jetty 9 listening on 8080 80. i've edited jetty-http.xml file this:

<call name="addconnector"> <arg>   <new class="org.eclipse.jetty.server.serverconnector">     <arg name="server"><ref refid="server" /></arg>     <arg name="factories">       <array type="org.eclipse.jetty.server.connectionfactory">         <item>           <new class="org.eclipse.jetty.server.httpconnectionfactory">             <arg name="config"><ref refid="httpconfig" /></arg>           </new>         </item>       </array>     </arg>     <set name="host"><property name="jetty.host" /></set>     <set name="port"><property name="jetty.port" default="80" /></set>     <set name="idletimeout"><property name="http.timeout" default="30000"/></set>   </new> </arg> 

however, strange reason when startup server still listens on 8080.

the way have xml defined, use jetty.port property first, if not found, use hardcoded port 80.

check ${jetty.home}/start.ini , ${jetty.home}/start.d/* files property.

or alternatively, run $ java -jar start.jar --help , see if shows defined @ end of output of command)

$ java -jar start.jar --help  (...snip...)    current start.ini arguments are:      options=server,websocket,resources,ext     threads.min=10     threads.max=200     threads.timeout=60000     jetty.dump.start=false     jetty.dump.stop=false     etc/jetty.xml     options=jmx     etc/jetty-jmx.xml     options=jsp     jetty.port=8080     http.timeout=30000     etc/jetty-http.xml 

at point have 2 options.

  1. don't edit xml file , configure start.ini entry jetty.port

  2. change xml file entry not property.

<set name="port">80</set> 

Comments

Popular posts from this blog

blackberry 10 - how to add multiple markers on the google map just by url? -

php - guestbook returning database data to flash -

delphi - Dynamic file type icon -