Process: com.example.je.motan, PID: 24963
com.weibo.api.motan.exception.MotanServiceException: error_message: NettyChannel connect to server timeout url: motan://192.168.1.201:8002/com.example.motan_jdbc.weibo.motan.benchmark.BenchmarkService, cost: 1001, result: false, success: false, connected: false, status: 503, error_code: 10001,r=null
at com.weibo.api.motan.transport.netty.NettyChannel.open(NettyChannel.java:155)
at com.weibo.api.motan.transport.netty.NettyChannelFactory.makeObject(NettyChannelFactory.java:53)
at org.apache.commons.pool.impl.GenericObjectPool.borrowObject(GenericObjectPool.java:1188)
at com.weibo.api.motan.transport.AbstractPoolClient.borrowObject(AbstractPoolClient.java:75)
at com.weibo.api.motan.transport.netty.NettyClient.request(NettyClient.java:164)
at com.weibo.api.motan.transport.netty.NettyClient.request(NettyClient.java:120)
at com.weibo.api.motan.protocol.rpc.DefaultRpcProtocol$DefaultRpcReferer.doCall(DefaultRpcProtocol.java:171)
at com.weibo.api.motan.rpc.AbstractReferer.call(AbstractReferer.java:64)
at com.weibo.api.motan.cluster.ha.FailfastHaStrategy.call(FailfastHaStrategy.java:38)
at com.weibo.api.motan.cluster.support.ClusterSpi.call(ClusterSpi.java:73)
at com.weibo.api.motan.proxy.RefererInvocationHandler.invoke(RefererInvocationHandler.java:125)
at java.lang.reflect.Proxy.invoke(Proxy.java:397)
at $Proxy4.callService(Unknown Source)
at com.example.je.motan.MotanClient.test(MotanClient.java:74)
at com.example.je.motan.MainActivity$1.run(MainActivity.java:16)
at java.lang.Thread.run(Thread.java:818)
后台要我们用motan框架来配合后端那边.虽然我也不知道为什么要这么做,他说手机微博也是这样用的. 在Android Studio上以java工程时运行是没有问题的. 但是在Android工程里用硬编码的方式配置测试,在最后一步连接服务器时出错了.状态码503.下面给错误信息和代码
下面是代码
我怀疑是Android不允许这样子调用连接网络. So.其实我相问的是motan这个框架可不可以用在Android当中