(wrong name: com/springaop/service/impl/AopMethodimpl)报错

本文探讨了在使用Spring框架时遇到的Error loading class异常,具体表现为无法正确加载定义在配置文件bean.xml中的com.springaop.service.impl.AopMethodImpl类。问题根源在于类文件名拼写错误或依赖项缺失,并提供了可能的解决方向。

在做sping等框架时出现Error loading class [com.springaop.service.impl.AopMethodImpl] for bean with name 'aopmethodtarget' defined in class path resource [bean.xml]: problem with class file or dependent class; nested exception is java.lang.NoClassDefFoundError: com/springaop/service/impl/AopMethodImpl (wrong name: com/springaop/service/impl/AopMethodimpl)错误,配置文件中的映射路径有误,比如类文件名写错...

2025-09-25 15:39:36.642 [reactor-http-nio-2] DEBUG reactor.netty.http.server.HttpServerOperations - [a730687a, L:/127.0.0.1:9002 - R:/127.0.0.1:34542] New http connection, requesting read 2025-09-25 15:39:36.642 [reactor-http-nio-2] DEBUG reactor.netty.transport.TransportConfig - [a730687a, L:/127.0.0.1:9002 - R:/127.0.0.1:34542] Initialized pipeline DefaultChannelPipeline{(reactor.left.httpCodec = io.netty.handler.codec.http.HttpServerCodec), (reactor.left.httpTrafficHandler = reactor.netty.http.server.HttpTrafficHandler), (reactor.right.reactiveBridge = reactor.netty.channel.ChannelOperationsHandler)} 2025-09-25 15:39:36.698 [reactor-http-nio-2] DEBUG reactor.netty.http.server.HttpServerOperations - [a730687a, L:/127.0.0.1:9002 - R:/127.0.0.1:34542] Increasing pending responses, now 1 2025-09-25 15:39:36.738 [reactor-http-nio-2] DEBUG reactor.netty.http.server.HttpServer - [a730687a-1, L:/127.0.0.1:9002 - R:/127.0.0.1:34542] Handler is being applied: org.springframework.http.server.reactive.ReactorHttpHandlerAdapter@5a1f40cc 2025-09-25 15:39:36.823 [reactor-http-nio-2] DEBUG o.s.web.server.adapter.HttpWebHandlerAdapter - [a730687a-1] HTTP POST "/asn/main/query" 2025-09-25 15:39:36.873 [reactor-http-nio-2] DEBUG o.s.w.r.r.m.a.RequestMappingHandlerMapping - [a730687a-1] Mapped to com.hvlink.controller.AsnMainController#queryPage(AsnParam) 2025-09-25 15:39:36.907 [reactor-http-nio-2] DEBUG o.s.w.r.r.m.a.RequestBodyMethodArgumentResolver - [a730687a-1] Content-Type:application/json 2025-09-25 15:39:36.924 [reactor-http-nio-2] DEBUG o.s.w.r.r.m.a.RequestBodyMethodArgumentResolver - [a730687a-1] 0..1 [com.hvlink.entity.param.asn.AsnParam] 2025-09-25 15:39:36.979 [reactor-http-nio-2] DEBUG reactor.netty.channel.FluxReceive - [a730687a-1, L:/127.0.0.1:9002 - R:/127.0.0.1:34542] [terminated=false, cancelled=false, pending=0, error=null]: subscribing inbound receiver 2025-09-25 15:39:37.077 [reactor-http-nio-2] DEBUG o.s.http.codec.json.Jackson2JsonDecoder - [a730687a-1] Decoded [AsnParam(factoryCode=null, factoryName=null, asnNo=null, partCode=null, partDesc=null, shipperName=n (truncated)...] 2025-09-25 15:39:37.178 [reactor-http-nio-2] DEBUG org.mybatis.spring.SqlSessionUtils - Creating a new SqlSession 2025-09-25 15:39:37.231 [reactor-http-nio-2] DEBUG org.mybatis.spring.SqlSessionUtils - SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@4a4da851] was not registered for synchronization because synchronization is not active 2025-09-25 15:39:37.866 [reactor-http-nio-2] DEBUG o.springframework.jdbc.datasource.DataSourceUtils - Fetching JDBC Connection from DataSource 2025-09-25 15:39:37.866 [reactor-http-nio-2] DEBUG o.m.spring.transaction.SpringManagedTransaction - JDBC Connection [ConnectionID:1 ClientConnectionId: 07ff3887-4115-4e1d-b198-03c5b1118714] will not be managed by Spring 2025-09-25 15:39:37.886 [reactor-http-nio-2] DEBUG c.h.mapper.asn.AsnMainMapper.queryAsnPage_mpCount - ==> Preparing: SELECT COUNT(*) AS total FROM tb_asn_main am WHERE am.is_deleted = 0 2025-09-25 15:39:38.038 [reactor-http-nio-2] DEBUG c.h.mapper.asn.AsnMainMapper.queryAsnPage_mpCount - ==> Parameters: 2025-09-25 15:39:38.169 [reactor-http-nio-2] DEBUG c.h.mapper.asn.AsnMainMapper.queryAsnPage_mpCount - <== Total: 1 2025-09-25 15:39:38.179 [reactor-http-nio-2] DEBUG com.hvlink.mapper.asn.AsnMainMapper.queryAsnPage - ==> Preparing: SELECT am.id, am.factory_code, am.warehouse_code, am.shipper_id, am.asn_no, am.status, am.production_batch, am.shipping_date, am.estimated_arrival_date, am.estimated_consumption_time, am.is_first_product, am.is_fully_shipping, am.release_date, am.is_deleted, am.create_user, am.update_user, am.create_time, am.update_time, f.factory_name, w.warehouse_name, s.shipper_name, sup.supplier_code, sup.supplier_name FROM tb_asn_main am LEFT JOIN tm_factory f ON am.factory_code = f.factory_code LEFT JOIN tm_warehouse w ON am.warehouse_code = w.warehouse_code LEFT JOIN tm_shipper s ON am.shipper_id = s.id LEFT JOIN tm_supplier sup ON s.supplier_code = sup.supplier_code WHERE am.is_deleted = 0 ORDER BY am.create_time DESC, am.asn_no DESC OFFSET ? ROWS FETCH NEXT ? ROWS ONLY 2025-09-25 15:39:38.203 [reactor-http-nio-2] DEBUG com.hvlink.mapper.asn.AsnMainMapper.queryAsnPage - ==> Parameters: 0(Long), 10(Long) 2025-09-25 15:39:38.328 [reactor-http-nio-2] DEBUG com.hvlink.mapper.asn.AsnMainMapper.queryAsnPage - <== Total: 10 2025-09-25 15:39:38.328 [reactor-http-nio-2] DEBUG org.mybatis.spring.SqlSessionUtils - Closing non transactional SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@4a4da851] 2025-09-25 15:39:38.364 [reactor-http-nio-2] ERROR com.hvlink.controller.AsnMainController - ASN查询失败 org.apache.ibatis.binding.BindingException: Invalid bound statement (not found): com.hvlink.mapper.asn.AsnDetailMapper.queryDetailsByAsnNos at org.apache.ibatis.binding.MapperMethod$SqlCommand.<init>(MapperMethod.java:235) at com.baomidou.mybatisplus.core.override.MybatisMapperMethod.<init>(MybatisMapperMethod.java:50) at com.baomidou.mybatisplus.core.override.MybatisMapperProxy.lambda$cachedInvoker$0(MybatisMapperProxy.java:111) at java.util.concurrent.ConcurrentHashMap.computeIfAbsent(ConcurrentHashMap.java:1660) at com.baomidou.mybatisplus.core.toolkit.CollectionUtils.computeIfAbsent(CollectionUtils.java:115) at com.baomidou.mybatisplus.core.override.MybatisMapperProxy.cachedInvoker(MybatisMapperProxy.java:98) at com.baomidou.mybatisplus.core.override.MybatisMapperProxy.invoke(MybatisMapperProxy.java:89) at com.sun.proxy.$Proxy114.queryDetailsByAsnNos(Unknown Source) at com.hvlink.service.impl.AsnMainServiceImpl.queryPage(AsnMainServiceImpl.java:348) at com.hvlink.service.impl.AsnMainServiceImpl$$FastClassBySpringCGLIB$$906a1c7c.invoke(<generated>) at org.springframework.cglib.proxy.MethodProxy.invoke(MethodProxy.java:218) at org.springframework.aop.framework.CglibAopProxy.invokeMethod(CglibAopProxy.java:386) at org.springframework.aop.framework.CglibAopProxy.access$000(CglibAopProxy.java:85) at org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:703) at com.hvlink.service.impl.AsnMainServiceImpl$$EnhancerBySpringCGLIB$$47be6e4b.queryPage(<generated>) at com.hvlink.controller.AsnMainController.queryPage(AsnMainController.java:51) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at org.springframework.web.reactive.result.method.InvocableHandlerMethod.lambda$invoke$0(InvocableHandlerMethod.java:145) at reactor.core.publisher.MonoFlatMap$FlatMapMain.onNext(MonoFlatMap.java:125) at reactor.core.publisher.FluxOnAssembly$OnAssemblySubscriber.onNext(FluxOnAssembly.java:539) at reactor.core.publisher.Operators$MonoSubscriber.complete(Operators.java:1839) at reactor.core.publisher.MonoZip$ZipCoordinator.signal(MonoZip.java:258) at reactor.core.publisher.MonoZip$ZipInner.onNext(MonoZip.java:347) at reactor.core.publisher.FluxOnAssembly$OnAssemblySubscriber.onNext(FluxOnAssembly.java:539) at reactor.core.publisher.MonoPeekTerminal$MonoTerminalPeekSubscriber.onNext(MonoPeekTerminal.java:180) at reactor.core.publisher.FluxOnAssembly$OnAssemblySubscriber.onNext(FluxOnAssembly.java:539) at reactor.core.publisher.FluxDefaultIfEmpty$DefaultIfEmptySubscriber.onNext(FluxDefaultIfEmpty.java:101) at reactor.core.publisher.FluxOnAssembly$OnAssemblySubscriber.onNext(FluxOnAssembly.java:539) at reactor.core.publisher.FluxPeekFuseable$PeekFuseableSubscriber.onNext(FluxPeekFuseable.java:210) at reactor.core.publisher.FluxOnAssembly$OnAssemblySubscriber.onNext(FluxOnAssembly.java:539) at reactor.core.publisher.FluxSwitchIfEmpty$SwitchIfEmptySubscriber.onNext(FluxSwitchIfEmpty.java:74) at reactor.core.publisher.FluxOnAssembly$OnAssemblySubscriber.onNext(FluxOnAssembly.java:539) at reactor.core.publisher.FluxOnErrorResume$ResumeSubscriber.onNext(FluxOnErrorResume.java:79) at reactor.core.publisher.FluxOnAssembly$OnAssemblySubscriber.onNext(FluxOnAssembly.java:539) at reactor.core.publisher.Operators$MonoSubscriber.complete(Operators.java:1839) at reactor.core.publisher.MonoFlatMap$FlatMapMain.onNext(MonoFlatMap.java:151) at reactor.core.publisher.FluxContextWrite$ContextWriteSubscriber.onNext(FluxContextWrite.java:107) at reactor.core.publisher.FluxOnAssembly$OnAssemblySubscriber.onNext(FluxOnAssembly.java:539) at reactor.core.publisher.FluxMapFuseable$MapFuseableConditionalSubscriber.onNext(FluxMapFuseable.java:299) at reactor.core.publisher.FluxOnAssembly$OnAssemblySubscriber.onNext(FluxOnAssembly.java:539) at reactor.core.publisher.FluxFilterFuseable$FilterFuseableConditionalSubscriber.onNext(FluxFilterFuseable.java:337) at reactor.core.publisher.FluxOnAssembly$OnAssemblySubscriber.onNext(FluxOnAssembly.java:539) at reactor.core.publisher.Operators$MonoSubscriber.complete(Operators.java:1839) at reactor.core.publisher.MonoCollect$CollectSubscriber.onComplete(MonoCollect.java:160) at reactor.core.publisher.FluxOnAssembly$OnAssemblySubscriber.onComplete(FluxOnAssembly.java:549) at reactor.core.publisher.FluxMapFuseable$MapFuseableSubscriber.onComplete(FluxMapFuseable.java:152) at reactor.core.publisher.FluxOnAssembly$OnAssemblySubscriber.onComplete(FluxOnAssembly.java:549) at reactor.core.publisher.FluxPeekFuseable$PeekFuseableSubscriber.onComplete(FluxPeekFuseable.java:277) at reactor.core.publisher.FluxOnAssembly$OnAssemblySubscriber.onComplete(FluxOnAssembly.java:549) at reactor.core.publisher.FluxMap$MapSubscriber.onComplete(FluxMap.java:144) at reactor.netty.channel.FluxReceive.onInboundComplete(FluxReceive.java:415) at reactor.netty.channel.ChannelOperations.onInboundComplete(ChannelOperations.java:439) at reactor.netty.http.server.HttpServerOperations.onInboundNext(HttpServerOperations.java:656) at reactor.netty.channel.ChannelOperationsHandler.channelRead(ChannelOperationsHandler.java:114) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:444) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:420) at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:412) at reactor.netty.http.server.HttpTrafficHandler.channelRead(HttpTrafficHandler.java:276) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:442) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:420) at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:412) at io.netty.channel.CombinedChannelDuplexHandler$DelegatingChannelHandlerContext.fireChannelRead(CombinedChannelDuplexHandler.java:436) at io.netty.handler.codec.ByteToMessageDecoder.fireChannelRead(ByteToMessageDecoder.java:346) at io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:318) at io.netty.channel.CombinedChannelDuplexHandler.channelRead(CombinedChannelDuplexHandler.java:251) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:442) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:420) at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:412) at io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1410) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:440) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:420) at io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:919) at io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:166) at io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:788) at io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:724) at io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:650) at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:562) at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:997) at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74) at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30) at java.lang.Thread.run(Thread.java:750) 2025-09-25 15:39:38.373 [reactor-http-nio-2] DEBUG o.s.w.r.r.m.annotation.ResponseBodyResultHandler - [a730687a-1] Using 'application/json' given [*/*] and supported [application/json, application/*+json, application/x-ndjson, text/event-stream] 2025-09-25 15:39:38.373 [reactor-http-nio-2] DEBUG o.s.w.r.r.m.annotation.ResponseBodyResultHandler - [a730687a-1] 0..1 [com.hvlink.common.Result<com.hvlink.pagination.PageResult<com.hvlink.entity.vo.asn.AsnMainVO>>] 2025-09-25 15:39:38.426 [reactor-http-nio-2] DEBUG o.s.http.codec.json.Jackson2JsonEncoder - [a730687a-1] Encoding [Result(status=500, msg=ASN查询失败, data=null, timestamp=1758785978368)] 2025-09-25 15:39:38.489 [reactor-http-nio-2] DEBUG reactor.netty.http.server.HttpServerOperations - [a730687a-1, L:/127.0.0.1:9002 - R:/127.0.0.1:34542] Decreasing pending responses, now 0 2025-09-25 15:39:38.490 [reactor-http-nio-2] DEBUG reactor.netty.http.server.HttpServerOperations - [a730687a-1, L:/127.0.0.1:9002 - R:/127.0.0.1:34542] Last HTTP packet was sent, terminating the channel 2025-09-25 15:39:38.490 [reactor-http-nio-2] DEBUG reactor.netty.channel.ChannelOperations - [a730687a-1, L:/127.0.0.1:9002 - R:/127.0.0.1:34542] [HttpServer] Channel inbound receiver cancelled (operation cancelled). 2025-09-25 15:39:38.512 [reactor-http-nio-2] DEBUG o.s.web.server.adapter.HttpWebHandlerAdapter - [a730687a-1] Completed 200 OK 2025-09-25 15:39:38.518 [reactor-http-nio-2] DEBUG reactor.netty.http.server.HttpServerOperations - [a730687a-1, L:/127.0.0.1:9002 - R:/127.0.0.1:34542] Last HTTP response frame
最新发布
09-26
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值