Closed kevinYin closed 7 years ago
应该是classloading问题。cat-client.jar中的/META-INF/plexus/components.xml找不到。
已经解决了,是maven-shade-plugin 插件引起的,多谢老吴
已经解决了,是maven-shade-plugin 插件引起的,要怎么解决呢,去掉这个插件吗
我换成别的插件了, 用dependency 或者 aseemly 都行,或者使用新版本2.0,老吴解决了这个问题
components 大佬,怎么解决的?
使用的是jdk1.8,resin4.1服务器,本地调用没有报错,配置文件正确远程调用爆以下错误:
异常如下: java.lang.RuntimeException: Unable to get component: interface org.unidal.initialization.Module. at org.unidal.initialization.DefaultModuleContext.lookup(DefaultModuleContext.java:98) at com.dianping.cat.Cat.initialize(Cat.java:112) at com.dianping.cat.Cat.initialize(Cat.java:107) at com.dianping.cat.Cat.checkAndInitialize(Cat.java:48) at com.dianping.cat.Cat.getProducer(Cat.java:98) at com.dianping.cat.Cat.newTransaction(Cat.java:315) at com.ibeiliao.statement.impl.provider.SummaryServiceProviderImpl.querySchoolDaily(SummaryServiceProviderImpl.java:35) at com.alibaba.dubbo.common.bytecode.Wrapper10.invokeMethod(Wrapper10.java) at com.alibaba.dubbo.rpc.proxy.javassist.JavassistProxyFactory$1.doInvoke(JavassistProxyFactory.java:46) at com.alibaba.dubbo.rpc.proxy.AbstractProxyInvoker.invoke(AbstractProxyInvoker.java:72) at com.alibaba.dubbo.rpc.protocol.InvokerWrapper.invoke(InvokerWrapper.java:53) at com.ibeiliao.platform.dubbo.filter.AuthorizationFilter.invoke(AuthorizationFilter.java:80) at com.alibaba.dubbo.rpc.protocol.ProtocolFilterWrapper$1.invoke(ProtocolFilterWrapper.java:91) at com.alibaba.dubbo.rpc.filter.ExceptionFilter.invoke(ExceptionFilter.java:64) at com.alibaba.dubbo.rpc.protocol.ProtocolFilterWrapper$1.invoke(ProtocolFilterWrapper.java:91) at com.alibaba.dubbo.monitor.support.MonitorFilter.invoke(MonitorFilter.java:75) at com.alibaba.dubbo.rpc.protocol.ProtocolFilterWrapper$1.invoke(ProtocolFilterWrapper.java:91) at com.alibaba.dubbo.rpc.filter.TimeoutFilter.invoke(TimeoutFilter.java:42) at com.alibaba.dubbo.rpc.protocol.ProtocolFilterWrapper$1.invoke(ProtocolFilterWrapper.java:91) at com.alibaba.dubbo.rpc.protocol.dubbo.filter.TraceFilter.invoke(TraceFilter.java:78) at com.alibaba.dubbo.rpc.protocol.ProtocolFilterWrapper$1.invoke(ProtocolFilterWrapper.java:91) at com.alibaba.dubbo.rpc.filter.ContextFilter.invoke(ContextFilter.java:60) at com.alibaba.dubbo.rpc.protocol.ProtocolFilterWrapper$1.invoke(ProtocolFilterWrapper.java:91) at com.alibaba.dubbo.rpc.filter.GenericFilter.invoke(GenericFilter.java:132) at com.alibaba.dubbo.rpc.protocol.ProtocolFilterWrapper$1.invoke(ProtocolFilterWrapper.java:91) at com.alibaba.dubbo.rpc.filter.ClassLoaderFilter.invoke(ClassLoaderFilter.java:38) at com.alibaba.dubbo.rpc.protocol.ProtocolFilterWrapper$1.invoke(ProtocolFilterWrapper.java:91) at com.alibaba.dubbo.rpc.filter.EchoFilter.invoke(EchoFilter.java:38) at com.alibaba.dubbo.rpc.protocol.ProtocolFilterWrapper$1.invoke(ProtocolFilterWrapper.java:91) at com.alibaba.dubbo.rpc.protocol.dubbo.DubboProtocol$1.reply(DubboProtocol.java:108) at com.alibaba.dubbo.remoting.exchange.support.header.HeaderExchangeHandler.handleRequest(HeaderExchangeHandler.java:84) at com.alibaba.dubbo.remoting.exchange.support.header.HeaderExchangeHandler.received(HeaderExchangeHandler.java:170) at com.alibaba.dubbo.remoting.transport.DecodeHandler.received(DecodeHandler.java:52) at com.alibaba.dubbo.remoting.transport.dispatcher.ChannelEventRunnable.run(ChannelEventRunnable.java:82) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745) Caused by: org.codehaus.plexus.component.repository.exception.ComponentLookupException: Component descriptor cannot be found in the component repository role: org.unidal.initialization.Module roleHint: cat-client classRealm: none specified at org.codehaus.plexus.DefaultComponentRegistry.getComponentManager(DefaultComponentRegistry.java:435) at org.codehaus.plexus.DefaultComponentRegistry.getComponent(DefaultComponentRegistry.java:353) at org.codehaus.plexus.DefaultComponentRegistry.lookup(DefaultComponentRegistry.java:178) at org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:388) at org.unidal.initialization.DefaultModuleContext.lookup(DefaultModuleContext.java:96) ... 36 more