HotSwapAgent - IncompatibleClassChangeError Type HeaderPanel$1 is not a nest member of HeaderPanel: current...












2















I have a problem w HotSwap Agent. It is not working correctly.



Setup:




  • JDK 11 from HotswapAgent.org

  • Widlfly 14

  • NetBeans 9

  • HotSwapAgent 1.3.1-SNAPSHOT


On start i



HOTSWAP AGENT: 08:17:59.098 INFO (org.hotswap.agent.HotswapAgent) - Loading Hotswap agent {1.3.1-SNAPSHOT} - unlimited runtime class redefinition.



In the middle i get a strange:



08:18:56,713 INFO [stdout] (ServerService Thread Pool -- 77) HOTSWAP AGENT: 08:18:56.713 WARNING (org.hotswap.agent.watch.nio.TreeWatcherNIO) - Unable to watch for path vfs:/C:/Java/wildfly-14.0.0.Final/bin/content/application.war/WEB-INF/classes/com/company/, not a local regular file or directory.



But it goes further ok. I change code, click apply code chages. It seemingly changes the code:



Classes to reload:
com.company.web.HeaderPanel$13
com.company.web.HeaderPanel$2
com.company.web.HeaderPanel$3
com.company.web.HeaderPanel$4
com.company.web.HeaderPanel
com.company.web.HeaderPanel$5
com.company.web.HeaderPanel$10
com.company.web.HeaderPanel$11
com.company.web.HeaderPanel$1
com.company.web.HeaderPanel$12
com.company.web.HeaderPanel$6
com.company.web.HeaderPanel$7
com.company.web.HeaderPanel$8
com.company.web.HeaderPanel$9

Code updated


In runtime it then throws an incompatible class change error when i go to the changed class:



java.lang.IncompatibleClassChangeError: Type com.company.web.HeaderPanel$1 is not a nest member of com.company.web.HeaderPanel: current type is not listed as a nest member
at deployment.application.war//com.company.web.HeaderPanel$1.onConfigure(HeaderPanel.java:110)


The relevant source code line is a overriden function in an anonymous class, the super. call:



 @Override
protected void onConfigure() {
super.onConfigure();
setVisible(!ssoService.isEnabled());
}


It is not the line i modified. I modified an completely different line.










share|improve this question


















  • 2





    Does "HotSwap Agent" have a mailing issue or issue tracker? It may not have been updated to work with JDK 11 yet, in particular it may not have been updated to support the class file attributes used to support nest-based access control (see JEP 181).

    – Alan Bateman
    Nov 19 '18 at 9:37













  • @AlanBateman Could this be for the reason stated in the JEP-181 as ... To preserve integrity of the nest it is proposed that, at least initially, it is prohibited to modify the nest classfile attributes using any form of class transformation or class redefinition. ?

    – nullpointer
    Nov 19 '18 at 9:54











  • @AlanBateman they support JDK11 - the have created a special distribution of JDK 11 that requires no configuration of the HotSwap agent - hotswapagent.org/mydoc_quickstart-jdk11.html . And i'm using this distribution.

    – Robert Niestroj
    Nov 19 '18 at 10:05






  • 1





    @nullpointer the key point is, the nesting shouldn’t change for such a simple code modification. However, if it’s not the Agent failing to include the nesting attribute, perhaps, it’s the compiler. The compiler used to compile the modified code must have the same language level as used for compiling the original code.

    – Holger
    Nov 19 '18 at 12:04






  • 2





    @nullpointer exactly. The NestHost/NestMembers attributes are only present when compiling with Java 11 (or newer) target. Before Java 11, the access to private members of inner/outer classes was established with synthetic helper methods, so even if changing the nest classfile attributes was allowed, it still failed as the removal or addition of methods is not. In other words, the language level must stay the same (at least regarding <11 or ≥11).

    – Holger
    Nov 19 '18 at 13:05


















2















I have a problem w HotSwap Agent. It is not working correctly.



Setup:




  • JDK 11 from HotswapAgent.org

  • Widlfly 14

  • NetBeans 9

  • HotSwapAgent 1.3.1-SNAPSHOT


On start i



HOTSWAP AGENT: 08:17:59.098 INFO (org.hotswap.agent.HotswapAgent) - Loading Hotswap agent {1.3.1-SNAPSHOT} - unlimited runtime class redefinition.



In the middle i get a strange:



08:18:56,713 INFO [stdout] (ServerService Thread Pool -- 77) HOTSWAP AGENT: 08:18:56.713 WARNING (org.hotswap.agent.watch.nio.TreeWatcherNIO) - Unable to watch for path vfs:/C:/Java/wildfly-14.0.0.Final/bin/content/application.war/WEB-INF/classes/com/company/, not a local regular file or directory.



But it goes further ok. I change code, click apply code chages. It seemingly changes the code:



