Comments (7)
have you managed to solve the issue? I'm encountering same issue on the latest hotswap agent
from hotswapagent.
Guys did you manage to find a solution since I have the same issue?
from hotswapagent.
Guys did you manage to find a solution since I have the same issue?
I did manage to fix by disabling log4j in jvm args. I think one of threads I found in stackoverflow worked. can't recall what it was. however I'm not using it anymore but rather just using remote jvm feature in intelliJ. It's built in and works well.
from hotswapagent.
Hotswap itself does not work either
[14:55:06 INFO]: [STDOUT] [org.hotswap.agent.logging.AgentLoggerHandler] HOTSWAP AGENT: 14:55:06.223 ERROR (org.hotswap.agent.plugin.jdk.JdkPlugin) - classReload() exception No such field java.beans.Introspector.declaredMethodCache on null.
[14:55:06 INFO]: [STDOUT] [org.hotswap.agent.logging.AgentLoggerHandler] HOTSWAP AGENT: 14:55:06.224 ERROR (org.hotswap.agent.plugin.jdk.JdkPlugin) - classReload() exception class java.io.ObjectStreamClass$Caches$1 cannot be cast to class java.util.Map (java.io.ObjectStreamClass$Caches$1 and java.util.Map are in module java.base of loader 'bootstrap').
[14:55:06 INFO]: [STDOUT] [org.hotswap.agent.logging.AgentLoggerHandler] HOTSWAP AGENT: 14:55:06.229 ERROR (org.hotswap.agent.annotation.handler.PluginClassFileTransformer) - InvocationTargetException in transform method on plugin 'class org.hotswap.agent.plugin.proxy.ProxyPlugin' class 'dev/h4kt/randomActivities/commands/CommandActivity'.
java.lang.reflect.InvocationTargetException
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:568)
at org.hotswap.agent.annotation.handler.PluginClassFileTransformer.transform(PluginClassFileTransformer.java:218)
at org.hotswap.agent.annotation.handler.PluginClassFileTransformer.transform(PluginClassFileTransformer.java:112)
at org.hotswap.agent.util.HotswapTransformer.transform(HotswapTransformer.java:246)
at java.instrument/java.lang.instrument.ClassFileTransformer.transform(ClassFileTransformer.java:244)
at java.instrument/sun.instrument.TransformerManager.transform(TransformerManager.java:188)
at java.instrument/sun.instrument.InstrumentationImpl.transform(InstrumentationImpl.java:541)
Caused by: java.lang.NoClassDefFoundError: org/hotswap/agent/logging/AgentLogger
at RandomActivities-1.0.jar//org.hotswap.agent.plugin.proxy.hscglib.GeneratorParametersRecorder.<clinit>(GeneratorParametersRecorder.java:38)
at java.base/jdk.internal.misc.Unsafe.ensureClassInitialized0(Native Method)
at java.base/jdk.internal.misc.Unsafe.ensureClassInitialized(Unsafe.java:1155)
at java.base/jdk.internal.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:42)
at java.base/jdk.internal.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:185)
at java.base/java.lang.reflect.Field.acquireFieldAccessor(Field.java:1132)
at java.base/java.lang.reflect.Field.getFieldAccessor(Field.java:1113)
at java.base/java.lang.reflect.Field.get(Field.java:425)
at org.hotswap.agent.plugin.proxy.hscglib.GeneratorParametersTransformer.getGeneratorParamsMap(GeneratorParametersTransformer.java:103)
at org.hotswap.agent.plugin.proxy.hscglib.GeneratorParametersTransformer.getGeneratorParams(GeneratorParametersTransformer.java:130)
at org.hotswap.agent.plugin.proxy.ProxyPlugin.transformCglibProxy(ProxyPlugin.java:105)
... 10 more
Caused by: java.lang.ClassNotFoundException: org.hotswap.agent.logging.AgentLogger
at io.papermc.paper.plugin.entrypoint.classloader.PaperPluginClassLoader.loadClass(PaperPluginClassLoader.java:142)
at io.papermc.paper.plugin.entrypoint.classloader.PaperPluginClassLoader.loadClass(PaperPluginClassLoader.java:103)
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:525)
... 21 more
from hotswapagent.
The AgentLogger issue (at least on debugging Minecraft plugins) can be "fixed" by disabling the Proxy plugin.
-javaagent:/route/to/jbr/lib/hotswap/hotswap-agent.jar=disablePlugin=log4j2,disablePlugin=proxy
from hotswapagent.
I just recompiled the hotswap agent with all the stuff I don't need removed and it does work now, with zero issues.
from hotswapagent.
I faced the same thing as you guys. I explained in my videos that only core, not fatjar works for me. Use core.
This was specifically how I set it up for Paper: https://youtu.be/yQVLT6sDg68
And this is just generally how I got it working for Java 21: https://youtu.be/iQSvTkyiIDY
from hotswapagent.
Related Issues (20)
- Mybatis was introduced into the project, and the properties prompt was updated: No qualifying bean of type 'org.springframework.core.env.ConfigurableEnvironment' available HOT 3
- java -jar update mybatis failure HOT 2
- nested exception HOT 1
- Help, the new Controller API interface cannot be hot updated. HOT 4
- 1.4.2-SNAPSHOT (2024-03-16) release: org.hotswap.agent.javassist.NotFoundException: invokeCustomInitMethod(..) is not found in org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory HOT 4
- 1.4.2-SNAPSHOT inner class hotswap fail HOT 2
- final static variable values duplicates when hot swap HOT 1
- Update xml sql in mybatis + spring boot project error and will not take effect HOT 3
- AnonymousClassPatchPlugin IllegalArgumentException
- Spring Plugin with Grails hitting a snag
- How should I debug the modified class? HOT 1
- change mybatis xml it is not working ,log like this HOT 2
- HOTSWAP AGENT: 09:34:24.247 ERROR (org.hotswap.agent.annotation.handler.PluginClassFileTransformer) - InvocationTargetException in transform method on plugin 'class org.hotswap.agent.plugin.spring.boot.SpringBootPlugin' class 'org/springframework/core/env/MapPropertySource' of classLoader 'org.apache.catalina.loader.ParallelWebappClassLoader' java.lang.reflect.InvocationTargetException HOT 5
- Release 1.4.2 HOT 1
- Use retransformClasses to replace redefineClasses to avoid bytecode update failure. HOT 3
- Solution to java.lang.NoSuchMethodException for org.zkoss.zel.BeanELResolver.__resetCache() in ZKPlugin HOT 1
- java.lang.NoSuchFieldException: ucp error while running with JetBrainsRuntime 17 HOT 9
- IDEA plugin: Enable reloading of only a selected subset of changed files HOT 8
- Old version mybatis-plus doesn't work HOT 7
- could i add the intellij HotSwapHelper plugin to readme IDE support part? HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from hotswapagent.