mirror of
https://github.com/alibaba/arthas.git
synced 2026-11-30 15:33:59 +00:00
redefine command check class if loaded.
This commit is contained in:
1 parent
2d9f12cbeb
commit
c93fb9d59b
1 file changed
+6
@@ -120,6 +120,12 @@ public class RedefineCommand extends AnnotatedCommand {
|
|||||||
}
|
}
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
if (definitions.isEmpty()) {
|
||||||
|
process.write("These classes are not found in the JVM and may not be loaded: " + bytesMap.keySet()
|
||||||
|
+ "\n");
|
||||||
|
process.end();
|
||||||
|
return;
|
||||||
|
}
|
||||||
inst.redefineClasses(definitions.toArray(new ClassDefinition[0]));
|
inst.redefineClasses(definitions.toArray(new ClassDefinition[0]));
|
||||||
process.write("redefine success, size: " + definitions.size() + "\n");
|
process.write("redefine success, size: " + definitions.size() + "\n");
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
|
|||||||
Reference in new issue
Block a user