java.lang.IllegalAccessError when attempting some operation

Still need help?

The Atlassian Community is here for you.

Ask the community

Platform notice: Server and Data Center only. This article only applies to Atlassian products on the Server and Data Center platforms.

Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.

*Except Fisheye and Crucible

Problem

When trying to perform some operation within the application - in this specific case a database migration - an error occurs and the following appears in the atlassian-bitbucket.log:

2016-04-06 15:00:00,002 ERROR [http-nio-8843-exec-9] @TOI4O4x919x2596x0 1qh0vkd 127.0.0.1 "GET /mvc/error500 HTTP/1.1" c.a.s.i.web.ErrorPageController There was an unhandled exception loading [/admin/db/edit]
org.springframework.web.util.NestedServletException: Handler processing failed; nested exception is java.lang.BootstrapMethodError: java.lang.IllegalAccessError: tried to access method com.atlassian.stash.internal.db.DbTypeBean.<init>(Lcom/atlassian/stash/internal/db/DbType;)V from class com.atlassian.stash.internal.db.DbTypeBean$$dtt
        at org.springframework.web.servlet.DispatcherServlet.triggerAfterCompletionWithError(DispatcherServlet.java:1303) ~[spring-webmvc-4.2.2.RELEASE.jar:4.2.2.RELEASE]
        at com.atlassian.applinks.core.rest.context.ContextFilter.doFilter(ContextFilter.java:26) ~[na:na]
        at com.atlassian.applinks.core.rest.context.ContextFilter.doFilter(ContextFilter.java:26) ~[na:na]
        at com.atlassian.applinks.core.rest.context.ContextFilter.doFilter(ContextFilter.java:26) ~[na:na]
        at com.atlassian.applinks.core.rest.context.ContextFilter.doFilter(ContextFilter.java:26) ~[na:na]
        at com.atlassian.applinks.core.rest.context.ContextFilter.doFilter(ContextFilter.java:26) ~[na:na]
        at com.atlassian.stash.internal.spring.security.StashAuthenticationFilter.doFilter(StashAuthenticationFilter.java:88) ~[StashAuthenticationFilter.class:na]
        at com.atlassian.stash.internal.web.auth.BeforeLoginPluginAuthenticationFilter.doInsideSpringSecurityChain(BeforeLoginPluginAuthenticationFilter.java:109) ~[BeforeLoginPluginAuthenticationFilter.class:na]
        at com.atlassian.stash.internal.web.auth.BeforeLoginPluginAuthenticationFilter.doFilter(BeforeLoginPluginAuthenticationFilter.java:75) ~[BeforeLoginPluginAuthenticationFilter.class:na]
        at com.atlassian.security.auth.trustedapps.filter.TrustedApplicationsFilter.doFilter(TrustedApplicationsFilter.java:94) ~[atlassian-trusted-apps-core-4.2.0.jar:na]
        at com.atlassian.oauth.serviceprovider.internal.servlet.OAuthFilter.doFilter(OAuthFilter.java:67) ~[na:na]
        at com.atlassian.security.auth.trustedapps.filter.TrustedApplicationsFilter.doFilter(TrustedApplicationsFilter.java:94) ~[atlassian-trusted-apps-core-4.2.0.jar:na]
        at com.atlassian.oauth.serviceprovider.internal.servlet.OAuthFilter.doFilter(OAuthFilter.java:67) ~[na:na]
        at com.atlassian.core.filters.ServletContextThreadLocalFilter.doFilter(ServletContextThreadLocalFilter.java:21) ~[atlassian-core-4.6.19.jar:na]
        at com.atlassian.core.filters.AbstractHttpFilter.doFilter(AbstractHttpFilter.java:31) ~[atlassian-core-4.6.19.jar:na]
        at com.atlassian.plugin.connect.plugin.auth.user.ThreeLeggedAuthFilter.doFilter(ThreeLeggedAuthFilter.java:122) ~[na:na]
        at com.atlassian.plugin.connect.plugin.auth.oauth.OAuth2LOFilter.doFilter(OAuth2LOFilter.java:82) ~[na:na]
        at com.atlassian.jwt.internal.servlet.JwtAuthFilter.doFilter(JwtAuthFilter.java:32) ~[na:na]
        at com.atlassian.analytics.client.filter.DefaultAnalyticsFilter.doFilter(DefaultAnalyticsFilter.java:36) ~[na:na]
        at com.atlassian.analytics.client.filter.AbstractHttpFilter.doFilter(AbstractHttpFilter.java:32) ~[na:na]
        at com.atlassian.stash.internal.web.auth.BeforeLoginPluginAuthenticationFilter.doBeforeBeforeLoginFilters(BeforeLoginPluginAuthenticationFilter.java:87) ~[BeforeLoginPluginAuthenticationFilter.class:na]
        at com.atlassian.stash.internal.web.auth.BeforeLoginPluginAuthenticationFilter.doFilter(BeforeLoginPluginAuthenticationFilter.java:73) ~[BeforeLoginPluginAuthenticationFilter.class:na]
        at com.atlassian.stash.internal.request.DefaultRequestManager.doAsRequest(DefaultRequestManager.java:85) ~[bitbucket-service-impl-4.3.2.jar:na]
        at com.atlassian.stash.internal.hazelcast.ConfigurableWebFilter.doFilter(ConfigurableWebFilter.java:38) ~[ConfigurableWebFilter.class:na]
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) [na:1.8.0_65]
        at java.lang.Thread.run(Thread.java:745) [na:1.8.0_65]
        ... 248 frames trimmed
Caused by: java.lang.BootstrapMethodError: java.lang.IllegalAccessError: tried to access method com.atlassian.stash.internal.db.DbTypeBean.<init>(Lcom/atlassian/stash/internal/db/DbType;)V from class com.atlassian.stash.internal.db.DbTypeBean$$dtt
        at com.atlassian.stash.internal.db.DbTypeBean$$dtt.dt_16_mclinitn_88(Unknown Source) ~[na:na]
        at com.atlassian.stash.internal.db.DbTypeBean.<clinit>(DbTypeBean.java:31) ~[bitbucket-service-api-4.3.2.jar:na]
        at com.atlassian.stash.internal.web.admin.DbConfigurationController.viewEditDbConfigForm(DbConfigurationController.java:148) ~[DbConfigurationController.class:na]
        ... 26 common frames omitted
Caused by: java.lang.IllegalAccessError: tried to access method com.atlassian.stash.internal.db.DbTypeBean.<init>(Lcom/atlassian/stash/internal/db/DbType;)V from class com.atlassian.stash.internal.db.DbTypeBean$$dtt
        at java.lang.invoke.MethodHandleNatives.resolve(Native Method) ~[na:1.8.0_65]
        at java.lang.invoke.MemberName$Factory.resolve(MemberName.java:962) ~[na:1.8.0_65]
        at java.lang.invoke.MemberName$Factory.resolveOrFail(MemberName.java:987) ~[na:1.8.0_65]
        at java.lang.invoke.MethodHandles$Lookup.resolveOrFail(MethodHandles.java:1390) ~[na:1.8.0_65]
        at java.lang.invoke.MethodHandles$Lookup.linkMethodHandleConstant(MethodHandles.java:1746) ~[na:1.8.0_65]
        at java.lang.invoke.MethodHandleNatives.linkMethodHandleConstant(MethodHandleNatives.java:477) ~[na:1.8.0_65]
        ... 29 common frames omitted

Cause

This specific occurrence was observed when having Dynatrace (profiling/performance management tool) running on the same server. It is possible that was interfering with some of the operations.

Workaround

Disable Dynatrace before performing the desired operation.

 

Last modified on Apr 7, 2016

Was this helpful?

Yes
No
Provide feedback about this article
Powered by Confluence and Scroll Viewport.