java.lang.RuntimeException: Error opening/reading [/var/atlassian/application-data/stash/shared/data/repositories/1/refs/heads/master]

Atlassian JIRA | Peter Koczan | 1 year ago
  1. 0

    h4. Problem If you move your master branch then create one with a name like {{master/alternate}} instead then push it back to origin, Stash will throw a HTTP 500 error stating: {{Error opening/reading [/var/atlassian/application-data/stash/shared/data/repositories/1/refs/heads/master]}} The logs will show: {noformat} 2015-12-04 12:15:39,342 WARN [threadpool:thread-9] admin @6JC3HDx735x117x0 127.0.0.1 "POST /scm/test/testrepo.git/git-receive-pack HTTP/1.1" c.a.s.i.h.DefaultBuiltInHookHandlerFactory Hook com.atlas sian.stash.internal.plugin.hooks.branchlinks.PrintBranchLinksHook failed. java.lang.RuntimeException: Error opening/reading [/var/atlassian/application-data/stash/shared/data/repositories/1/refs/heads/master] at com.atlassian.stash.internal.scm.git.RawGitAgent.execute(RawGitAgent.java:260) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent.execute(RawGitAgent.java:251) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent.resolveBranch(RawGitAgent.java:368) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent.resolveHead(RawGitAgent.java:225) ~[na:na] at com.atlassian.stash.internal.scm.git.DefaultGitCommandFactory$1.call(DefaultGitCommandFactory.java:198) ~[na:na] at com.atlassian.stash.internal.scm.git.DefaultGitCommandFactory$1.call(DefaultGitCommandFactory.java:194) ~[na:na] at com.atlassian.stash.internal.repository.RepositoryMetadataServiceImpl.getDefaultBranch(RepositoryMetadataServiceImpl.java:93) ~[stash-service-impl-3.9.1.jar:na] at com.atlassian.stash.internal.plugin.hooks.branchlinks.PrintBranchLinksHook.getDefaultBranchId(PrintBranchLinksHook.java:66) ~[na:na] at com.atlassian.stash.internal.plugin.hooks.branchlinks.PrintBranchLinksHook.shouldPrint(PrintBranchLinksHook.java:57) ~[na:na] at com.atlassian.stash.internal.plugin.hooks.branchlinks.PrintBranchLinksHook.onReceive(PrintBranchLinksHook.java:44) ~[na:na] at com.atlassian.stash.internal.hook.DefaultBuiltInHookHandlerFactory$2.handle(DefaultBuiltInHookHandlerFactory.java:71) ~[stash-service-impl-3.9.1.jar:na] at com.atlassian.stash.internal.hook.DefaultHookService.doHandleRequest(DefaultHookService.java:345) [stash-service-impl-3.9.1.jar:na] at com.atlassian.stash.internal.hook.DefaultHookService.handleRequest(DefaultHookService.java:331) [stash-service-impl-3.9.1.jar:na] at com.atlassian.stash.internal.hook.DefaultHookService.handleRawRequest(DefaultHookService.java:239) [stash-service-impl-3.9.1.jar:na] at com.atlassian.stash.internal.hook.DefaultHookService$2$1.run(DefaultHookService.java:205) [stash-service-impl-3.9.1.jar:na] at com.atlassian.stash.internal.concurrent.StateTransferringExecutor$StateTransferringRunnable.run(StateTransferringExecutor.java:73) [stash-platform-3.9.1.jar:na] at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [na:1.8.0_66] at java.util.concurrent.FutureTask.run(FutureTask.java:266) [na:1.8.0_66] at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180) [na:1.8.0_66] at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293) [na:1.8.0_66] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) [na:1.8.0_66] at java.lang.Thread.run(Thread.java:745) [na:1.8.0_66] ... 66 frames trimmed Caused by: java.io.IOException: Is a directory at sun.nio.ch.FileDispatcherImpl.read0(Native Method) ~[na:1.8.0_66] at sun.nio.ch.FileDispatcherImpl.read(FileDispatcherImpl.java:46) ~[na:1.8.0_66] at sun.nio.ch.IOUtil.readIntoNativeBuffer(IOUtil.java:223) ~[na:1.8.0_66] at sun.nio.ch.IOUtil.read(IOUtil.java:197) ~[na:1.8.0_66] at sun.nio.ch.FileChannelImpl.read(FileChannelImpl.java:159) ~[na:1.8.0_66] at sun.nio.ch.ChannelInputStream.read(ChannelInputStream.java:65) ~[na:1.8.0_66] at sun.nio.ch.ChannelInputStream.read(ChannelInputStream.java:109) ~[na:1.8.0_66] at sun.nio.ch.ChannelInputStream.read(ChannelInputStream.java:103) ~[na:1.8.0_66] at sun.nio.cs.StreamDecoder.readBytes(StreamDecoder.java:284) ~[na:1.8.0_66] at sun.nio.cs.StreamDecoder.implRead(StreamDecoder.java:326) ~[na:1.8.0_66] at sun.nio.cs.StreamDecoder.read(StreamDecoder.java:178) ~[na:1.8.0_66] at java.io.InputStreamReader.read(InputStreamReader.java:184) ~[na:1.8.0_66] at java.io.BufferedReader.fill(BufferedReader.java:161) ~[na:1.8.0_66] at java.io.BufferedReader.readLine(BufferedReader.java:324) ~[na:1.8.0_66] at java.io.BufferedReader.readLine(BufferedReader.java:389) ~[na:1.8.0_66] at com.atlassian.stash.internal.scm.git.RawGitAgent$FirstLineCallback.doWithReader(RawGitAgent.java:473) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent$FirstLineCallback.doWithReader(RawGitAgent.java:469) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent.execute(RawGitAgent.java:256) ~[na:na] ... 22 common frames omitted 2015-12-04 12:15:46,723 ERROR [http-nio-7990-exec-3] admin @6JC3HDx735x118x0 151ydgu 127.0.0.1 "GET /projects/TEST/repos/testrepo/browse HTTP/1.1" c.a.s.i.w.HandlerExceptionResolverImpl Error opening/reading [/var/atlassian/application-data/stash/shared/data/repositories/1/refs/heads/master] java.lang.RuntimeException: Error opening/reading [/var/atlassian/application-data/stash/shared/data/repositories/1/refs/heads/master] at com.atlassian.stash.internal.scm.git.RawGitAgent.execute(RawGitAgent.java:260) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent.execute(RawGitAgent.java:251) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent.resolveBranch(RawGitAgent.java:368) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent.resolveHead(RawGitAgent.java:225) ~[na:na] at com.atlassian.stash.internal.scm.git.DefaultGitCommandFactory$1.call(DefaultGitCommandFactory.java:198) ~[na:na] at com.atlassian.stash.internal.scm.git.DefaultGitCommandFactory$1.call(DefaultGitCommandFactory.java:194) ~[na:na] at com.atlassian.stash.internal.repository.RepositoryMetadataServiceImpl.getDefaultBranch(RepositoryMetadataServiceImpl.java:93) ~[stash-service-impl-3.9.1.jar:na] at com.atlassian.stash.internal.web.repos.RepositoryController.browseFilePath(RepositoryController.java:271) ~[RepositoryController.class:na] at com.atlassian.applinks.core.rest.context.ContextFilter.doFilter(ContextFilter.java:25) [applinks-plugin-4.3.5_1427859172000.jar:na] at com.atlassian.stash.internal.spring.security.StashAuthenticationFilter.doFilter(StashAuthenticationFilter.java:83) [StashAuthenticationFilter.class:na] at com.atlassian.stash.internal.web.auth.BeforeLoginPluginAuthenticationFilter.doInsideSpringSecurityChain(BeforeLoginPluginAuthenticationFilter.java:111) [BeforeLoginPluginAuthenticationFilter.class:na] at com.atlassian.stash.internal.web.auth.BeforeLoginPluginAuthenticationFilter.doFilter(BeforeLoginPluginAuthenticationFilter.java:77) [BeforeLoginPluginAuthenticationFilter.class:na] at com.atlassian.security.auth.trustedapps.filter.TrustedApplicationsFilter.doFilter(TrustedApplicationsFilter.java:103) [atlassian-trusted-apps-core-4.0.0.jar:na] at com.atlassian.oauth.serviceprovider.internal.servlet.OAuthFilter.doFilter(OAuthFilter.java:79) [atlassian-oauth-service-provider-plugin-1.9.10_1427859174000.jar:na] at com.atlassian.analytics.client.filter.DefaultAnalyticsFilter.doFilter(DefaultAnalyticsFilter.java:32) [analytics-client-3.65.1_1428700568000.jar:na] at com.atlassian.analytics.client.filter.AbstractHttpFilter.doFilter(AbstractHttpFilter.java:32) [analytics-client-3.65.1_1428700568000.jar:na] at com.atlassian.stash.internal.web.auth.BeforeLoginPluginAuthenticationFilter.doBeforeBeforeLoginFilters(BeforeLoginPluginAuthenticationFilter.java:89) [BeforeLoginPluginAuthenticationFilter.class:na] at com.atlassian.stash.internal.web.auth.BeforeLoginPluginAuthenticationFilter.doFilter(BeforeLoginPluginAuthenticationFilter.java:75) [BeforeLoginPluginAuthenticationFilter.class:na] at com.atlassian.stash.internal.request.DefaultRequestManager.doAsRequest(DefaultRequestManager.java:85) [stash-service-impl-3.9.1.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_66] at java.lang.Thread.run(Thread.java:745) [na:1.8.0_66] ... 273 frames trimmed Caused by: java.io.IOException: Is a directory at sun.nio.ch.FileDispatcherImpl.read0(Native Method) ~[na:1.8.0_66] at sun.nio.ch.FileDispatcherImpl.read(FileDispatcherImpl.java:46) ~[na:1.8.0_66] at sun.nio.ch.IOUtil.readIntoNativeBuffer(IOUtil.java:223) ~[na:1.8.0_66] at sun.nio.ch.IOUtil.read(IOUtil.java:197) ~[na:1.8.0_66] at sun.nio.ch.FileChannelImpl.read(FileChannelImpl.java:159) ~[na:1.8.0_66] at sun.nio.ch.ChannelInputStream.read(ChannelInputStream.java:65) ~[na:1.8.0_66] at sun.nio.ch.ChannelInputStream.read(ChannelInputStream.java:109) ~[na:1.8.0_66] at sun.nio.ch.ChannelInputStream.read(ChannelInputStream.java:103) ~[na:1.8.0_66] at sun.nio.cs.StreamDecoder.readBytes(StreamDecoder.java:284) ~[na:1.8.0_66] at sun.nio.cs.StreamDecoder.implRead(StreamDecoder.java:326) ~[na:1.8.0_66] at sun.nio.cs.StreamDecoder.read(StreamDecoder.java:178) ~[na:1.8.0_66] at java.io.InputStreamReader.read(InputStreamReader.java:184) ~[na:1.8.0_66] at java.io.BufferedReader.fill(BufferedReader.java:161) ~[na:1.8.0_66] at java.io.BufferedReader.readLine(BufferedReader.java:324) ~[na:1.8.0_66] at java.io.BufferedReader.readLine(BufferedReader.java:389) ~[na:1.8.0_66] at com.atlassian.stash.internal.scm.git.RawGitAgent$FirstLineCallback.doWithReader(RawGitAgent.java:473) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent$FirstLineCallback.doWithReader(RawGitAgent.java:469) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent.execute(RawGitAgent.java:256) ~[na:na] ... 24 common frames omitted {noformat} h4. Steps to reproduce # Create a repository # Clone the newly created repository to a local # Add something to the local repository and commit it # {{git branch -m tmp}} # {{git branch master/alternate}} # {{git checkout master/alternate}} # {{git branch -D tmp}} # {{git push origin master/alternate}} h4. Proposed solution This scenario should be handled the same way as it is described in the following article: [https://confluence.atlassian.com/display/STASHKB/NoDefaultBranchException+error+regarding+the+default+branch+-+this+branch+does+not+exist].

    Atlassian JIRA | 1 year ago | Peter Koczan
    java.lang.RuntimeException: Error opening/reading [/var/atlassian/application-data/stash/shared/data/repositories/1/refs/heads/master]
  2. 0

    h4. Problem If you move your master branch then create one with a name like {{master/alternate}} instead then push it back to origin, Stash will throw a HTTP 500 error stating: {{Error opening/reading [/var/atlassian/application-data/stash/shared/data/repositories/1/refs/heads/master]}} The logs will show: {noformat} 2015-12-04 12:15:39,342 WARN [threadpool:thread-9] admin @6JC3HDx735x117x0 127.0.0.1 "POST /scm/test/testrepo.git/git-receive-pack HTTP/1.1" c.a.s.i.h.DefaultBuiltInHookHandlerFactory Hook com.atlas sian.stash.internal.plugin.hooks.branchlinks.PrintBranchLinksHook failed. java.lang.RuntimeException: Error opening/reading [/var/atlassian/application-data/stash/shared/data/repositories/1/refs/heads/master] at com.atlassian.stash.internal.scm.git.RawGitAgent.execute(RawGitAgent.java:260) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent.execute(RawGitAgent.java:251) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent.resolveBranch(RawGitAgent.java:368) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent.resolveHead(RawGitAgent.java:225) ~[na:na] at com.atlassian.stash.internal.scm.git.DefaultGitCommandFactory$1.call(DefaultGitCommandFactory.java:198) ~[na:na] at com.atlassian.stash.internal.scm.git.DefaultGitCommandFactory$1.call(DefaultGitCommandFactory.java:194) ~[na:na] at com.atlassian.stash.internal.repository.RepositoryMetadataServiceImpl.getDefaultBranch(RepositoryMetadataServiceImpl.java:93) ~[stash-service-impl-3.9.1.jar:na] at com.atlassian.stash.internal.plugin.hooks.branchlinks.PrintBranchLinksHook.getDefaultBranchId(PrintBranchLinksHook.java:66) ~[na:na] at com.atlassian.stash.internal.plugin.hooks.branchlinks.PrintBranchLinksHook.shouldPrint(PrintBranchLinksHook.java:57) ~[na:na] at com.atlassian.stash.internal.plugin.hooks.branchlinks.PrintBranchLinksHook.onReceive(PrintBranchLinksHook.java:44) ~[na:na] at com.atlassian.stash.internal.hook.DefaultBuiltInHookHandlerFactory$2.handle(DefaultBuiltInHookHandlerFactory.java:71) ~[stash-service-impl-3.9.1.jar:na] at com.atlassian.stash.internal.hook.DefaultHookService.doHandleRequest(DefaultHookService.java:345) [stash-service-impl-3.9.1.jar:na] at com.atlassian.stash.internal.hook.DefaultHookService.handleRequest(DefaultHookService.java:331) [stash-service-impl-3.9.1.jar:na] at com.atlassian.stash.internal.hook.DefaultHookService.handleRawRequest(DefaultHookService.java:239) [stash-service-impl-3.9.1.jar:na] at com.atlassian.stash.internal.hook.DefaultHookService$2$1.run(DefaultHookService.java:205) [stash-service-impl-3.9.1.jar:na] at com.atlassian.stash.internal.concurrent.StateTransferringExecutor$StateTransferringRunnable.run(StateTransferringExecutor.java:73) [stash-platform-3.9.1.jar:na] at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [na:1.8.0_66] at java.util.concurrent.FutureTask.run(FutureTask.java:266) [na:1.8.0_66] at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180) [na:1.8.0_66] at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293) [na:1.8.0_66] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) [na:1.8.0_66] at java.lang.Thread.run(Thread.java:745) [na:1.8.0_66] ... 66 frames trimmed Caused by: java.io.IOException: Is a directory at sun.nio.ch.FileDispatcherImpl.read0(Native Method) ~[na:1.8.0_66] at sun.nio.ch.FileDispatcherImpl.read(FileDispatcherImpl.java:46) ~[na:1.8.0_66] at sun.nio.ch.IOUtil.readIntoNativeBuffer(IOUtil.java:223) ~[na:1.8.0_66] at sun.nio.ch.IOUtil.read(IOUtil.java:197) ~[na:1.8.0_66] at sun.nio.ch.FileChannelImpl.read(FileChannelImpl.java:159) ~[na:1.8.0_66] at sun.nio.ch.ChannelInputStream.read(ChannelInputStream.java:65) ~[na:1.8.0_66] at sun.nio.ch.ChannelInputStream.read(ChannelInputStream.java:109) ~[na:1.8.0_66] at sun.nio.ch.ChannelInputStream.read(ChannelInputStream.java:103) ~[na:1.8.0_66] at sun.nio.cs.StreamDecoder.readBytes(StreamDecoder.java:284) ~[na:1.8.0_66] at sun.nio.cs.StreamDecoder.implRead(StreamDecoder.java:326) ~[na:1.8.0_66] at sun.nio.cs.StreamDecoder.read(StreamDecoder.java:178) ~[na:1.8.0_66] at java.io.InputStreamReader.read(InputStreamReader.java:184) ~[na:1.8.0_66] at java.io.BufferedReader.fill(BufferedReader.java:161) ~[na:1.8.0_66] at java.io.BufferedReader.readLine(BufferedReader.java:324) ~[na:1.8.0_66] at java.io.BufferedReader.readLine(BufferedReader.java:389) ~[na:1.8.0_66] at com.atlassian.stash.internal.scm.git.RawGitAgent$FirstLineCallback.doWithReader(RawGitAgent.java:473) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent$FirstLineCallback.doWithReader(RawGitAgent.java:469) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent.execute(RawGitAgent.java:256) ~[na:na] ... 22 common frames omitted 2015-12-04 12:15:46,723 ERROR [http-nio-7990-exec-3] admin @6JC3HDx735x118x0 151ydgu 127.0.0.1 "GET /projects/TEST/repos/testrepo/browse HTTP/1.1" c.a.s.i.w.HandlerExceptionResolverImpl Error opening/reading [/var/atlassian/application-data/stash/shared/data/repositories/1/refs/heads/master] java.lang.RuntimeException: Error opening/reading [/var/atlassian/application-data/stash/shared/data/repositories/1/refs/heads/master] at com.atlassian.stash.internal.scm.git.RawGitAgent.execute(RawGitAgent.java:260) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent.execute(RawGitAgent.java:251) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent.resolveBranch(RawGitAgent.java:368) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent.resolveHead(RawGitAgent.java:225) ~[na:na] at com.atlassian.stash.internal.scm.git.DefaultGitCommandFactory$1.call(DefaultGitCommandFactory.java:198) ~[na:na] at com.atlassian.stash.internal.scm.git.DefaultGitCommandFactory$1.call(DefaultGitCommandFactory.java:194) ~[na:na] at com.atlassian.stash.internal.repository.RepositoryMetadataServiceImpl.getDefaultBranch(RepositoryMetadataServiceImpl.java:93) ~[stash-service-impl-3.9.1.jar:na] at com.atlassian.stash.internal.web.repos.RepositoryController.browseFilePath(RepositoryController.java:271) ~[RepositoryController.class:na] at com.atlassian.applinks.core.rest.context.ContextFilter.doFilter(ContextFilter.java:25) [applinks-plugin-4.3.5_1427859172000.jar:na] at com.atlassian.stash.internal.spring.security.StashAuthenticationFilter.doFilter(StashAuthenticationFilter.java:83) [StashAuthenticationFilter.class:na] at com.atlassian.stash.internal.web.auth.BeforeLoginPluginAuthenticationFilter.doInsideSpringSecurityChain(BeforeLoginPluginAuthenticationFilter.java:111) [BeforeLoginPluginAuthenticationFilter.class:na] at com.atlassian.stash.internal.web.auth.BeforeLoginPluginAuthenticationFilter.doFilter(BeforeLoginPluginAuthenticationFilter.java:77) [BeforeLoginPluginAuthenticationFilter.class:na] at com.atlassian.security.auth.trustedapps.filter.TrustedApplicationsFilter.doFilter(TrustedApplicationsFilter.java:103) [atlassian-trusted-apps-core-4.0.0.jar:na] at com.atlassian.oauth.serviceprovider.internal.servlet.OAuthFilter.doFilter(OAuthFilter.java:79) [atlassian-oauth-service-provider-plugin-1.9.10_1427859174000.jar:na] at com.atlassian.analytics.client.filter.DefaultAnalyticsFilter.doFilter(DefaultAnalyticsFilter.java:32) [analytics-client-3.65.1_1428700568000.jar:na] at com.atlassian.analytics.client.filter.AbstractHttpFilter.doFilter(AbstractHttpFilter.java:32) [analytics-client-3.65.1_1428700568000.jar:na] at com.atlassian.stash.internal.web.auth.BeforeLoginPluginAuthenticationFilter.doBeforeBeforeLoginFilters(BeforeLoginPluginAuthenticationFilter.java:89) [BeforeLoginPluginAuthenticationFilter.class:na] at com.atlassian.stash.internal.web.auth.BeforeLoginPluginAuthenticationFilter.doFilter(BeforeLoginPluginAuthenticationFilter.java:75) [BeforeLoginPluginAuthenticationFilter.class:na] at com.atlassian.stash.internal.request.DefaultRequestManager.doAsRequest(DefaultRequestManager.java:85) [stash-service-impl-3.9.1.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_66] at java.lang.Thread.run(Thread.java:745) [na:1.8.0_66] ... 273 frames trimmed Caused by: java.io.IOException: Is a directory at sun.nio.ch.FileDispatcherImpl.read0(Native Method) ~[na:1.8.0_66] at sun.nio.ch.FileDispatcherImpl.read(FileDispatcherImpl.java:46) ~[na:1.8.0_66] at sun.nio.ch.IOUtil.readIntoNativeBuffer(IOUtil.java:223) ~[na:1.8.0_66] at sun.nio.ch.IOUtil.read(IOUtil.java:197) ~[na:1.8.0_66] at sun.nio.ch.FileChannelImpl.read(FileChannelImpl.java:159) ~[na:1.8.0_66] at sun.nio.ch.ChannelInputStream.read(ChannelInputStream.java:65) ~[na:1.8.0_66] at sun.nio.ch.ChannelInputStream.read(ChannelInputStream.java:109) ~[na:1.8.0_66] at sun.nio.ch.ChannelInputStream.read(ChannelInputStream.java:103) ~[na:1.8.0_66] at sun.nio.cs.StreamDecoder.readBytes(StreamDecoder.java:284) ~[na:1.8.0_66] at sun.nio.cs.StreamDecoder.implRead(StreamDecoder.java:326) ~[na:1.8.0_66] at sun.nio.cs.StreamDecoder.read(StreamDecoder.java:178) ~[na:1.8.0_66] at java.io.InputStreamReader.read(InputStreamReader.java:184) ~[na:1.8.0_66] at java.io.BufferedReader.fill(BufferedReader.java:161) ~[na:1.8.0_66] at java.io.BufferedReader.readLine(BufferedReader.java:324) ~[na:1.8.0_66] at java.io.BufferedReader.readLine(BufferedReader.java:389) ~[na:1.8.0_66] at com.atlassian.stash.internal.scm.git.RawGitAgent$FirstLineCallback.doWithReader(RawGitAgent.java:473) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent$FirstLineCallback.doWithReader(RawGitAgent.java:469) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent.execute(RawGitAgent.java:256) ~[na:na] ... 24 common frames omitted {noformat} h4. Steps to reproduce # Create a repository # Clone the newly created repository to a local # Add something to the local repository and commit it # {{git branch -m tmp}} # {{git branch master/alternate}} # {{git checkout master/alternate}} # {{git branch -D tmp}} # {{git push origin master/alternate}} h4. Proposed solution This scenario should be handled the same way as it is described in the following article: [https://confluence.atlassian.com/display/STASHKB/NoDefaultBranchException+error+regarding+the+default+branch+-+this+branch+does+not+exist].

    Atlassian JIRA | 1 year ago | Peter Koczan
    java.lang.RuntimeException: Error opening/reading [/var/atlassian/application-data/stash/shared/data/repositories/1/refs/heads/master]
  3. 0

    h4. Problem If you move your master branch then create one with a name like {{master/alternate}} instead then push it back to origin, Stash will throw a HTTP 500 error stating: {{Error opening/reading [/var/atlassian/application-data/stash/shared/data/repositories/1/refs/heads/master]}} The logs will show: {noformat} 2015-12-04 12:15:39,342 WARN [threadpool:thread-9] admin @6JC3HDx735x117x0 127.0.0.1 "POST /scm/test/testrepo.git/git-receive-pack HTTP/1.1" c.a.s.i.h.DefaultBuiltInHookHandlerFactory Hook com.atlas sian.stash.internal.plugin.hooks.branchlinks.PrintBranchLinksHook failed. java.lang.RuntimeException: Error opening/reading [/var/atlassian/application-data/stash/shared/data/repositories/1/refs/heads/master] at com.atlassian.stash.internal.scm.git.RawGitAgent.execute(RawGitAgent.java:260) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent.execute(RawGitAgent.java:251) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent.resolveBranch(RawGitAgent.java:368) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent.resolveHead(RawGitAgent.java:225) ~[na:na] at com.atlassian.stash.internal.scm.git.DefaultGitCommandFactory$1.call(DefaultGitCommandFactory.java:198) ~[na:na] at com.atlassian.stash.internal.scm.git.DefaultGitCommandFactory$1.call(DefaultGitCommandFactory.java:194) ~[na:na] at com.atlassian.stash.internal.repository.RepositoryMetadataServiceImpl.getDefaultBranch(RepositoryMetadataServiceImpl.java:93) ~[stash-service-impl-3.9.1.jar:na] at com.atlassian.stash.internal.plugin.hooks.branchlinks.PrintBranchLinksHook.getDefaultBranchId(PrintBranchLinksHook.java:66) ~[na:na] at com.atlassian.stash.internal.plugin.hooks.branchlinks.PrintBranchLinksHook.shouldPrint(PrintBranchLinksHook.java:57) ~[na:na] at com.atlassian.stash.internal.plugin.hooks.branchlinks.PrintBranchLinksHook.onReceive(PrintBranchLinksHook.java:44) ~[na:na] at com.atlassian.stash.internal.hook.DefaultBuiltInHookHandlerFactory$2.handle(DefaultBuiltInHookHandlerFactory.java:71) ~[stash-service-impl-3.9.1.jar:na] at com.atlassian.stash.internal.hook.DefaultHookService.doHandleRequest(DefaultHookService.java:345) [stash-service-impl-3.9.1.jar:na] at com.atlassian.stash.internal.hook.DefaultHookService.handleRequest(DefaultHookService.java:331) [stash-service-impl-3.9.1.jar:na] at com.atlassian.stash.internal.hook.DefaultHookService.handleRawRequest(DefaultHookService.java:239) [stash-service-impl-3.9.1.jar:na] at com.atlassian.stash.internal.hook.DefaultHookService$2$1.run(DefaultHookService.java:205) [stash-service-impl-3.9.1.jar:na] at com.atlassian.stash.internal.concurrent.StateTransferringExecutor$StateTransferringRunnable.run(StateTransferringExecutor.java:73) [stash-platform-3.9.1.jar:na] at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [na:1.8.0_66] at java.util.concurrent.FutureTask.run(FutureTask.java:266) [na:1.8.0_66] at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180) [na:1.8.0_66] at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293) [na:1.8.0_66] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) [na:1.8.0_66] at java.lang.Thread.run(Thread.java:745) [na:1.8.0_66] ... 66 frames trimmed Caused by: java.io.IOException: Is a directory at sun.nio.ch.FileDispatcherImpl.read0(Native Method) ~[na:1.8.0_66] at sun.nio.ch.FileDispatcherImpl.read(FileDispatcherImpl.java:46) ~[na:1.8.0_66] at sun.nio.ch.IOUtil.readIntoNativeBuffer(IOUtil.java:223) ~[na:1.8.0_66] at sun.nio.ch.IOUtil.read(IOUtil.java:197) ~[na:1.8.0_66] at sun.nio.ch.FileChannelImpl.read(FileChannelImpl.java:159) ~[na:1.8.0_66] at sun.nio.ch.ChannelInputStream.read(ChannelInputStream.java:65) ~[na:1.8.0_66] at sun.nio.ch.ChannelInputStream.read(ChannelInputStream.java:109) ~[na:1.8.0_66] at sun.nio.ch.ChannelInputStream.read(ChannelInputStream.java:103) ~[na:1.8.0_66] at sun.nio.cs.StreamDecoder.readBytes(StreamDecoder.java:284) ~[na:1.8.0_66] at sun.nio.cs.StreamDecoder.implRead(StreamDecoder.java:326) ~[na:1.8.0_66] at sun.nio.cs.StreamDecoder.read(StreamDecoder.java:178) ~[na:1.8.0_66] at java.io.InputStreamReader.read(InputStreamReader.java:184) ~[na:1.8.0_66] at java.io.BufferedReader.fill(BufferedReader.java:161) ~[na:1.8.0_66] at java.io.BufferedReader.readLine(BufferedReader.java:324) ~[na:1.8.0_66] at java.io.BufferedReader.readLine(BufferedReader.java:389) ~[na:1.8.0_66] at com.atlassian.stash.internal.scm.git.RawGitAgent$FirstLineCallback.doWithReader(RawGitAgent.java:473) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent$FirstLineCallback.doWithReader(RawGitAgent.java:469) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent.execute(RawGitAgent.java:256) ~[na:na] ... 22 common frames omitted 2015-12-04 12:15:46,723 ERROR [http-nio-7990-exec-3] admin @6JC3HDx735x118x0 151ydgu 127.0.0.1 "GET /projects/TEST/repos/testrepo/browse HTTP/1.1" c.a.s.i.w.HandlerExceptionResolverImpl Error opening/reading [/var/atlassian/application-data/stash/shared/data/repositories/1/refs/heads/master] java.lang.RuntimeException: Error opening/reading [/var/atlassian/application-data/stash/shared/data/repositories/1/refs/heads/master] at com.atlassian.stash.internal.scm.git.RawGitAgent.execute(RawGitAgent.java:260) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent.execute(RawGitAgent.java:251) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent.resolveBranch(RawGitAgent.java:368) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent.resolveHead(RawGitAgent.java:225) ~[na:na] at com.atlassian.stash.internal.scm.git.DefaultGitCommandFactory$1.call(DefaultGitCommandFactory.java:198) ~[na:na] at com.atlassian.stash.internal.scm.git.DefaultGitCommandFactory$1.call(DefaultGitCommandFactory.java:194) ~[na:na] at com.atlassian.stash.internal.repository.RepositoryMetadataServiceImpl.getDefaultBranch(RepositoryMetadataServiceImpl.java:93) ~[stash-service-impl-3.9.1.jar:na] at com.atlassian.stash.internal.web.repos.RepositoryController.browseFilePath(RepositoryController.java:271) ~[RepositoryController.class:na] at com.atlassian.applinks.core.rest.context.ContextFilter.doFilter(ContextFilter.java:25) [applinks-plugin-4.3.5_1427859172000.jar:na] at com.atlassian.stash.internal.spring.security.StashAuthenticationFilter.doFilter(StashAuthenticationFilter.java:83) [StashAuthenticationFilter.class:na] at com.atlassian.stash.internal.web.auth.BeforeLoginPluginAuthenticationFilter.doInsideSpringSecurityChain(BeforeLoginPluginAuthenticationFilter.java:111) [BeforeLoginPluginAuthenticationFilter.class:na] at com.atlassian.stash.internal.web.auth.BeforeLoginPluginAuthenticationFilter.doFilter(BeforeLoginPluginAuthenticationFilter.java:77) [BeforeLoginPluginAuthenticationFilter.class:na] at com.atlassian.security.auth.trustedapps.filter.TrustedApplicationsFilter.doFilter(TrustedApplicationsFilter.java:103) [atlassian-trusted-apps-core-4.0.0.jar:na] at com.atlassian.oauth.serviceprovider.internal.servlet.OAuthFilter.doFilter(OAuthFilter.java:79) [atlassian-oauth-service-provider-plugin-1.9.10_1427859174000.jar:na] at com.atlassian.analytics.client.filter.DefaultAnalyticsFilter.doFilter(DefaultAnalyticsFilter.java:32) [analytics-client-3.65.1_1428700568000.jar:na] at com.atlassian.analytics.client.filter.AbstractHttpFilter.doFilter(AbstractHttpFilter.java:32) [analytics-client-3.65.1_1428700568000.jar:na] at com.atlassian.stash.internal.web.auth.BeforeLoginPluginAuthenticationFilter.doBeforeBeforeLoginFilters(BeforeLoginPluginAuthenticationFilter.java:89) [BeforeLoginPluginAuthenticationFilter.class:na] at com.atlassian.stash.internal.web.auth.BeforeLoginPluginAuthenticationFilter.doFilter(BeforeLoginPluginAuthenticationFilter.java:75) [BeforeLoginPluginAuthenticationFilter.class:na] at com.atlassian.stash.internal.request.DefaultRequestManager.doAsRequest(DefaultRequestManager.java:85) [stash-service-impl-3.9.1.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_66] at java.lang.Thread.run(Thread.java:745) [na:1.8.0_66] ... 273 frames trimmed Caused by: java.io.IOException: Is a directory at sun.nio.ch.FileDispatcherImpl.read0(Native Method) ~[na:1.8.0_66] at sun.nio.ch.FileDispatcherImpl.read(FileDispatcherImpl.java:46) ~[na:1.8.0_66] at sun.nio.ch.IOUtil.readIntoNativeBuffer(IOUtil.java:223) ~[na:1.8.0_66] at sun.nio.ch.IOUtil.read(IOUtil.java:197) ~[na:1.8.0_66] at sun.nio.ch.FileChannelImpl.read(FileChannelImpl.java:159) ~[na:1.8.0_66] at sun.nio.ch.ChannelInputStream.read(ChannelInputStream.java:65) ~[na:1.8.0_66] at sun.nio.ch.ChannelInputStream.read(ChannelInputStream.java:109) ~[na:1.8.0_66] at sun.nio.ch.ChannelInputStream.read(ChannelInputStream.java:103) ~[na:1.8.0_66] at sun.nio.cs.StreamDecoder.readBytes(StreamDecoder.java:284) ~[na:1.8.0_66] at sun.nio.cs.StreamDecoder.implRead(StreamDecoder.java:326) ~[na:1.8.0_66] at sun.nio.cs.StreamDecoder.read(StreamDecoder.java:178) ~[na:1.8.0_66] at java.io.InputStreamReader.read(InputStreamReader.java:184) ~[na:1.8.0_66] at java.io.BufferedReader.fill(BufferedReader.java:161) ~[na:1.8.0_66] at java.io.BufferedReader.readLine(BufferedReader.java:324) ~[na:1.8.0_66] at java.io.BufferedReader.readLine(BufferedReader.java:389) ~[na:1.8.0_66] at com.atlassian.stash.internal.scm.git.RawGitAgent$FirstLineCallback.doWithReader(RawGitAgent.java:473) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent$FirstLineCallback.doWithReader(RawGitAgent.java:469) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent.execute(RawGitAgent.java:256) ~[na:na] ... 24 common frames omitted {noformat} h4. Steps to reproduce # Create a repository # Clone the newly created repository to a local # Add something to the local repository and commit it # {{git branch -m tmp}} # {{git branch master/alternate}} # {{git checkout master/alternate}} # {{git branch -D tmp}} # {{git push origin master/alternate}} h4. Proposed solution This scenario should be handled the same way as it is described in the following article: [https://confluence.atlassian.com/display/STASHKB/NoDefaultBranchException+error+regarding+the+default+branch+-+this+branch+does+not+exist].

    Atlassian JIRA | 1 year ago | Peter Koczan
    java.lang.RuntimeException: Error opening/reading [/var/atlassian/application-data/stash/shared/data/repositories/1/refs/heads/master]
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    h4. Problem If you move your master branch then create one with a name like {{master/alternate}} instead then push it back to origin, Stash will throw a HTTP 500 error stating: {{Error opening/reading [/var/atlassian/application-data/stash/shared/data/repositories/1/refs/heads/master]}} The logs will show: {noformat} 2015-12-04 12:15:39,342 WARN [threadpool:thread-9] admin @6JC3HDx735x117x0 127.0.0.1 "POST /scm/test/testrepo.git/git-receive-pack HTTP/1.1" c.a.s.i.h.DefaultBuiltInHookHandlerFactory Hook com.atlas sian.stash.internal.plugin.hooks.branchlinks.PrintBranchLinksHook failed. java.lang.RuntimeException: Error opening/reading [/var/atlassian/application-data/stash/shared/data/repositories/1/refs/heads/master] at com.atlassian.stash.internal.scm.git.RawGitAgent.execute(RawGitAgent.java:260) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent.execute(RawGitAgent.java:251) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent.resolveBranch(RawGitAgent.java:368) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent.resolveHead(RawGitAgent.java:225) ~[na:na] at com.atlassian.stash.internal.scm.git.DefaultGitCommandFactory$1.call(DefaultGitCommandFactory.java:198) ~[na:na] at com.atlassian.stash.internal.scm.git.DefaultGitCommandFactory$1.call(DefaultGitCommandFactory.java:194) ~[na:na] at com.atlassian.stash.internal.repository.RepositoryMetadataServiceImpl.getDefaultBranch(RepositoryMetadataServiceImpl.java:93) ~[stash-service-impl-3.9.1.jar:na] at com.atlassian.stash.internal.plugin.hooks.branchlinks.PrintBranchLinksHook.getDefaultBranchId(PrintBranchLinksHook.java:66) ~[na:na] at com.atlassian.stash.internal.plugin.hooks.branchlinks.PrintBranchLinksHook.shouldPrint(PrintBranchLinksHook.java:57) ~[na:na] at com.atlassian.stash.internal.plugin.hooks.branchlinks.PrintBranchLinksHook.onReceive(PrintBranchLinksHook.java:44) ~[na:na] at com.atlassian.stash.internal.hook.DefaultBuiltInHookHandlerFactory$2.handle(DefaultBuiltInHookHandlerFactory.java:71) ~[stash-service-impl-3.9.1.jar:na] at com.atlassian.stash.internal.hook.DefaultHookService.doHandleRequest(DefaultHookService.java:345) [stash-service-impl-3.9.1.jar:na] at com.atlassian.stash.internal.hook.DefaultHookService.handleRequest(DefaultHookService.java:331) [stash-service-impl-3.9.1.jar:na] at com.atlassian.stash.internal.hook.DefaultHookService.handleRawRequest(DefaultHookService.java:239) [stash-service-impl-3.9.1.jar:na] at com.atlassian.stash.internal.hook.DefaultHookService$2$1.run(DefaultHookService.java:205) [stash-service-impl-3.9.1.jar:na] at com.atlassian.stash.internal.concurrent.StateTransferringExecutor$StateTransferringRunnable.run(StateTransferringExecutor.java:73) [stash-platform-3.9.1.jar:na] at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [na:1.8.0_66] at java.util.concurrent.FutureTask.run(FutureTask.java:266) [na:1.8.0_66] at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180) [na:1.8.0_66] at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293) [na:1.8.0_66] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) [na:1.8.0_66] at java.lang.Thread.run(Thread.java:745) [na:1.8.0_66] ... 66 frames trimmed Caused by: java.io.IOException: Is a directory at sun.nio.ch.FileDispatcherImpl.read0(Native Method) ~[na:1.8.0_66] at sun.nio.ch.FileDispatcherImpl.read(FileDispatcherImpl.java:46) ~[na:1.8.0_66] at sun.nio.ch.IOUtil.readIntoNativeBuffer(IOUtil.java:223) ~[na:1.8.0_66] at sun.nio.ch.IOUtil.read(IOUtil.java:197) ~[na:1.8.0_66] at sun.nio.ch.FileChannelImpl.read(FileChannelImpl.java:159) ~[na:1.8.0_66] at sun.nio.ch.ChannelInputStream.read(ChannelInputStream.java:65) ~[na:1.8.0_66] at sun.nio.ch.ChannelInputStream.read(ChannelInputStream.java:109) ~[na:1.8.0_66] at sun.nio.ch.ChannelInputStream.read(ChannelInputStream.java:103) ~[na:1.8.0_66] at sun.nio.cs.StreamDecoder.readBytes(StreamDecoder.java:284) ~[na:1.8.0_66] at sun.nio.cs.StreamDecoder.implRead(StreamDecoder.java:326) ~[na:1.8.0_66] at sun.nio.cs.StreamDecoder.read(StreamDecoder.java:178) ~[na:1.8.0_66] at java.io.InputStreamReader.read(InputStreamReader.java:184) ~[na:1.8.0_66] at java.io.BufferedReader.fill(BufferedReader.java:161) ~[na:1.8.0_66] at java.io.BufferedReader.readLine(BufferedReader.java:324) ~[na:1.8.0_66] at java.io.BufferedReader.readLine(BufferedReader.java:389) ~[na:1.8.0_66] at com.atlassian.stash.internal.scm.git.RawGitAgent$FirstLineCallback.doWithReader(RawGitAgent.java:473) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent$FirstLineCallback.doWithReader(RawGitAgent.java:469) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent.execute(RawGitAgent.java:256) ~[na:na] ... 22 common frames omitted 2015-12-04 12:15:46,723 ERROR [http-nio-7990-exec-3] admin @6JC3HDx735x118x0 151ydgu 127.0.0.1 "GET /projects/TEST/repos/testrepo/browse HTTP/1.1" c.a.s.i.w.HandlerExceptionResolverImpl Error opening/reading [/var/atlassian/application-data/stash/shared/data/repositories/1/refs/heads/master] java.lang.RuntimeException: Error opening/reading [/var/atlassian/application-data/stash/shared/data/repositories/1/refs/heads/master] at com.atlassian.stash.internal.scm.git.RawGitAgent.execute(RawGitAgent.java:260) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent.execute(RawGitAgent.java:251) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent.resolveBranch(RawGitAgent.java:368) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent.resolveHead(RawGitAgent.java:225) ~[na:na] at com.atlassian.stash.internal.scm.git.DefaultGitCommandFactory$1.call(DefaultGitCommandFactory.java:198) ~[na:na] at com.atlassian.stash.internal.scm.git.DefaultGitCommandFactory$1.call(DefaultGitCommandFactory.java:194) ~[na:na] at com.atlassian.stash.internal.repository.RepositoryMetadataServiceImpl.getDefaultBranch(RepositoryMetadataServiceImpl.java:93) ~[stash-service-impl-3.9.1.jar:na] at com.atlassian.stash.internal.web.repos.RepositoryController.browseFilePath(RepositoryController.java:271) ~[RepositoryController.class:na] at com.atlassian.applinks.core.rest.context.ContextFilter.doFilter(ContextFilter.java:25) [applinks-plugin-4.3.5_1427859172000.jar:na] at com.atlassian.stash.internal.spring.security.StashAuthenticationFilter.doFilter(StashAuthenticationFilter.java:83) [StashAuthenticationFilter.class:na] at com.atlassian.stash.internal.web.auth.BeforeLoginPluginAuthenticationFilter.doInsideSpringSecurityChain(BeforeLoginPluginAuthenticationFilter.java:111) [BeforeLoginPluginAuthenticationFilter.class:na] at com.atlassian.stash.internal.web.auth.BeforeLoginPluginAuthenticationFilter.doFilter(BeforeLoginPluginAuthenticationFilter.java:77) [BeforeLoginPluginAuthenticationFilter.class:na] at com.atlassian.security.auth.trustedapps.filter.TrustedApplicationsFilter.doFilter(TrustedApplicationsFilter.java:103) [atlassian-trusted-apps-core-4.0.0.jar:na] at com.atlassian.oauth.serviceprovider.internal.servlet.OAuthFilter.doFilter(OAuthFilter.java:79) [atlassian-oauth-service-provider-plugin-1.9.10_1427859174000.jar:na] at com.atlassian.analytics.client.filter.DefaultAnalyticsFilter.doFilter(DefaultAnalyticsFilter.java:32) [analytics-client-3.65.1_1428700568000.jar:na] at com.atlassian.analytics.client.filter.AbstractHttpFilter.doFilter(AbstractHttpFilter.java:32) [analytics-client-3.65.1_1428700568000.jar:na] at com.atlassian.stash.internal.web.auth.BeforeLoginPluginAuthenticationFilter.doBeforeBeforeLoginFilters(BeforeLoginPluginAuthenticationFilter.java:89) [BeforeLoginPluginAuthenticationFilter.class:na] at com.atlassian.stash.internal.web.auth.BeforeLoginPluginAuthenticationFilter.doFilter(BeforeLoginPluginAuthenticationFilter.java:75) [BeforeLoginPluginAuthenticationFilter.class:na] at com.atlassian.stash.internal.request.DefaultRequestManager.doAsRequest(DefaultRequestManager.java:85) [stash-service-impl-3.9.1.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_66] at java.lang.Thread.run(Thread.java:745) [na:1.8.0_66] ... 273 frames trimmed Caused by: java.io.IOException: Is a directory at sun.nio.ch.FileDispatcherImpl.read0(Native Method) ~[na:1.8.0_66] at sun.nio.ch.FileDispatcherImpl.read(FileDispatcherImpl.java:46) ~[na:1.8.0_66] at sun.nio.ch.IOUtil.readIntoNativeBuffer(IOUtil.java:223) ~[na:1.8.0_66] at sun.nio.ch.IOUtil.read(IOUtil.java:197) ~[na:1.8.0_66] at sun.nio.ch.FileChannelImpl.read(FileChannelImpl.java:159) ~[na:1.8.0_66] at sun.nio.ch.ChannelInputStream.read(ChannelInputStream.java:65) ~[na:1.8.0_66] at sun.nio.ch.ChannelInputStream.read(ChannelInputStream.java:109) ~[na:1.8.0_66] at sun.nio.ch.ChannelInputStream.read(ChannelInputStream.java:103) ~[na:1.8.0_66] at sun.nio.cs.StreamDecoder.readBytes(StreamDecoder.java:284) ~[na:1.8.0_66] at sun.nio.cs.StreamDecoder.implRead(StreamDecoder.java:326) ~[na:1.8.0_66] at sun.nio.cs.StreamDecoder.read(StreamDecoder.java:178) ~[na:1.8.0_66] at java.io.InputStreamReader.read(InputStreamReader.java:184) ~[na:1.8.0_66] at java.io.BufferedReader.fill(BufferedReader.java:161) ~[na:1.8.0_66] at java.io.BufferedReader.readLine(BufferedReader.java:324) ~[na:1.8.0_66] at java.io.BufferedReader.readLine(BufferedReader.java:389) ~[na:1.8.0_66] at com.atlassian.stash.internal.scm.git.RawGitAgent$FirstLineCallback.doWithReader(RawGitAgent.java:473) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent$FirstLineCallback.doWithReader(RawGitAgent.java:469) ~[na:na] at com.atlassian.stash.internal.scm.git.RawGitAgent.execute(RawGitAgent.java:256) ~[na:na] ... 24 common frames omitted {noformat} h4. Steps to reproduce # Create a repository # Clone the newly created repository to a local # Add something to the local repository and commit it # {{git branch -m tmp}} # {{git branch master/alternate}} # {{git checkout master/alternate}} # {{git branch -D tmp}} # {{git push origin master/alternate}} h4. Proposed solution This scenario should be handled the same way as it is described in the following article: [https://confluence.atlassian.com/display/STASHKB/NoDefaultBranchException+error+regarding+the+default+branch+-+this+branch+does+not+exist].

    Atlassian JIRA | 1 year ago | Peter Koczan
    java.lang.RuntimeException: Error opening/reading [/var/atlassian/application-data/stash/shared/data/repositories/1/refs/heads/master]
  6. 0

    h3. Actual Results: When manually updating JIRA Service Desk 2.3.2 (through upload) on a version that is not supported for that version, JIRA Service Desk breaks and throws the following error: {noformat} 2015-03-04 16:54:19,986 http-bio-8039-exec-43 ERROR anonymous 1014x4719900x1 1p5nk73 66.158.140.50,127.0.0.1 /servicedesk/customer/portal/2 [atlassian.plugin.servlet.DefaultServletModuleManager] Unable to create filter com.atlassian.util.concurrent.LazyReference$InitializationException: java.lang.RuntimeException: Could not identify Bundle at location <file:/var/atlassian/application-data/jira/plugins/installed-plugins/jira-servicedesk-2.3.2.jar> at com.atlassian.util.concurrent.LazyReference.getInterruptibly(LazyReference.java:149) at com.atlassian.util.concurrent.LazyReference.get(LazyReference.java:112) at com.atlassian.plugin.servlet.DefaultServletModuleManager.getFilter(DefaultServletModuleManager.java:389) at com.atlassian.plugin.servlet.DefaultServletModuleManager.getFilters(DefaultServletModuleManager.java:213) at com.atlassian.plugins.rest.module.servlet.DefaultRestServletModuleManager.getFilters(DefaultRestServletModuleManager.java:117) at com.atlassian.plugin.servlet.filter.ServletFilterModuleContainerFilter.doFilter(ServletFilterModuleContainerFilter.java:75) at com.atlassian.plugin.servlet.filter.ServletFilterModuleContainerFilter.doFilter(ServletFilterModuleContainerFilter.java:63) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter.doFilter(DelegatingPluginFilter.java:78) at com.atlassian.plugin.servlet.filter.IteratingFilterChain.doFilter(IteratingFilterChain.java:42) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter$1.doFilter(DelegatingPluginFilter.java:70) at com.atlassian.plugins.rest.module.servlet.RestServletUtilsUpdaterFilter.doFilterInternal(RestServletUtilsUpdaterFilter.java:26) at com.atlassian.plugins.rest.module.servlet.RestServletUtilsUpdaterFilter.doFilter(RestServletUtilsUpdaterFilter.java:40) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter.doFilter(DelegatingPluginFilter.java:78) at com.atlassian.plugin.servlet.filter.IteratingFilterChain.doFilter(IteratingFilterChain.java:42) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter$1.doFilter(DelegatingPluginFilter.java:70) at com.atlassian.applinks.core.rest.context.ContextFilter.doFilter(ContextFilter.java:25) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter.doFilter(DelegatingPluginFilter.java:78) at com.atlassian.plugin.servlet.filter.IteratingFilterChain.doFilter(IteratingFilterChain.java:42) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter$1.doFilter(DelegatingPluginFilter.java:70) at com.atlassian.servicedesk.internal.web.RedirectExternalCustomerToPortalFilter.doFilter(RedirectExternalCustomerToPortalFilter.scala:18) at com.atlassian.core.filters.AbstractHttpFilter.doFilter(AbstractHttpFilter.java:31) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter.doFilter(DelegatingPluginFilter.java:78) at com.atlassian.plugin.servlet.filter.IteratingFilterChain.doFilter(IteratingFilterChain.java:42) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter$1.doFilter(DelegatingPluginFilter.java:70) at com.atlassian.prettyurls.filter.PrettyUrlsSiteMeshFixupFilter.doFilter(PrettyUrlsSiteMeshFixupFilter.java:36) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter.doFilter(DelegatingPluginFilter.java:78) at com.atlassian.plugin.servlet.filter.IteratingFilterChain.doFilter(IteratingFilterChain.java:42) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter$1.doFilter(DelegatingPluginFilter.java:70) at com.atlassian.prettyurls.filter.PrettyUrlsDispatcherFilter.doFilter(PrettyUrlsDispatcherFilter.java:60) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter.doFilter(DelegatingPluginFilter.java:78) at com.atlassian.plugin.servlet.filter.IteratingFilterChain.doFilter(IteratingFilterChain.java:42) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter$1.doFilter(DelegatingPluginFilter.java:70) at com.atlassian.prettyurls.filter.PrettyUrlsCommonFilter.preventDoubleInvocation(PrettyUrlsCommonFilter.java:38) at com.atlassian.prettyurls.filter.PrettyUrlsSiteMeshFilter.doFilter(PrettyUrlsSiteMeshFilter.java:74) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter.doFilter(DelegatingPluginFilter.java:78) at com.atlassian.plugin.servlet.filter.IteratingFilterChain.doFilter(IteratingFilterChain.java:42) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter$1.doFilter(DelegatingPluginFilter.java:70) at com.atlassian.prettyurls.filter.PrettyUrlsMatcherFilter.doFilter(PrettyUrlsMatcherFilter.java:56) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter.doFilter(DelegatingPluginFilter.java:78) at com.atlassian.plugin.servlet.filter.IteratingFilterChain.doFilter(IteratingFilterChain.java:42) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter$1.doFilter(DelegatingPluginFilter.java:70) at com.atlassian.labs.botkiller.BotKillerFilter.doFilter(BotKillerFilter.java:30) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter.doFilter(DelegatingPluginFilter.java:78) at com.atlassian.plugin.servlet.filter.IteratingFilterChain.doFilter(IteratingFilterChain.java:42) at com.atlassian.plugin.servlet.filter.ServletFilterModuleContainerFilter.doFilter(ServletFilterModuleContainerFilter.java:77) at com.atlassian.plugin.servlet.filter.ServletFilterModuleContainerFilter.doFilter(ServletFilterModuleContainerFilter.java:63) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at com.atlassian.plugin.servlet.filter.IteratingFilterChain.doFilter(IteratingFilterChain.java:46) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter$1.doFilter(DelegatingPluginFilter.java:70) at com.atlassian.prettyurls.filter.PrettyUrlsCombinedMatchDispatcherFilter.doFilter(PrettyUrlsCombinedMatchDispatcherFilter.java:61) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter.doFilter(DelegatingPluginFilter.java:78) at com.atlassian.plugin.servlet.filter.IteratingFilterChain.doFilter(IteratingFilterChain.java:42) at com.atlassian.plugin.servlet.filter.ServletFilterModuleContainerFilter.doFilter(ServletFilterModuleContainerFilter.java:77) at com.atlassian.plugin.servlet.filter.ServletFilterModuleContainerFilter.doFilter(ServletFilterModuleContainerFilter.java:63) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at com.atlassian.seraph.filter.SecurityFilter.doFilter(SecurityFilter.java:85) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at com.atlassian.seraph.filter.BaseLoginFilter.doFilter(BaseLoginFilter.java:172) at com.atlassian.jira.web.filters.JiraLoginFilter.doFilter(JiraLoginFilter.java:70) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at com.atlassian.plugin.servlet.filter.IteratingFilterChain.doFilter(IteratingFilterChain.java:46) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter$1.doFilter(DelegatingPluginFilter.java:70) at com.atlassian.oauth.serviceprovider.internal.servlet.OAuthFilter.doFilter(OAuthFilter.java:69) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter.doFilter(DelegatingPluginFilter.java:78) at com.atlassian.plugin.servlet.filter.IteratingFilterChain.doFilter(IteratingFilterChain.java:42) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter$1.doFilter(DelegatingPluginFilter.java:70) at com.atlassian.bonfire.web.filters.BonfireP3PFilter.doFilter(BonfireP3PFilter.java:43) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter.doFilter(DelegatingPluginFilter.java:78) at com.atlassian.plugin.servlet.filter.IteratingFilterChain.doFilter(IteratingFilterChain.java:42) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter$1.doFilter(DelegatingPluginFilter.java:70) at com.atlassian.prettyurls.filter.PrettyUrlsCombinedMatchDispatcherFilter.doFilter(PrettyUrlsCombinedMatchDispatcherFilter.java:61) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter.doFilter(DelegatingPluginFilter.java:78) at com.atlassian.plugin.servlet.filter.IteratingFilterChain.doFilter(IteratingFilterChain.java:42) at com.atlassian.plugin.servlet.filter.ServletFilterModuleContainerFilter.doFilter(ServletFilterModuleContainerFilter.java:77) at com.atlassian.plugin.servlet.filter.ServletFilterModuleContainerFilter.doFilter(ServletFilterModuleContainerFilter.java:63) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at com.atlassian.plugin.servlet.filter.IteratingFilterChain.doFilter(IteratingFilterChain.java:46) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter$1.doFilter(DelegatingPluginFilter.java:70) at com.atlassian.servicedesk.internal.web.PortalContextSetter$$anonfun$doFilter$1.apply$mcV$sp(PortalContextSetter.scala:12) at com.atlassian.servicedesk.internal.web.PortalContextSetter$$anonfun$doFilter$1.apply(PortalContextSetter.scala:11) at com.atlassian.servicedesk.internal.web.PortalContextSetter$$anonfun$doFilter$1.apply(PortalContextSetter.scala:11) at com.atlassian.servicedesk.internal.utils.context.PortalContextUtil$.inPortalContext(PortalContextUtil.scala:29) at com.atlassian.servicedesk.internal.web.PortalContextSetter.doFilter(PortalContextSetter.scala:11) at com.atlassian.core.filters.AbstractHttpFilter.doFilter(AbstractHttpFilter.java:31) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter.doFilter(DelegatingPluginFilter.java:78) at com.atlassian.plugin.servlet.filter.IteratingFilterChain.doFilter(IteratingFilterChain.java:42) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter$1.doFilter(DelegatingPluginFilter.java:70) at com.atlassian.prettyurls.filter.PrettyUrlsCombinedMatchDispatcherFilter.doFilter(PrettyUrlsCombinedMatchDispatcherFilter.java:61) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter.doFilter(DelegatingPluginFilter.java:78) at com.atlassian.plugin.servlet.filter.IteratingFilterChain.doFilter(IteratingFilterChain.java:42) at com.atlassian.plugin.servlet.filter.ServletFilterModuleContainerFilter.doFilter(ServletFilterModuleContainerFilter.java:77) at com.atlassian.plugin.servlet.filter.ServletFilterModuleContainerFilter.doFilter(ServletFilterModuleContainerFilter.java:63) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:748) at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:486) at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:411) at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:338) at com.atlassian.prettyurls.filter.PrettyUrlsDispatcherFilter.doFilter(PrettyUrlsDispatcherFilter.java:55) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter.doFilter(DelegatingPluginFilter.java:78) at com.atlassian.plugin.servlet.filter.IteratingFilterChain.doFilter(IteratingFilterChain.java:42) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter$1.doFilter(DelegatingPluginFilter.java:70) at com.atlassian.prettyurls.filter.PrettyUrlsSiteMeshFilter.doFilter(PrettyUrlsSiteMeshFilter.java:92) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter.doFilter(DelegatingPluginFilter.java:78) at com.atlassian.plugin.servlet.filter.IteratingFilterChain.doFilter(IteratingFilterChain.java:42) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter$1.doFilter(DelegatingPluginFilter.java:70) at com.atlassian.prettyurls.filter.PrettyUrlsMatcherFilter.doFilter(PrettyUrlsMatcherFilter.java:56) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter.doFilter(DelegatingPluginFilter.java:78) at com.atlassian.plugin.servlet.filter.IteratingFilterChain.doFilter(IteratingFilterChain.java:42) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter$1.doFilter(DelegatingPluginFilter.java:70) at com.atlassian.labs.botkiller.BotKillerFilter.doFilter(BotKillerFilter.java:36) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter.doFilter(DelegatingPluginFilter.java:78) at com.atlassian.plugin.servlet.filter.IteratingFilterChain.doFilter(IteratingFilterChain.java:42) at com.atlassian.plugin.servlet.filter.ServletFilterModuleContainerFilter.doFilter(ServletFilterModuleContainerFilter.java:77) at com.atlassian.plugin.servlet.filter.ServletFilterModuleContainerFilter.doFilter(ServletFilterModuleContainerFilter.java:63) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at com.atlassian.jira.web.filters.accesslog.AccessLogFilter.executeRequest(AccessLogFilter.java:103) at com.atlassian.jira.web.filters.accesslog.AccessLogFilter.doFilter(AccessLogFilter.java:87) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at com.atlassian.jira.security.xsrf.XsrfTokenAdditionRequestFilter.doFilter(XsrfTokenAdditionRequestFilter.java:54) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at com.atlassian.jira.web.filters.steps.ChainedFilterStepRunner.doFilter(ChainedFilterStepRunner.java:87) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at com.atlassian.plugin.servlet.filter.IteratingFilterChain.doFilter(IteratingFilterChain.java:46) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter$1.doFilter(DelegatingPluginFilter.java:70) at com.atlassian.prettyurls.filter.PrettyUrlsCombinedMatchDispatcherFilter.doFilter(PrettyUrlsCombinedMatchDispatcherFilter.java:61) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter.doFilter(DelegatingPluginFilter.java:78) at com.atlassian.plugin.servlet.filter.IteratingFilterChain.doFilter(IteratingFilterChain.java:42) at com.atlassian.plugin.servlet.filter.ServletFilterModuleContainerFilter.doFilter(ServletFilterModuleContainerFilter.java:77) at com.atlassian.plugin.servlet.filter.ServletFilterModuleContainerFilter.doFilter(ServletFilterModuleContainerFilter.java:63) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at com.atlassian.seraph.filter.SecurityFilter.doFilter(SecurityFilter.java:237) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at com.atlassian.security.auth.trustedapps.filter.TrustedApplicationsFilter.doFilter(TrustedApplicationsFilter.java:100) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at com.atlassian.seraph.filter.BaseLoginFilter.doFilter(BaseLoginFilter.java:172) at com.atlassian.jira.web.filters.JiraLoginFilter.doFilter(JiraLoginFilter.java:70) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at com.atlassian.plugin.servlet.filter.IteratingFilterChain.doFilter(IteratingFilterChain.java:46) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter$1.doFilter(DelegatingPluginFilter.java:70) at com.atlassian.oauth.serviceprovider.internal.servlet.OAuthFilter.doFilter(OAuthFilter.java:69) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter.doFilter(DelegatingPluginFilter.java:78) at com.atlassian.plugin.servlet.filter.IteratingFilterChain.doFilter(IteratingFilterChain.java:42) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter$1.doFilter(DelegatingPluginFilter.java:70) at com.atlassian.bonfire.web.filters.BonfireP3PFilter.doFilter(BonfireP3PFilter.java:57) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter.doFilter(DelegatingPluginFilter.java:78) at com.atlassian.plugin.servlet.filter.IteratingFilterChain.doFilter(IteratingFilterChain.java:42) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter$1.doFilter(DelegatingPluginFilter.java:70) at com.atlassian.prettyurls.filter.PrettyUrlsCombinedMatchDispatcherFilter.doFilter(PrettyUrlsCombinedMatchDispatcherFilter.java:61) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter.doFilter(DelegatingPluginFilter.java:78) at com.atlassian.plugin.servlet.filter.IteratingFilterChain.doFilter(IteratingFilterChain.java:42) at com.atlassian.plugin.servlet.filter.ServletFilterModuleContainerFilter.doFilter(ServletFilterModuleContainerFilter.java:77) at com.atlassian.plugin.servlet.filter.ServletFilterModuleContainerFilter.doFilter(ServletFilterModuleContainerFilter.java:63) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at org.tuckey.web.filters.urlrewrite.RuleChain.handleRewrite(RuleChain.java:176) at org.tuckey.web.filters.urlrewrite.RuleChain.doRules(RuleChain.java:145) at org.tuckey.web.filters.urlrewrite.UrlRewriter.processRequest(UrlRewriter.java:92) at org.tuckey.web.filters.urlrewrite.UrlRewriteFilter.doFilter(UrlRewriteFilter.java:394) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at com.atlassian.gzipfilter.GzipFilter.doFilterInternal(GzipFilter.java:88) at com.atlassian.gzipfilter.GzipFilter.doFilter(GzipFilter.java:59) at com.atlassian.jira.web.filters.gzip.JiraGzipFilter.doFilter(JiraGzipFilter.java:55) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at com.atlassian.plugin.servlet.filter.IteratingFilterChain.doFilter(IteratingFilterChain.java:46) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter$1.doFilter(DelegatingPluginFilter.java:70) at com.atlassian.analytics.client.filter.JiraAnalyticsFilter.doFilter(JiraAnalyticsFilter.java:41) at com.atlassian.core.filters.AbstractHttpFilter.doFilter(AbstractHttpFilter.java:31) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter.doFilter(DelegatingPluginFilter.java:78) at com.atlassian.plugin.servlet.filter.IteratingFilterChain.doFilter(IteratingFilterChain.java:42) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter$1.doFilter(DelegatingPluginFilter.java:70) at com.atlassian.servicedesk.internal.web.PortalContextSetter$$anonfun$doFilter$1.apply$mcV$sp(PortalContextSetter.scala:12) at com.atlassian.servicedesk.internal.web.PortalContextSetter$$anonfun$doFilter$1.apply(PortalContextSetter.scala:11) at com.atlassian.servicedesk.internal.web.PortalContextSetter$$anonfun$doFilter$1.apply(PortalContextSetter.scala:11) at com.atlassian.servicedesk.internal.utils.context.PortalContextUtil$.inPortalContext(PortalContextUtil.scala:23) at com.atlassian.servicedesk.internal.web.PortalContextSetter.doFilter(PortalContextSetter.scala:11) at com.atlassian.core.filters.AbstractHttpFilter.doFilter(AbstractHttpFilter.java:31) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter.doFilter(DelegatingPluginFilter.java:78) at com.atlassian.plugin.servlet.filter.IteratingFilterChain.doFilter(IteratingFilterChain.java:42) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter$1.doFilter(DelegatingPluginFilter.java:70) at com.atlassian.prettyurls.filter.PrettyUrlsCombinedMatchDispatcherFilter.doFilter(PrettyUrlsCombinedMatchDispatcherFilter.java:61) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter.doFilter(DelegatingPluginFilter.java:78) at com.atlassian.plugin.servlet.filter.IteratingFilterChain.doFilter(IteratingFilterChain.java:42) at com.atlassian.plugin.servlet.filter.ServletFilterModuleContainerFilter.doFilter(ServletFilterModuleContainerFilter.java:77) at com.atlassian.plugin.servlet.filter.ServletFilterModuleContainerFilter.doFilter(ServletFilterModuleContainerFilter.java:63) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at com.atlassian.jira.web.filters.steps.ChainedFilterStepRunner.doFilter(ChainedFilterStepRunner.java:87) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at com.atlassian.core.filters.cache.AbstractCachingFilter.doFilter(AbstractCachingFilter.java:33) at com.atlassian.core.filters.AbstractHttpFilter.doFilter(AbstractHttpFilter.java:31) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at com.atlassian.core.filters.encoding.AbstractEncodingFilter.doFilter(AbstractEncodingFilter.java:41) at com.atlassian.core.filters.AbstractHttpFilter.doFilter(AbstractHttpFilter.java:31) at com.atlassian.jira.web.filters.PathMatchingEncodingFilter.doFilter(PathMatchingEncodingFilter.java:49) at com.atlassian.core.filters.AbstractHttpFilter.doFilter(AbstractHttpFilter.java:31) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at com.atlassian.jira.startup.JiraStartupChecklistFilter.doFilter(JiraStartupChecklistFilter.java:79) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at com.atlassian.jira.web.filters.MultipartBoundaryCheckFilter.doFilter(MultipartBoundaryCheckFilter.java:41) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at com.atlassian.jira.web.filters.steps.ChainedFilterStepRunner.doFilter(ChainedFilterStepRunner.java:87) at com.atlassian.jira.web.filters.JiraFirstFilter.doFilter(JiraFirstFilter.java:60) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:220) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:122) at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:501) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:171) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:103) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:116) at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:950) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:408) at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1070) at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:611) at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:316) at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source) at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) at java.lang.Thread.run(Unknown Source) Caused by: java.lang.RuntimeException: Could not identify Bundle at location <file:/var/atlassian/application-data/jira/plugins/installed-plugins/jira-servicedesk-2.3.2.jar> at com.atlassian.plugins.rest.module.scanner.AnnotatedClassScanner.scan(AnnotatedClassScanner.java:59) at com.atlassian.plugins.rest.module.OsgiResourceConfig.scanForAnnotatedClasses(OsgiResourceConfig.java:95) at com.atlassian.plugins.rest.module.OsgiResourceConfig.getClasses(OsgiResourceConfig.java:86) at com.sun.jersey.spi.container.servlet.WebComponent.configure(WebComponent.java:570) at com.sun.jersey.spi.container.servlet.ServletContainer$InternalWebComponent.configure(ServletContainer.java:311) at com.sun.jersey.spi.container.servlet.WebComponent.load(WebComponent.java:608) at com.sun.jersey.spi.container.servlet.WebComponent.init(WebComponent.java:210) at com.sun.jersey.spi.container.servlet.ServletContainer.init(ServletContainer.java:373) at com.sun.jersey.spi.container.servlet.ServletContainer.init(ServletContainer.java:710) at com.atlassian.plugins.rest.module.RestDelegatingServletFilter.initServletContainer(RestDelegatingServletFilter.java:99) at com.atlassian.plugins.rest.module.RestDelegatingServletFilter.init(RestDelegatingServletFilter.java:64) at com.atlassian.plugin.servlet.filter.DelegatingPluginFilter.init(DelegatingPluginFilter.java:43) at com.atlassian.plugin.servlet.DefaultServletModuleManager$LazyLoadedFilterReference.create(DefaultServletModuleManager.java:442) at com.atlassian.plugin.servlet.DefaultServletModuleManager$LazyLoadedFilterReference.create(DefaultServletModuleManager.java:427) at com.atlassian.util.concurrent.LazyReference$Sync.run(LazyReference.java:325) at com.atlassian.util.concurrent.LazyReference.getInterruptibly(LazyReference.java:143) ... 239 more {noformat} h3. Steps to reproduce: # Install JIRA 6.3.5 or newer; # Upload JIRA Service Desk 2.3.2 or newer; h3. Expected Results: The application shouldn't allow users to manually install a plugin when the same is not supported to the current version. This behaviour was fixed by upgrading JIRA to a matching version.

    Atlassian JIRA | 2 years ago | Benito Picarelli
    com.atlassian.util.concurrent.LazyReference$InitializationException: java.lang.RuntimeException: Could not identify Bundle at location <file:/var/atlassian/application-data/jira/plugins/installed-plugins/jira-servicedesk-2.3.2.jar>

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. java.lang.RuntimeException

      Error opening/reading [/var/atlassian/application-data/stash/shared/data/repositories/1/refs/heads/master]

      at com.atlassian.stash.internal.scm.git.RawGitAgent.execute()
    2. com.atlassian.stash
      StateTransferringExecutor$StateTransferringRunnable.run
      1. com.atlassian.stash.internal.scm.git.RawGitAgent.execute(RawGitAgent.java:260)[na:na]
      2. com.atlassian.stash.internal.scm.git.RawGitAgent.execute(RawGitAgent.java:251)[na:na]
      3. com.atlassian.stash.internal.scm.git.RawGitAgent.resolveBranch(RawGitAgent.java:368)[na:na]
      4. com.atlassian.stash.internal.scm.git.RawGitAgent.resolveHead(RawGitAgent.java:225)[na:na]
      5. com.atlassian.stash.internal.scm.git.DefaultGitCommandFactory$1.call(DefaultGitCommandFactory.java:198)[na:na]
      6. com.atlassian.stash.internal.scm.git.DefaultGitCommandFactory$1.call(DefaultGitCommandFactory.java:194)[na:na]
      7. com.atlassian.stash.internal.repository.RepositoryMetadataServiceImpl.getDefaultBranch(RepositoryMetadataServiceImpl.java:93)[stash-service-impl-3.9.1.jar:na]
      8. com.atlassian.stash.internal.plugin.hooks.branchlinks.PrintBranchLinksHook.getDefaultBranchId(PrintBranchLinksHook.java:66)[na:na]
      9. com.atlassian.stash.internal.plugin.hooks.branchlinks.PrintBranchLinksHook.shouldPrint(PrintBranchLinksHook.java:57)[na:na]
      10. com.atlassian.stash.internal.plugin.hooks.branchlinks.PrintBranchLinksHook.onReceive(PrintBranchLinksHook.java:44)[na:na]
      11. com.atlassian.stash.internal.hook.DefaultBuiltInHookHandlerFactory$2.handle(DefaultBuiltInHookHandlerFactory.java:71)[stash-service-impl-3.9.1.jar:na]
      12. com.atlassian.stash.internal.hook.DefaultHookService.doHandleRequest(DefaultHookService.java:345)[stash-service-impl-3.9.1.jar:na]
      13. com.atlassian.stash.internal.hook.DefaultHookService.handleRequest(DefaultHookService.java:331)[stash-service-impl-3.9.1.jar:na]
      14. com.atlassian.stash.internal.hook.DefaultHookService.handleRawRequest(DefaultHookService.java:239)[stash-service-impl-3.9.1.jar:na]
      15. com.atlassian.stash.internal.hook.DefaultHookService$2$1.run(DefaultHookService.java:205)[stash-service-impl-3.9.1.jar:na]
      16. com.atlassian.stash.internal.concurrent.StateTransferringExecutor$StateTransferringRunnable.run(StateTransferringExecutor.java:73)[stash-platform-3.9.1.jar:na]
      16 frames
    3. Java RT
      Thread.run
      1. java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)[na:1.8.0_66]
      2. java.util.concurrent.FutureTask.run(FutureTask.java:266)[na:1.8.0_66]
      3. java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180)[na:1.8.0_66]
      4. java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293)[na:1.8.0_66]
      5. java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)[na:1.8.0_66]
      6. java.lang.Thread.run(Thread.java:745)[na:1.8.0_66]
      6 frames