Caused by: com.alibaba.dubbo.remoting.RemotingException

Caused by: com.alibaba.dubbo.remoting.RemotingException: Failed to bind NettyServer on /10.200.12.227:20896, cause: Failed to bind to: /0.0.0.0:20896
    at com.alibaba.dubbo.remoting.transport.AbstractServer.<init>(AbstractServer.java:68)
    at com.alibaba.dubbo.remoting.transport.netty.NettyServer.<init>(NettyServer.java:61)
    at com.alibaba.dubbo.remoting.transport.netty.NettyTransporter.bind(NettyTransporter.java:31)
    at com.alibaba.dubbo.remoting.Transporter$Adaptive.bind(Transporter$Adaptive.java)
    at com.alibaba.dubbo.remoting.Transporters.bind(Transporters.java:56)
    at com.alibaba.dubbo.remoting.exchange.support.header.HeaderExchanger.bind(HeaderExchanger.java:42)
    at com.alibaba.dubbo.remoting.exchange.Exchangers.bind(Exchangers.java:70)
    at com.alibaba.dubbo.rpc.protocol.dubbo.DubboProtocol.createServer(DubboProtocol.java:281)
    ... 55 more
Caused by: org.jboss.netty.channel.ChannelException: Failed to bind to: /0.0.0.0:20896
    at org.jboss.netty.bootstrap.ServerBootstrap.bind(ServerBootstrap.java:272)
    at com.alibaba.dubbo.remoting.transport.netty.NettyServer.doOpen(NettyServer.java:92)
    at com.alibaba.dubbo.remoting.transport.AbstractServer.<init>(AbstractServer.java:63)
    ... 62 more
Caused by: java.net.BindException: Address already in use: bind
    at sun.nio.ch.Net.bind0(Native Method)
    at sun.nio.ch.Net.bind(Net.java:433)
    at sun.nio.ch.Net.bind(Net.java:425)
    at sun.nio.ch.ServerSocketChannelImpl.bind(ServerSocketChannelImpl.java:223)
    at sun.nio.ch.ServerSocketAdaptor.bind(ServerSocketAdaptor.java:74)
    at org.jboss.netty.channel.socket.nio.NioServerBoss$RegisterTask.run(NioServerBoss.java:193)
    at org.jboss.netty.channel.socket.nio.AbstractNioSelector.processTaskQueue(AbstractNioSelector.java:391)
    at org.jboss.netty.channel.socket.nio.AbstractNioSelector.run(AbstractNioSelector.java:315)
    at org.jboss.netty.channel.socket.nio.NioServerBoss.run(NioServerBoss.java:42)
    at org.jboss.netty.util.ThreadRenamingRunnable.run(ThreadRenamingRunnable.java:108)
    at org.jboss.netty.util.internal.DeadLockProofWorker$1.run(DeadLockProofWorker.java:42)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
    at java.lang.Thread.run(Thread.java:748)