Classes to reload:
com.company.web.HeaderPanel$13
com.company.web.HeaderPanel$2
com.company.web.HeaderPanel$3
com.company.web.HeaderPanel$4
com.company.web.HeaderPanel
com.company.web.HeaderPanel$5
com.company.web.HeaderPanel$10
com.company.web.HeaderPanel$11
com.company.web.HeaderPanel$1
com.company.web.HeaderPanel$12
com.company.web.HeaderPanel$6
com.company.web.HeaderPanel$7
com.company.web.HeaderPanel$8
com.company.web.HeaderPanel$9

Code updated


In runtime it then throws an incompatible class change error when i go to the changed class:



java.lang.IncompatibleClassChangeError: Type com.company.web.HeaderPanel$1 is not a nest member of com.company.web.HeaderPanel: current type is not listed as a nest member
at deployment.application.war//com.company.web.HeaderPanel$1.onConfigure(HeaderPanel.java:110)


The relevant source code line is a overriden function in an anonymous class, the super. call:



 @Override
protected void onConfigure() {
super.onConfigure();
setVisible(!ssoService.isEnabled());
}


It is not the line i modified. I modified an completely different line.










share|improve this question


















  • 2





    Does "HotSwap Agent" have a mailing issue or issue tracker? It may not have been updated to work with JDK 11 yet, in particular it may not have been updated to support the class file attributes used to support nest-based access control (see JEP 181).

    – Alan Bateman
    Nov 19 '18 at 9:37













  • @AlanBateman Could this be for the reason stated in the JEP-181 as ... To preserve integrity of the nest it is proposed that, at least initially, it is prohibited to modify the nest classfile attributes using any form of class transformation or class redefinition. ?

    – nullpointer
    Nov 19 '18 at 9:54











  • @AlanBateman they support JDK11 - the have created a special distribution of JDK 11 that requires no configuration of the HotSwap agent - hotswapagent.org/mydoc_quickstart-jdk11.html . And i'm using this distribution.

    – Robert Niestroj
    Nov 19 '18 at 10:05






  • 1





    @nullpointer the key point is, the nesting shouldn’t change for such a simple code modification. However, if it’s not the Agent failing to include the nesting attribute, perhaps, it’s the compiler. The compiler used to compile the modified code must have the same language level as used for compiling the original code.

    – Holger
    Nov 19 '18 at 12:04






  • 2





    @nullpointer exactly. The NestHost/NestMembers attributes are only present when compiling with Java 11 (or newer) target. Before Java 11, the access to private members of inner/outer classes was established with synthetic helper methods, so even if changing the nest classfile attributes was allowed, it still failed as the removal or addition of methods is not. In other words, the language level must stay the same (at least regarding <11 or ≥11).

    – Holger
    Nov 19 '18 at 13:05
















2












2








2








I have a problem w HotSwap Agent. It is not working correctly.



Setup:




  • JDK 11 from HotswapAgent.org

  • Widlfly 14

  • NetBeans 9

  • HotSwapAgent 1.3.1-SNAPSHOT


On start i



HOTSWAP AGENT: 08:17:59.098 INFO (org.hotswap.agent.HotswapAgent) - Loading Hotswap agent {1.3.1-SNAPSHOT} - unlimited runtime class redefinition.



In the middle i get a strange:



08:18:56,713 INFO [stdout] (ServerService Thread Pool -- 77) HOTSWAP AGENT: 08:18:56.713 WARNING (org.hotswap.agent.watch.nio.TreeWatcherNIO) - Unable to watch for path vfs:/C:/Java/wildfly-14.0.0.Final/bin/content/application.war/WEB-INF/classes/com/company/, not a local regular file or directory.



But it goes further ok. I change code, click apply code chages. It seemingly changes the code:



Classes to reload:
com.company.web.HeaderPanel$13
com.company.web.HeaderPanel$2
com.company.web.HeaderPanel$3
com.company.web.HeaderPanel$4
com.company.web.HeaderPanel
com.company.web.HeaderPanel$5
com.company.web.HeaderPanel$10
com.company.web.HeaderPanel$11
com.company.web.HeaderPanel$1
com.company.web.HeaderPanel$12
com.company.web.HeaderPanel$6
com.company.web.HeaderPanel$7
com.company.web.HeaderPanel$8
com.company.web.HeaderPanel$9

Code updated


In runtime it then throws an incompatible class change error when i go to the changed class:



java.lang.IncompatibleClassChangeError: Type com.company.web.HeaderPanel$1 is not a nest member of com.company.web.HeaderPanel: current type is not listed as a nest member
at deployment.application.war//com.company.web.HeaderPanel$1.onConfigure(HeaderPanel.java:110)


The relevant source code line is a overriden function in an anonymous class, the super. call:



 @Override
protected void onConfigure() {
super.onConfigure();
setVisible(!ssoService.isEnabled());
}


It is not the line i modified. I modified an completely different line.










share|improve this question














I have a problem w HotSwap Agent. It is not working correctly.



Setup:




  • JDK 11 from HotswapAgent.org

  • Widlfly 14

  • NetBeans 9

  • HotSwapAgent 1.3.1-SNAPSHOT


On start i



HOTSWAP AGENT: 08:17:59.098 INFO (org.hotswap.agent.HotswapAgent) - Loading Hotswap agent {1.3.1-SNAPSHOT} - unlimited runtime class redefinition.



In the middle i get a strange:



08:18:56,713 INFO [stdout] (ServerService Thread Pool -- 77) HOTSWAP AGENT: 08:18:56.713 WARNING (org.hotswap.agent.watch.nio.TreeWatcherNIO) - Unable to watch for path vfs:/C:/Java/wildfly-14.0.0.Final/bin/content/application.war/WEB-INF/classes/com/company/, not a local regular file or directory.



But it goes further ok. I change code, click apply code chages. It seemingly changes the code:



Classes to reload:
com.company.web.HeaderPanel$13
com.company.web.HeaderPanel$2
com.company.web.HeaderPanel$3
com.company.web.HeaderPanel$4
com.company.web.HeaderPanel
com.company.web.HeaderPanel$5
com.company.web.HeaderPanel$10
com.company.web.HeaderPanel$11
com.company.web.HeaderPanel$1
com.company.web.HeaderPanel$12
com.company.web.HeaderPanel$6
com.company.web.HeaderPanel$7
com.company.web.HeaderPanel$8
com.company.web.HeaderPanel$9

Code updated


In runtime it then throws an incompatible class change error when i go to the changed class:



java.lang.IncompatibleClassChangeError: Type com.company.web.HeaderPanel$1 is not a nest member of com.company.web.HeaderPanel: current type is not listed as a nest member
at deployment.application.war//com.company.web.HeaderPanel$1.onConfigure(HeaderPanel.java:110)


The relevant source code line is a overriden function in an anonymous class, the super. call:



 @Override
protected void onConfigure() {
super.onConfigure();
setVisible(!ssoService.isEnabled());
}


It is not the line i modified. I modified an completely different line.







java hotswap java-11 hotswapagent






share|improve this question













share|improve this question











share|improve this question




share|improve this question










asked Nov 19 '18 at 7:51









Robert NiestrojRobert Niestroj

7,86064579




7,86064579








  • 2





    Does "HotSwap Agent" have a mailing issue or issue tracker? It may not have been updated to work with JDK 11 yet, in particular it may not have been updated to support the class file attributes used to support nest-based access control (see JEP 181).

    – Alan Bateman
    Nov 19 '18 at 9:37













  • @AlanBateman Could this be for the reason stated in the JEP-181 as ... To preserve integrity of the nest it is proposed that, at least initially, it is prohibited to modify the nest classfile attributes using any form of class transformation or class redefinition. ?

    – nullpointer
    Nov 19 '18 at 9:54











  • @AlanBateman they support JDK11 - the have created a special distribution of JDK 11 that requires no configuration of the HotSwap agent - hotswapagent.org/mydoc_quickstart-jdk11.html . And i'm using this distribution.

    – Robert Niestroj
    Nov 19 '18 at 10:05






  • 1





    @nullpointer the key point is, the nesting shouldn’t change for such a simple code modification. However, if it’s not the Agent failing to include the nesting attribute, perhaps, it’s the compiler. The compiler used to compile the modified code must have the same language level as used for compiling the original code.

    – Holger
    Nov 19 '18 at 12:04






  • 2





    @nullpointer exactly. The NestHost/NestMembers attributes are only present when compiling with Java 11 (or newer) target. Before Java 11, the access to private members of inner/outer classes was established with synthetic helper methods, so even if changing the nest classfile attributes was allowed, it still failed as the removal or addition of methods is not. In other words, the language level must stay the same (at least regarding <11 or ≥11).

    – Holger
    Nov 19 '18 at 13:05
















  • 2





    Does "HotSwap Agent" have a mailing issue or issue tracker? It may not have been updated to work with JDK 11 yet, in particular it may not have been updated to support the class file attributes used to support nest-based access control (see JEP 181).

    – Alan Bateman
    Nov 19 '18 at 9:37













  • @AlanBateman Could this be for the reason stated in the JEP-181 as ... To preserve integrity of the nest it is proposed that, at least initially, it is prohibited to modify the nest classfile attributes using any form of class transformation or class redefinition. ?

    – nullpointer
    Nov 19 '18 at 9:54











  • @AlanBateman they support JDK11 - the have created a special distribution of JDK 11 that requires no configuration of the HotSwap agent - hotswapagent.org/mydoc_quickstart-jdk11.html . And i'm using this distribution.

    – Robert Niestroj
    Nov 19 '18 at 10:05






  • 1





    @nullpointer the key point is, the nesting shouldn’t change for such a simple code modification. However, if it’s not the Agent failing to include the nesting attribute, perhaps, it’s the compiler. The compiler used to compile the modified code must have the same language level as used for compiling the original code.

    – Holger
    Nov 19 '18 at 12:04






  • 2





    @nullpointer exactly. The NestHost/NestMembers attributes are only present when compiling with Java 11 (or newer) target. Before Java 11, the access to private members of inner/outer classes was established with synthetic helper methods, so even if changing the nest classfile attributes was allowed, it still failed as the removal or addition of methods is not. In other words, the language level must stay the same (at least regarding <11 or ≥11).

    – Holger
    Nov 19 '18 at 13:05










