axis2 发送报文报告Dangling meta character '*' near index 0 异常

最近在用Mac Pro做开发,一直好好地,直到有一天,项目上用了axis2来做Webservice的客户端,结果一运行,就出现了以下的异常:

java.util.regex.PatternSyntaxException: Dangling meta character '*' near index 0

*.local

^tokenid:null

at java.util.regex.Pattern.error(Pattern.java:1955)

at java.util.regex.Pattern.sequence(Pattern.java:2123)

at java.util.regex.Pattern.expr(Pattern.java:1996)

at java.util.regex.Pattern.compile(Pattern.java:1696)

at java.util.regex.Pattern.<init>(Pattern.java:1351)

at java.util.regex.Pattern.compile(Pattern.java:1028)

at java.util.regex.Pattern.matches(Pattern.java:1133)

at java.lang.String.matches(String.java:2109)

at org.apache.axis2.transport.http.ProxyConfiguration.validateNonProxyHosts(ProxyConfiguration.java:261)

at org.apache.axis2.transport.http.ProxyConfiguration.isProxyEnabled(ProxyConfiguration.java:223)

at org.apache.axis2.transport.http.AbstractHTTPSender.getHostConfiguration(AbstractHTTPSender.java:271)

at org.apache.axis2.transport.http.AbstractHTTPSender.executeMethod(AbstractHTTPSender.java:502)

at org.apache.axis2.transport.http.HTTPSender.sendViaPost(HTTPSender.java:191)

at org.apache.axis2.transport.http.HTTPSender.send(HTTPSender.java:77)

at org.apache.axis2.transport.http.CommonsHTTPTransportSender.writeMessageWithCommons(CommonsHTTPTransportSender.java:327)

at org.apache.axis2.transport.http.CommonsHTTPTransportSender.invoke(CommonsHTTPTransportSender.java:206)

at org.apache.axis2.engine.AxisEngine.send(AxisEngine.java:396)

at org.apache.axis2.description.OutInAxisOperationClient.send(OutInAxisOperation.java:374)

at org.apache.axis2.description.OutInAxisOperationClient.executeImpl(OutInAxisOperation.java:211)

at org.apache.axis2.client.OperationClient.execute(OperationClient.java:163)

at com.wondersgroup.cuteinfo.client.auth.IAuthenServiceServiceStub.authenticate(IAuthenServiceServiceStub.java:436)

at com.wondersgroup.cuteinfo.client.util.UserTokenUtils.getTicket(UserTokenUtils.java:32)

at cuteinfo.demo.NStest.main(NStest.java:52)

com.wondersgroup.cuteinfo.client.exchangeserver.exchangetransport.exception.UMessageTransportException: User info is invalid.

at com.wondersgroup.cuteinfo.client.exchangeserver.exchangetransport.impl.UMessageTransporterDAOImpl.send(UMessageTransporterDAOImpl.java:197)

at cuteinfo.demo.NStest.main(NStest.java:78)


 …… 真的很神奇。同样的代码在用windows开发的同事那里就没有问题,一时间真是莫名其妙,不知道怎么回事。试了好久,也找不到解决的方法。

是在没办法,只好拿来源码,跟踪一下,看看到底什么缘故。

结果,发现是出错在,apache读取mac 本机的网络代理信息的时候。于是,灵光一闪,打开了MAC的网络代理设置,发现,居然是这样滴:

看来问题的源头就是在这里了。试着把里面的配置清空,保存。

在运行程序,一切正常,问题解决了。

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值