2019-12-16 09:18:24  INFO (org.springframework.scheduling.concurrent.ThreadPoolTaskExecutor:208) - Shutting down ExecutorService 'applicationTaskExecutor'
2019-12-16 09:18:24  INFO (com.erp.common.SpringBean:95) - ------->>>> destroy <<<<<------
2019-12-16 09:18:24 ERROR (org.springframework.test.context.TestContextManager:250) - Caught exception while allowing TestExecutionListener [org.springframework.test.context.web.ServletTestExecutionListener@16d04d3d] to prepare test instance [com.erp.TestControll@294a12b5]
java.lang.IllegalStateException: Failed to load ApplicationContext
    at org.springframework.test.context.cache.DefaultCacheAwareContextLoaderDelegate.loadContext(DefaultCacheAwareContextLoaderDelegate.java:125)
    at org.springframework.test.context.support.DefaultTestContext.getApplicationContext(DefaultTestContext.java:108)
    at org.springframework.test.context.web.ServletTestExecutionListener.setUpRequestContextIfNecessary(ServletTestExecutionListener.java:190)
    at org.springframework.test.context.web.ServletTestExecutionListener.prepareTestInstance(ServletTestExecutionListener.java:132)
    at org.springframework.test.context.TestContextManager.prepareTestInstance(TestContextManager.java:246)
    at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.createTest(SpringJUnit4ClassRunner.java:227)
    at org.springframework.test.context.junit4.SpringJUnit4ClassRunner$1.runReflectiveCall(SpringJUnit4ClassRunner.java:289)
    at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
    at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.methodBlock(SpringJUnit4ClassRunner.java:291)
    at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.runChild(SpringJUnit4ClassRunner.java:246)
    at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.runChild(SpringJUnit4ClassRunner.java:97)
    at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
    at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
    at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
    at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
    at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
    at org.springframework.test.context.junit4.statements.RunBeforeTestClassCallbacks.evaluate(RunBeforeTestClassCallbacks.java:61)
    at org.springframework.test.context.junit4.statements.RunAfterTestClassCallbacks.evaluate(RunAfterTestClassCallbacks.java:70)
    at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
    at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.run(SpringJUnit4ClassRunner.java:190)
    at org.junit.runner.JUnitCore.run(JUnitCore.java:137)
    at com.intellij.junit4.JUnit4IdeaTestRunner.startRunnerWithArgs(JUnit4IdeaTestRunner.java:68)
    at com.intellij.rt.execution.junit.IdeaTestRunner$Repeater.startRunnerWithArgs(IdeaTestRunner.java:47)
    at com.intellij.rt.execution.junit.JUnitStarter.prepareStreamsAndStart(JUnitStarter.java:242)
    at com.intellij.rt.execution.junit.JUnitStarter.main(JUnitStarter.java:70)
