java.lang.IllegalArgumentException: java.lang.IllegalAccessException: Class com.atlassian.jira.webwork.JiraSafeActionParameterSetter can not access a member of class com.atlassian.jira.plugin.devstatus.we b.admin.AbstractProjectAdminAction with modifiers "public"

Atlassian JIRA | Oswaldo Hernandez [Atlassian] Bugmaster | 4 years ago
tip
Click on the to mark the solution that helps you, Samebug will learn from it.
As a community member, you’ll be rewarded for you help.
  1. 0

    Accessing the ConfigureDevStatus page on the Summit demo instance: http://summitdemo.dyn.syd.atlassian.com:2430/jira/secure/ConfigureDevStatus.jspa?projectKey=TIS gives an error page with the following exception: {code} com.google.template.soy.tofu.SoyTofuException: In template JIRA.Templates.DevStatus.Admin.projectAdminPage: In 'print' tag, expression "$projectKey" evaluates to undefined. at com.google.template.soy.tofu.internal.BaseTofu.renderMainHelper(BaseTofu.java:341) at com.google.template.soy.tofu.internal.BaseTofu.renderMain(BaseTofu.java:300) at com.google.template.soy.tofu.internal.BaseTofu.access$100(BaseTofu.java:56) at com.google.template.soy.tofu.internal.BaseTofu$RendererImpl.render(BaseTofu.java:427) at com.atlassian.soy.impl.DefaultSoyManager.render(DefaultSoyManager.java:111) at com.atlassian.soy.impl.SoyTemplateRendererImpl.render(SoyTemplateRendererImpl.java:40) at com.atlassian.soy.impl.SoyTemplateRendererImpl.render(SoyTemplateRendererImpl.java:33) at com.atlassian.jira.web.dispatcher.JiraSoyViewDispatcher.dispatch(JiraSoyViewDispatcher.java:36) at com.atlassian.jira.web.dispatcher.JiraWebworkViewDispatcher.dispatchViaSoyView(JiraWebworkViewDispatcher.java:148) at com.atlassian.jira.web.dispatcher.JiraWebworkViewDispatcher.dispatchView(JiraWebworkViewDispatcher.java:65) at com.atlassian.jira.web.dispatcher.JiraWebworkActionDispatcher.service(JiraWebworkActionDispatcher.java:204) at javax.servlet.http.HttpServlet.service(HttpServlet.java:722) {code} Following some troubleshooting, it was found that the root cause is the following exception: {code} java.lang.IllegalArgumentException: java.lang.IllegalAccessException: Class com.atlassian.jira.webwork.JiraSafeActionParameterSetter can not access a member of class com.atlassian.jira.plugin.devstatus.we b.admin.AbstractProjectAdminAction with modifiers "public" at com.atlassian.jira.webwork.JiraSafeActionParameterSetter.setActionProperty(JiraSafeActionParameterSetter.java:227) at com.atlassian.jira.webwork.JiraSafeActionParameterSetter.setSafeParameters(JiraSafeActionParameterSetter.java:129) at com.atlassian.jira.config.webwork.JiraActionFactory$SafeParameterSettingActionFactoryProxy.setActionParameters(JiraActionFactory.java:275) at com.atlassian.jira.config.webwork.JiraActionFactory$SafeParameterSettingActionFactoryProxy.getActionImpl(JiraActionFactory.java:162) at webwork.action.factory.ChainingActionFactoryProxy.getActionImpl(ChainingActionFactoryProxy.java:53) at com.atlassian.jira.config.webwork.JiraActionFactory.getActionImpl(JiraActionFactory.java:353) <+2> (GenericDispatcher.java:141) (JiraWebworkActionDispatcher.java:152) at javax.servlet.http.HttpServlet.service(HttpServlet.java:722) Caused by: java.lang.IllegalAccessException: Class com.atlassian.jira.webwork.JiraSafeActionParameterSetter can not access a member of class com.atlassian.jira.plugin.devstatus.web.admin.AbstractProjectAdminAction with modifiers "public" at sun.reflect.Reflection.ensureMemberAccess(Reflection.java:95) at java.lang.reflect.Method.invoke(Method.java:607) at com.atlassian.jira.webwork.JiraSafeActionParameterSetter.setActionProperty(JiraSafeActionParameterSetter.java:208) ... 174 more {code} It appears that JiraActionFactory was trying to call the setter method for projectKey but failed due to IllegalAccessException. In theory, in order to use reflection to invoke a public method, Java requires the class itself to be accessible by the caller. (https://vaadin.com/forum#!/thread/1414726/1416458) In our case, AbstractProjectAdminAction, which is the class that owns the setProjectKey method, has default/package access. :| Changing the class to public fixed the problem on the summitdemo instance. *But we need to figure out why it worked (and still works) on all other instances, including jdog and the jira-fusion OD instances.*

    Atlassian JIRA | 4 years ago | Oswaldo Hernandez [Atlassian] Bugmaster
    java.lang.IllegalArgumentException: java.lang.IllegalAccessException: Class com.atlassian.jira.webwork.JiraSafeActionParameterSetter can not access a member of class com.atlassian.jira.plugin.devstatus.we b.admin.AbstractProjectAdminAction with modifiers "public"
  2. 0

    Accessing the ConfigureDevStatus page on the Summit demo instance: http://summitdemo.dyn.syd.atlassian.com:2430/jira/secure/ConfigureDevStatus.jspa?projectKey=TIS gives an error page with the following exception: {code} com.google.template.soy.tofu.SoyTofuException: In template JIRA.Templates.DevStatus.Admin.projectAdminPage: In 'print' tag, expression "$projectKey" evaluates to undefined. at com.google.template.soy.tofu.internal.BaseTofu.renderMainHelper(BaseTofu.java:341) at com.google.template.soy.tofu.internal.BaseTofu.renderMain(BaseTofu.java:300) at com.google.template.soy.tofu.internal.BaseTofu.access$100(BaseTofu.java:56) at com.google.template.soy.tofu.internal.BaseTofu$RendererImpl.render(BaseTofu.java:427) at com.atlassian.soy.impl.DefaultSoyManager.render(DefaultSoyManager.java:111) at com.atlassian.soy.impl.SoyTemplateRendererImpl.render(SoyTemplateRendererImpl.java:40) at com.atlassian.soy.impl.SoyTemplateRendererImpl.render(SoyTemplateRendererImpl.java:33) at com.atlassian.jira.web.dispatcher.JiraSoyViewDispatcher.dispatch(JiraSoyViewDispatcher.java:36) at com.atlassian.jira.web.dispatcher.JiraWebworkViewDispatcher.dispatchViaSoyView(JiraWebworkViewDispatcher.java:148) at com.atlassian.jira.web.dispatcher.JiraWebworkViewDispatcher.dispatchView(JiraWebworkViewDispatcher.java:65) at com.atlassian.jira.web.dispatcher.JiraWebworkActionDispatcher.service(JiraWebworkActionDispatcher.java:204) at javax.servlet.http.HttpServlet.service(HttpServlet.java:722) {code} Following some troubleshooting, it was found that the root cause is the following exception: {code} java.lang.IllegalArgumentException: java.lang.IllegalAccessException: Class com.atlassian.jira.webwork.JiraSafeActionParameterSetter can not access a member of class com.atlassian.jira.plugin.devstatus.we b.admin.AbstractProjectAdminAction with modifiers "public" at com.atlassian.jira.webwork.JiraSafeActionParameterSetter.setActionProperty(JiraSafeActionParameterSetter.java:227) at com.atlassian.jira.webwork.JiraSafeActionParameterSetter.setSafeParameters(JiraSafeActionParameterSetter.java:129) at com.atlassian.jira.config.webwork.JiraActionFactory$SafeParameterSettingActionFactoryProxy.setActionParameters(JiraActionFactory.java:275) at com.atlassian.jira.config.webwork.JiraActionFactory$SafeParameterSettingActionFactoryProxy.getActionImpl(JiraActionFactory.java:162) at webwork.action.factory.ChainingActionFactoryProxy.getActionImpl(ChainingActionFactoryProxy.java:53) at com.atlassian.jira.config.webwork.JiraActionFactory.getActionImpl(JiraActionFactory.java:353) <+2> (GenericDispatcher.java:141) (JiraWebworkActionDispatcher.java:152) at javax.servlet.http.HttpServlet.service(HttpServlet.java:722) Caused by: java.lang.IllegalAccessException: Class com.atlassian.jira.webwork.JiraSafeActionParameterSetter can not access a member of class com.atlassian.jira.plugin.devstatus.web.admin.AbstractProjectAdminAction with modifiers "public" at sun.reflect.Reflection.ensureMemberAccess(Reflection.java:95) at java.lang.reflect.Method.invoke(Method.java:607) at com.atlassian.jira.webwork.JiraSafeActionParameterSetter.setActionProperty(JiraSafeActionParameterSetter.java:208) ... 174 more {code} It appears that JiraActionFactory was trying to call the setter method for projectKey but failed due to IllegalAccessException. In theory, in order to use reflection to invoke a public method, Java requires the class itself to be accessible by the caller. (https://vaadin.com/forum#!/thread/1414726/1416458) In our case, AbstractProjectAdminAction, which is the class that owns the setProjectKey method, has default/package access. :| Changing the class to public fixed the problem on the summitdemo instance. *But we need to figure out why it worked (and still works) on all other instances, including jdog and the jira-fusion OD instances.*

    Atlassian JIRA | 4 years ago | Oswaldo Hernandez [Atlassian] Bugmaster
    java.lang.IllegalArgumentException: java.lang.IllegalAccessException: Class com.atlassian.jira.webwork.JiraSafeActionParameterSetter can not access a member of class com.atlassian.jira.plugin.devstatus.we b.admin.AbstractProjectAdminAction with modifiers "public"

    Root Cause Analysis

    1. java.lang.IllegalArgumentException

      java.lang.IllegalAccessException: Class com.atlassian.jira.webwork.JiraSafeActionParameterSetter can not access a member of class com.atlassian.jira.plugin.devstatus.we b.admin.AbstractProjectAdminAction with modifiers "public"

      at com.atlassian.jira.webwork.JiraSafeActionParameterSetter.setActionProperty()
    2. com.atlassian.jira
      JiraActionFactory$SafeParameterSettingActionFactoryProxy.getActionImpl
      1. com.atlassian.jira.webwork.JiraSafeActionParameterSetter.setActionProperty(JiraSafeActionParameterSetter.java:227)
      2. com.atlassian.jira.webwork.JiraSafeActionParameterSetter.setSafeParameters(JiraSafeActionParameterSetter.java:129)
      3. com.atlassian.jira.config.webwork.JiraActionFactory$SafeParameterSettingActionFactoryProxy.setActionParameters(JiraActionFactory.java:275)
      4. com.atlassian.jira.config.webwork.JiraActionFactory$SafeParameterSettingActionFactoryProxy.getActionImpl(JiraActionFactory.java:162)
      4 frames
    3. webwork.action.factory
      ChainingActionFactoryProxy.getActionImpl
      1. webwork.action.factory.ChainingActionFactoryProxy.getActionImpl(ChainingActionFactoryProxy.java:53)
      1 frame