[x] I have searched the issues of this repository and believe that this is not a duplicate.
Ⅰ. Issue Description
I downloads the newest source code, get the dependencies, open the server module run the ServerTest.java , it has errors. After traceing the errors, I found the code execute on this line
" RegistryFactory.getInstance().register(new InetSocketAddress(XID.getIpAddress(), XID.getPort()));" in AbstractRpcRemotingServer.java file, the error just happend. It seem that XID have no values, so the XID.getIpAddress()'s call return null, then CHECKHOST method catch that and throw the exception. SO I want to know is there something wrong or I have some mistakes.
Ⅱ. Describe what happened
If there is an exception, please attach the exception trace:
Just paste your stack trace here!
2019-04-08 14:53:21.436 INFO [main]c.a.fescar.core.rpc.netty.AbstractRpcRemotingServer.start:153 -Server started ...
Exception in thread "main" java.lang.RuntimeException: java.lang.IllegalArgumentException: hostname can't be null
at com.alibaba.fescar.core.rpc.netty.AbstractRpcRemotingServer.start(AbstractRpcRemotingServer.java:158)
at com.alibaba.fescar.core.rpc.netty.RpcServer.init(RpcServer.java:131)
at ServerTest.main(ServerTest.java:46)
Caused by: java.lang.IllegalArgumentException: hostname can't be null
at java.net.InetSocketAddress.checkHost(InetSocketAddress.java:149)
at java.net.InetSocketAddress.(InetSocketAddress.java:216)
at com.alibaba.fescar.core.rpc.netty.AbstractRpcRemotingServer.start(AbstractRpcRemotingServer.java:154)
... 2 more
2019-04-08 14:53:21.452 INFO [ShutdownHook]com.alibaba.fescar.core.rpc.netty.RpcServer.destroy:177 -destroyed rpcServer
Ⅲ. Describe what you expected to happen
Ⅳ. How to reproduce it (as minimally and precisely as possible)
just downloads the newest source code
get the dependencies ready
open the server module, run the ServerTest.java in test directory , then you will see the exception
Ⅰ. Issue Description
I downloads the newest source code, get the dependencies, open the server module run the ServerTest.java , it has errors. After traceing the errors, I found the code execute on this line " RegistryFactory.getInstance().register(new InetSocketAddress(XID.getIpAddress(), XID.getPort()));" in AbstractRpcRemotingServer.java file, the error just happend. It seem that XID have no values, so the XID.getIpAddress()'s call return null, then CHECKHOST method catch that and throw the exception. SO I want to know is there something wrong or I have some mistakes.
Ⅱ. Describe what happened
If there is an exception, please attach the exception trace:
2019-04-08 14:53:21.436 INFO [main]c.a.fescar.core.rpc.netty.AbstractRpcRemotingServer.start:153 -Server started ... Exception in thread "main" java.lang.RuntimeException: java.lang.IllegalArgumentException: hostname can't be null at com.alibaba.fescar.core.rpc.netty.AbstractRpcRemotingServer.start(AbstractRpcRemotingServer.java:158) at com.alibaba.fescar.core.rpc.netty.RpcServer.init(RpcServer.java:131) at ServerTest.main(ServerTest.java:46) Caused by: java.lang.IllegalArgumentException: hostname can't be null at java.net.InetSocketAddress.checkHost(InetSocketAddress.java:149) at java.net.InetSocketAddress.(InetSocketAddress.java:216)
at com.alibaba.fescar.core.rpc.netty.AbstractRpcRemotingServer.start(AbstractRpcRemotingServer.java:154)
... 2 more
2019-04-08 14:53:21.452 INFO [ShutdownHook]com.alibaba.fescar.core.rpc.netty.RpcServer.destroy:177 -destroyed rpcServer
Ⅲ. Describe what you expected to happen
Ⅳ. How to reproduce it (as minimally and precisely as possible)
Ⅴ. Anything else we need to know?
Ⅵ. Environment: