cfhttp dns解析 [英] cfhttp dns resolution

查看:341
本文介绍了cfhttp dns解析的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我试图让CFHTTP与我在测试服务器上为测试目的创建的域进行通信。域的地址是mydomain.example.com。每次我尝试使用cfhttp连接我得到一个错误说明:

i'm trying to get CFHTTP to talk to a domain that i have created for testing purposes on my test server. the address of the domain is "mydomain.example.com". everytime i try to connect using cfhttp i get an error stating:

Your requested host "mydomain.example.com" could not be resolved by DNS.

我已经在Windows主机文件中添加了条目。

i have already added the entry in the windows hosts file.

mydomain.example.com 127.0.0.1

我还确保java.net.InetAddress可以通过在coldfusion页面中执行以下操作来解析域:

i've also made sure that java.net.InetAddress can resolve the domain by doing the following in a coldfusion page:

<cfset loc.javaInet = createObject("java","java.net.InetAddress")>
<cfset loc.dnsLookup = loc.javaInet.getByName("mydomain.example.com")>

mydomain.example.com/127.0.0.1

尝试启动和停止冷拼服务,并将runtimeaddress.cache.ttl的值在runtime\jre\lib\security\java.security中更改为0.

i've even tried starting and stopping the coldfusion service and changing the value of networkaddress.cache.ttl in the runtime\jre\lib\security\java.security to 0.

我失去了为什么一切似乎解决在jre级别,而不是在cfhttp级别。任何想法

i'm at a lost of why everything seems to be resolving at the jre level but not at the cfhttp level. any ideas???

推荐答案

为什么我发布问题后,我想出来?转到图

Why is it that after I post a question, I figure it out? Go fig.

问题是,由于某种原因,我仍然有一个旧的代理配置设置我的java.args行在我的运行时\bin\jvm.config 。

The issue was that for some reason I still had an old proxy configuration setup on my java.args line in my runtime\bin\jvm.config.

删除旧配置设置并重新启动ColdFusion服务后,我已恢复运行。

After removing the old configuration setting and restarting the ColdFusion service, I'm back in business.

对于那些想知道的,你可以通过添加以下参数到jvm.config文件中的java.args行来设置cfhttp的代理信息

For those that want to know, you can set the proxy information for cfhttp to use by adding the following arguments to your java.args line in the jvm.config file

-Dhttp.proxyHost=<ip address>
-Dhttp.proxyPort=<portnumber>
-Dhttp.proxyUser=<username>
-Dhttp.proxyPassword=<password>

这篇关于cfhttp dns解析的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