Caused by: com.alibaba.dubbo.rpc.RpcException: Fail to start server(url: dubbo://10.200.12.227:20896/com.interfaces.erp.BaseDataServer?anyhost=true&application=cloud-accounting-server&bind.ip=10.200.12.227&bind.port=20896&channel.readonly.sent=true&codec=dubbo&dubbo=2.6.1&generic=false&group=crm.dev&heartbeat=60000&interface=com.interfaces.erp.BaseDataServer&methods=nonTradePaymentCount,updateProductTypeInfo,addAreaInfo,addCurrencyInfo,getLayerHeightInfo,updateProductStateInfo,getCurrencyInfo,cooperationEmployeeInfoCount,customsBookCount,updateContractSmallInfo,getBuildingStructureInfo,getCustomsBook,addReceiveAmountClassInfo,getPositionInfo,getCustomsCreditLevel,updateSettleTypeInfo,addFloorAllInfo,updateLayerHeightInfo,getProductTypeInfo,getRegionInfo,floorAllInfoCount,getCityInfo,updateCurrencyInfo,getHqType,updateReceiveAmountClassInfo,financingInfoCount,addSettleTypeInfo,authorizationInfoCount,addBuildingStructureInfo,updateWLFProductTypeInfo,addNonTradePayment,getCooperationEmployeeInfo,updateGroundBlockNumberInfo,getIndustryMainType,addIndustryInfo,updateAreaInfo,addIndustryMainType,getFileList,updateIndustryMainType,addCityInfo,getContractSmallInfo,updateProductClassInfo,updateFloorAllInfo,customsCreditLevelCount,getFinancingInfo,updateNonTradePayment,updateMeasureUnitInfo,saveFileRelList,industryInfoCount,industrySubTypeCount,addIndustrySubType,updateFinancingInfo,getAuthorizationInfo,getFloorAllInfo,addCooperationEmployeeInfo,getFloorInfo,getIndustrySubType,getCooperationEmployeeList,addPositionInfo,updateProductPropertiesInfo,getFileRelList,buildingStructureInfoCount,addLayerHeightInfo,addGroundBlockNumberInfo,updateCustomsBook,positionInfoCount,addFloorInfo,updateBuildingStructureInfo,addCustomsCreditLevel,floorInfoCount,addFinancingInfo,updateProvinceInfo,addProductClassInfo,getContractBigInfo,countryInfoCount,productPropertiesInfoCount,getProductStateInfo,industryMainTypeCount,productTypeInfoCount,currencyInfoCount,addProvinceInfo,getProvinceInfo,layerHeightInfoCount,receiveAmountClassInfoCount,updateContractBigInfo,addContractSmallInfo,addProductTypeInfo,getGroundBlockNumberInfo,updateRegionInfo,addWLFProductTypeInfo,updateCityInfo,regionInfoCount,addAuthorizationInfo,hqTypeCount,provinceInfoCount,updateIndustrySubType,updateCustomsCreditLevel,getNonTradePayment,getMeasureUnitInfo,addMeasureUnitInfo,productClassInfoCount,saveUpdateFile,addRegionInfo,measureUnitInfoCount,updateCountryInfo,getAreaInfo,contractSmallInfoCount,updateFloorInfo,groundBlockNumberInfoCount,settleTypeInfoCount,getReceiveAmountClassInfo,addCustomsBook,contractBigInfoCount,getCountryInfo,updateCooperationEmployeeInfo,getSettleTypeInfo,getWLFProductTypeInfo,saveFile,areaInfoCount,deleteFileRelList,updateIndustryInfo,getProductPropertiesInfo,productStateInfoCount,addProductPropertiesInfo,getProductClassInfo,addHqType,updateHqType,updateAuthorizationInfo,cityInfoCount,addProductStateInfo,updatePositionInfo,getIndustryInfo,addContractBigInfo,wLFProductTypeInfoCount,addCountryInfo&pid=19352&revision=1.0.0&side=provider&timestamp=1576459104299&version=1.0.0) Failed to bind NettyServer on /10.200.12.227:20896, cause: Failed to bind to: /0.0.0.0:20896
    at com.alibaba.dubbo.rpc.protocol.dubbo.DubboProtocol.createServer(DubboProtocol.java:283)
    at com.alibaba.dubbo.rpc.protocol.dubbo.DubboProtocol.openServer(DubboProtocol.java:260)
    at com.alibaba.dubbo.rpc.protocol.dubbo.DubboProtocol.export(DubboProtocol.java:247)
    at com.alibaba.dubbo.qos.protocol.QosProtocolWrapper.export(QosProtocolWrapper.java:56)
    at com.alibaba.dubbo.rpc.protocol.ProtocolFilterWrapper.export(ProtocolFilterWrapper.java:93)
    at com.alibaba.dubbo.rpc.protocol.ProtocolListenerWrapper.export(ProtocolListenerWrapper.java:56)
    at com.alibaba.dubbo.rpc.Protocol$Adaptive.export(Protocol$Adaptive.java)
    at com.alibaba.dubbo.registry.integration.RegistryProtocol.doLocalExport(RegistryProtocol.java:166)
    at com.alibaba.dubbo.registry.integration.RegistryProtocol.export(RegistryProtocol.java:129)
    at com.alibaba.dubbo.qos.protocol.QosProtocolWrapper.export(QosProtocolWrapper.java:54)
    at com.alibaba.dubbo.rpc.protocol.ProtocolFilterWrapper.export(ProtocolFilterWrapper.java:91)
    at com.alibaba.dubbo.rpc.protocol.ProtocolListenerWrapper.export(ProtocolListenerWrapper.java:54)
    at com.alibaba.dubbo.rpc.Protocol$Adaptive.export(Protocol$Adaptive.java)
    at com.alibaba.dubbo.config.ServiceConfig.doExportUrlsFor1Protocol(ServiceConfig.java:505)
    at com.alibaba.dubbo.config.ServiceConfig.doExportUrls(ServiceConfig.java:357)
    at com.alibaba.dubbo.config.ServiceConfig.doExport(ServiceConfig.java:316)
    at com.alibaba.dubbo.config.ServiceConfig.export(ServiceConfig.java:215)
    at com.alibaba.dubbo.config.spring.ServiceBean.onApplicationEvent(ServiceBean.java:121)
    at com.alibaba.dubbo.config.spring.ServiceBean.onApplicationEvent(ServiceBean.java:50)
    at org.springframework.context.event.SimpleApplicationEventMulticaster.doInvokeListener(SimpleApplicationEventMulticaster.java:172)
    at org.springframework.context.event.SimpleApplicationEventMulticaster.invokeListener(SimpleApplicationEventMulticaster.java:165)
    at org.springframework.context.event.SimpleApplicationEventMulticaster.multicastEvent(SimpleApplicationEventMulticaster.java:139)
    at org.springframework.context.support.AbstractApplicationContext.publishEvent(AbstractApplicationContext.java:402)
    at org.springframework.context.support.AbstractApplicationContext.publishEvent(AbstractApplicationContext.java:359)
    at org.springframework.context.support.AbstractApplicationContext.finishRefresh(AbstractApplicationContext.java:896)
    at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:552)
    at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:742)
    at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:389)
    at org.springframework.boot.SpringApplication.run(SpringApplication.java:311)
    at org.springframework.boot.test.context.SpringBootContextLoader.loadContext(SpringBootContextLoader.java:119)
    at org.springframework.test.context.cache.DefaultCacheAwareContextLoaderDelegate.loadContextInternal(DefaultCacheAwareContextLoaderDelegate.java:99)
    at org.springframework.test.context.cache.DefaultCacheAwareContextLoaderDelegate.loadContext(DefaultCacheAwareContextLoaderDelegate.java:117)
    ... 24 more
