This is an automated email from the ASF dual-hosted git repository.
ehsavoie pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/netbeans.git
The following commit(s) were added to refs/heads/master by this push:
new d4eda26a38 [NETBEANS-4923]: Problem with Deploy/HotDeploy using
Netbeans 12.1 and Wildfly 18.0.1 for JAVAEE application.
new 0087cff309 Merge pull request #4768 from ehsavoie/NETBEANS-4923
d4eda26a38 is described below
commit d4eda26a38542d7fa371aa3e18296966f2cf226d
Author: Emmanuel Hugonnet <[email protected]>
AuthorDate: Tue Oct 11 11:16:25 2022 +0200
[NETBEANS-4923]: Problem with Deploy/HotDeploy using Netbeans 12.1 and
Wildfly 18.0.1 for JAVAEE application.
* Fixing classloading issue as the default classloader of ASM ClassWriter
didn't have access to WildFly classes.
Jira: https://issues.apache.org/jira/browse/NETBEANS-4923
---
.../netbeans/modules/javaee/wildfly/WildflyDeploymentFactory.java | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git
a/enterprise/javaee.wildfly/src/org/netbeans/modules/javaee/wildfly/WildflyDeploymentFactory.java
b/enterprise/javaee.wildfly/src/org/netbeans/modules/javaee/wildfly/WildflyDeploymentFactory.java
index a6b19245e8..c973bcc2bb 100644
---
a/enterprise/javaee.wildfly/src/org/netbeans/modules/javaee/wildfly/WildflyDeploymentFactory.java
+++
b/enterprise/javaee.wildfly/src/org/netbeans/modules/javaee/wildfly/WildflyDeploymentFactory.java
@@ -142,6 +142,7 @@ public class WildflyDeploymentFactory implements
DeploymentFactory {
String path = name.replace('.', '/').concat(".class"); //
NOI18N
try (InputStream is = super.getResourceAsStream(path)) {
ClassReader cr = new ClassReader(is);
+ final ClassLoader ld = this;
ClassWriter cw = new ClassWriter(cr,
ClassWriter.COMPUTE_FRAMES) {
@Override
@@ -152,6 +153,13 @@ public class WildflyDeploymentFactory implements
DeploymentFactory {
}
return super.getCommonSuperClass(string,
string1);
}
+
+ @Override
+ protected ClassLoader getClassLoader() {
+ return ld;
+ }
+
+
};
ClassNode node = new ClassNode(Opcodes.ASM9);
cr.accept(node, 0);
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists