Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我需要在嵌入式tomcat中配置valve http://tomcat.apache.org/tomcat-8.0-doc/config/valve.html#Remote_IP_Valve 怎么做?
它是 Pipeline 的一部分,它是 Host 的一部分,因此您可以:
Tomcat tomcat = new Tomcat(); Host host = new StandardHost(); Valve valve = ... host.getPipeline().addValve(valve); tomcat.setHost(host);