Caused by: com.alibaba.dubbo.remoting.RemotingException: Failed to bind NettyServer on /10.200.12.227:20896, cause: Failed to bind to: /0.0.0.0:20896
    at com.alibaba.dubbo.remoting.transport.AbstractServer.<init>(AbstractServer.java:68)
    at com.alibaba.dubbo.remoting.transport.netty.NettyServer.<init>(NettyServer.java:61)
    at com.alibaba.dubbo.remoting.transport.netty.NettyTransporter.bind(NettyTransporter.java:31)
    at com.alibaba.dubbo.remoting.Transporter$Adaptive.bind(Transporter$Adaptive.java)
    at com.alibaba.dubbo.remoting.Transporters.bind(Transporters.java:56)
    at com.alibaba.dubbo.remoting.exchange.support.header.HeaderExchanger.bind(HeaderExchanger.java:42)
    at com.alibaba.dubbo.remoting.exchange.Exchangers.bind(Exchangers.java:70)
    at com.alibaba.dubbo.rpc.protocol.dubbo.DubboProtocol.createServer(DubboProtocol.java:281)
    ... 55 more
Caused by: org.jboss.netty.channel.ChannelException: Failed to bind to: /0.0.0.0:20896
    at org.jboss.netty.bootstrap.ServerBootstrap.bind(ServerBootstrap.java:272)
    at com.alibaba.dubbo.remoting.transport.netty.NettyServer.doOpen(NettyServer.java:92)
    at com.alibaba.dubbo.remoting.transport.AbstractServer.<init>(AbstractServer.java:63)
    ... 62 more
Caused by: java.net.BindException: Address already in use: bind
    at sun.nio.ch.Net.bind0(Native Method)
    at sun.nio.ch.Net.bind(Net.java:433)
    at sun.nio.ch.Net.bind(Net.java:425)
    at sun.nio.ch.ServerSocketChannelImpl.bind(ServerSocketChannelImpl.java:223)
    at sun.nio.ch.ServerSocketAdaptor.bind(ServerSocketAdaptor.java:74)
    at org.jboss.netty.channel.socket.nio.NioServerBoss$RegisterTask.run(NioServerBoss.java:193)
    at org.jboss.netty.channel.socket.nio.AbstractNioSelector.processTaskQueue(AbstractNioSelector.java:391)
    at org.jboss.netty.channel.socket.nio.AbstractNioSelector.run(AbstractNioSelector.java:315)
    at org.jboss.netty.channel.socket.nio.NioServerBoss.run(NioServerBoss.java:42)
    at org.jboss.netty.util.ThreadRenamingRunnable.run(ThreadRenamingRunnable.java:108)
    at org.jboss.netty.util.internal.DeadLockProofWorker$1.run(DeadLockProofWorker.java:42)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
    at java.lang.Thread.run(Thread.java:748)


原因:端口被佔用
netstat -ano 


然後使用下面命令結束進程就行了
taskkill /T /F /PID 4620 

 

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章