有 Java 编程相关的问题?

你可以在下面搜索框中键入要查询的问题!

java_OPTS中的java绕过非代理主机

我在单机版中添加了非代理主机。获取门户服务器的conf.bat

-Dhttp.proxyHost=10.111.1.00 -Dhttp.proxyPort=80 -Dhttp.nonProxyHosts=localhost|127.0.0.1|172.16.31.* "

当我启动服务器时,出现以下错误

c:\jboss-jpp-6.1.0\jboss-jpp-6.1\bin>standalone.bat
Calling "c:\jboss-jpp-6.1.0\jboss-jpp-6.1\bin\standalone.conf.bat"
'127.0.0.1' is not recognized as an internal or external command,
operable program or batch file.

共 (1) 个答案

  1. # 1 楼答案

    因为我没有足够的声誉,所以不能发表评论。在Windows中将其设置为环境变量时,我也遇到了这个问题。事实证明,你需要使用^来转义|字符

    http://www.robvanderwoude.com/useless.php#EscapeChar

    所以这对我有用

    -Dhttp.nonProxyHosts=localhost^|127.0.0.1^|*.foo.com