2




2





Does "HotSwap Agent" have a mailing issue or issue tracker? It may not have been updated to work with JDK 11 yet, in particular it may not have been updated to support the class file attributes used to support nest-based access control (see JEP 181).

– Alan Bateman
Nov 19 '18 at 9:37







Does "HotSwap Agent" have a mailing issue or issue tracker? It may not have been updated to work with JDK 11 yet, in particular it may not have been updated to support the class file attributes used to support nest-based access control (see JEP 181).

– Alan Bateman
Nov 19 '18 at 9:37















@AlanBateman Could this be for the reason stated in the JEP-181 as ... To preserve integrity of the nest it is proposed that, at least initially, it is prohibited to modify the nest classfile attributes using any form of class transformation or class redefinition. ?

– nullpointer
Nov 19 '18 at 9:54





@AlanBateman Could this be for the reason stated in the JEP-181 as ... To preserve integrity of the nest it is proposed that, at least initially, it is prohibited to modify the nest classfile attributes using any form of class transformation or class redefinition. ?

– nullpointer
Nov 19 '18 at 9:54













@AlanBateman they support JDK11 - the have created a special distribution of JDK 11 that requires no configuration of the HotSwap agent - hotswapagent.org/mydoc_quickstart-jdk11.html . And i'm using this distribution.

– Robert Niestroj
Nov 19 '18 at 10:05





@AlanBateman they support JDK11 - the have created a special distribution of JDK 11 that requires no configuration of the HotSwap agent - hotswapagent.org/mydoc_quickstart-jdk11.html . And i'm using this distribution.

– Robert Niestroj
Nov 19 '18 at 10:05




1




1





@nullpointer the key point is, the nesting shouldn’t change for such a simple code modification. However, if it’s not the Agent failing to include the nesting attribute, perhaps, it’s the compiler. The compiler used to compile the modified code must have the same language level as used for compiling the original code.

– Holger
Nov 19 '18 at 12:04





@nullpointer the key point is, the nesting shouldn’t change for such a simple code modification. However, if it’s not the Agent failing to include the nesting attribute, perhaps, it’s the compiler. The compiler used to compile the modified code must have the same language level as used for compiling the original code.

– Holger
Nov 19 '18 at 12:04




2




2





@nullpointer exactly. The NestHost/NestMembers attributes are only present when compiling with Java 11 (or newer) target. Before Java 11, the access to private members of inner/outer classes was established with synthetic helper methods, so even if changing the nest classfile attributes was allowed, it still failed as the removal or addition of methods is not. In other words, the language level must stay the same (at least regarding <11 or ≥11).

– Holger
Nov 19 '18 at 13:05







@nullpointer exactly. The NestHost/NestMembers attributes are only present when compiling with Java 11 (or newer) target. Before Java 11, the access to private members of inner/outer classes was established with synthetic helper methods, so even if changing the nest classfile attributes was allowed, it still failed as the removal or addition of methods is not. In other words, the language level must stay the same (at least regarding <11 or ≥11).

– Holger
Nov 19 '18 at 13:05














0






active

oldest

votes











Your Answer






StackExchange.ifUsing("editor", function () {
StackExchange.using("externalEditor", function () {
StackExchange.using("snippets", function () {
StackExchange.snippets.init();
});
});
}, "code-snippets");

StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "1"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});

function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});


}
});














draft saved

draft discarded


















StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53370380%2fhotswapagent-incompatibleclasschangeerror-type-headerpanel1-is-not-a-nest-mem%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown

























0






active

oldest

votes








0






active

oldest

votes









active

oldest

votes






active

oldest

votes
















draft saved

draft discarded




















































Thanks for contributing an answer to Stack Overflow!


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53370380%2fhotswapagent-incompatibleclasschangeerror-type-headerpanel1-is-not-a-nest-mem%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







這個網誌中的熱門文章

Tangent Lines Diagram Along Smooth Curve

Yusuf al-Mu'taman ibn Hud

Zucchini