非容器环境时设置networkaddress.cache.ttl参数
networkaddress.cache.ttl (default: -1)
Specified in java.security to indicate the caching policy for successful
name lookups from the name service. The value is specified as as integer
to indicate the number of seconds to cache the successful lookup.
A value of -1 indicates "cache forever".
当应用部署与Tomcat等容器在容器的启动参数中设置-Dsun.net.inetaddr.ttl参数:
sun.net.inetaddr.ttl
This is a sun private system property which corresponds to networkaddress.cache.ttl.
It takes the same value and has the same meaning, but can be set as a command-line
option. However, the preferred way is to use the security property mentioned above.
阅读(826) | 评论(0) | 转发(0) |