Bind Jetty to IPv6 address

后端 未结 2 1038
一个人的身影
一个人的身影 2021-01-21 04:12

I am trying to bind Jetty to listen only to IPv6 address. I am using Jetty 7.4.2.v20110526.

my jetty.xml:


  

        
2条回答
  •  -上瘾入骨i
    2021-01-21 04:41

    If you haven't found a solution, here it is. Change the NIO connector with the IO one. Instead of using "org.mortbay.jetty.nio.SelectChannelConnector" use "org.mortbay.jetty.bio.SocketConnector" and the overall connector config will be:

    
      
          
            
            50000
            1500
          
      
    
    

    This way you will be able to access the webpage using both IPv4 and IPv6 address. Hope this helps.

提交回复
热议问题