Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-27977

NullPointer & authentication cancelled occure immediately on SVN checkout

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: Blocker
    • Resolution: Cannot Reproduce
    • Component/s: subversion-plugin
    • Labels:
      None
    • Environment:
      Linux + LDAP (Microsoft Server) + SvnKit
    • Similar Issues:

      Description

      The NullPointerException below sometimes occures when Jenkins starts an SVN checkout (at the beginning of the job), only with secured HTTP (HTTPS).

      Can you please catch this exception and log a message with the root cause ?

      It is a blocker for us to use SVN over HTTPS.

      We use last versions of every components:
      Jenkins 1.608
      Subversion Plug-in : 2.5

      23:00:46 Started by upstream project "Build Pipeline Job" build number 193
      23:00:46 originally caused by:
      23:00:46 Started by timer
      23:00:46 [EnvInject] - Loading node environment variables.
      23:00:46 Building remotely on linux-slave1 in workspace /home/app_jenkins/slave1/workspace/XXX Nightly Trunk
      23:00:47 Checking out a fresh workspace because there's no workspace at /home/app_jenkins/slave1/workspace/XXX Nightly Trunk
      23:00:47 Cleaning local Directory .
      23:00:47 Checking out https://svn.company.com/products/xxx/trunk at revision '2015-04-15T23:00:46.930 +0200'
      23:00:47 ERROR: Failed to check out https://svn.company.com/products/xxx/trunk
      23:00:47 org.tmatesoft.svn.core.SVNCancelException: svn: E200015: authentication cancelled
      23:00:47 at org.tmatesoft.svn.core.internal.wc.SVNErrorManager.cancel(SVNErrorManager.java:37)
      23:00:47 at org.tmatesoft.svn.core.internal.wc.SVNErrorManager.cancel(SVNErrorManager.java:32)
      23:00:47 at org.tmatesoft.svn.core.internal.wc.DefaultSVNAuthenticationManager.getNextAuthentication(DefaultSVNAuthenticationManager.java:215)
      23:00:47 at org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:685)
      23:00:47 at org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:371)
      23:00:47 at org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:359)
      23:00:47 at org.tmatesoft.svn.core.internal.io.dav.DAVConnection.performHttpRequest(DAVConnection.java:710)
      23:00:47 at org.tmatesoft.svn.core.internal.io.dav.DAVConnection.exchangeCapabilities(DAVConnection.java:627)
      23:00:47 at org.tmatesoft.svn.core.internal.io.dav.DAVConnection.open(DAVConnection.java:102)
      23:00:47 at org.tmatesoft.svn.core.internal.io.dav.DAVRepository.openConnection(DAVRepository.java:1032)
      23:00:47 at org.tmatesoft.svn.core.internal.io.dav.DAVRepository.getLatestRevision(DAVRepository.java:175)
      23:00:47 at org.tmatesoft.svn.core.internal.wc2.ng.SvnNgRepositoryAccess.getRevisionNumber(SvnNgRepositoryAccess.java:118)
      23:00:47 at org.tmatesoft.svn.core.internal.wc2.SvnRepositoryAccess.getLocations(SvnRepositoryAccess.java:184)
      23:00:47 at org.tmatesoft.svn.core.internal.wc2.ng.SvnNgRepositoryAccess.createRepositoryFor(SvnNgRepositoryAccess.java:45)
      23:00:47 at org.tmatesoft.svn.core.internal.wc2.ng.SvnNgAbstractUpdate.checkout(SvnNgAbstractUpdate.java:756)
      23:00:47 at org.tmatesoft.svn.core.internal.wc2.ng.SvnNgCheckout.run(SvnNgCheckout.java:26)
      23:00:47 at org.tmatesoft.svn.core.internal.wc2.ng.SvnNgCheckout.run(SvnNgCheckout.java:11)
      23:00:47 at org.tmatesoft.svn.core.internal.wc2.ng.SvnNgOperationRunner.run(SvnNgOperationRunner.java:20)
      23:00:47 at org.tmatesoft.svn.core.internal.wc2.SvnOperationRunner.run(SvnOperationRunner.java:21)
      23:00:47 at org.tmatesoft.svn.core.wc2.SvnOperationFactory.run(SvnOperationFactory.java:1259)
      23:00:47 at org.tmatesoft.svn.core.wc2.SvnOperation.run(SvnOperation.java:294)
      23:00:47 at hudson.scm.subversion.CheckoutUpdater$1.perform(CheckoutUpdater.java:115)
      23:00:47 at hudson.scm.subversion.WorkspaceUpdater$UpdateTask.delegateTo(WorkspaceUpdater.java:162)
      23:00:47 at hudson.scm.subversion.WorkspaceUpdater$UpdateTask.delegateTo(WorkspaceUpdater.java:170)
      23:00:47 at hudson.scm.subversion.UpdateUpdater$TaskImpl.perform(UpdateUpdater.java:133)
      23:00:47 at hudson.scm.subversion.WorkspaceUpdater$UpdateTask.delegateTo(WorkspaceUpdater.java:162)
      23:00:47 at hudson.scm.SubversionSCM$CheckOutTask.perform(SubversionSCM.java:991)
      23:00:47 at hudson.scm.SubversionSCM$CheckOutTask.invoke(SubversionSCM.java:972)
      23:00:47 at hudson.scm.SubversionSCM$CheckOutTask.invoke(SubversionSCM.java:948)
      23:00:47 at hudson.FilePath$FileCallableWrapper.call(FilePath.java:2688)
      23:00:47 at hudson.remoting.UserRequest.perform(UserRequest.java:118)
      23:00:47 at hudson.remoting.UserRequest.perform(UserRequest.java:48)
      23:00:47 at hudson.remoting.Request$2.run(Request.java:328)
      23:00:47 at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72)
      23:00:47 at java.util.concurrent.FutureTask.run(FutureTask.java:262)
      23:00:47 at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
      23:00:47 at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
      23:00:47 at java.lang.Thread.run(Thread.java:744)
      23:00:47 FATAL: null
      23:00:47 java.lang.NullPointerException
      23:00:47 at java.util.ArrayList.addAll(ArrayList.java:559)
      23:00:47 at hudson.scm.SubversionSCM.checkout(SubversionSCM.java:897)
      23:00:47 at hudson.scm.SubversionSCM.checkout(SubversionSCM.java:833)
      23:00:47 at hudson.scm.SCM.checkout(SCM.java:484)
      23:00:47 at hudson.model.AbstractProject.checkout(AbstractProject.java:1270)
      23:00:47 at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:609)
      23:00:47 at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:86)
      23:00:47 at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:531)
      23:00:47 at hudson.model.Run.execute(Run.java:1741)
      23:00:47 at hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:531)
      23:00:47 at hudson.model.ResourceController.execute(ResourceController.java:98)
      23:00:47 at hudson.model.Executor.run(Executor.java:374)

        Attachments

          Issue Links

            Activity

            Hide
            recena Manuel Recena Soto added a comment -

            Tim Styles, Please, file a new issue with your environment and configuration.

            Show
            recena Manuel Recena Soto added a comment - Tim Styles , Please, file a new issue with your environment and configuration.
            Hide
            timstyles Tim Styles added a comment - - edited

            I see this error when I use the SVN plugin (2.5.7) to checkout a repository with externals. The external repositories are on the same SVN server and require the same credentials.
            We are using a Debian (Jessie) box with Apache and the dav_svn module (http, not https). All software is up to date from stable. Authentication is using OpenLDAP and user jenkins has an account. I can successfully run 'svn update' as jenkins in the same directory, so the issue only occurs with the SVN plugin.

            The workaround I am using is to check 'Ignore externals' in the subversion section of the job configuration and then add an initial 'Execute shell' build step to run 'svn update'. This successfully completes the partial SVN update done by the SVN plugin.

            When the SVN plugin tries to update externals I see the following output:
            Updating http://metis/svn/xxx-software at revision '2016-01-09T21:31:33.950 +0000'
            org.tmatesoft.svn.core.SVNCancelException: svn: E200015: authentication cancelled
            at org.tmatesoft.svn.core.internal.wc.SVNErrorManager.cancel(SVNErrorManager.java:37)
            <snip>
            at org.tmatesoft.svn.core.internal.wc2.ng.SvnNgUpdate.run(SvnNgUpdate.java:38)
            <snip>
            at hudson.scm.subversion.UpdateUpdater$TaskImpl.perform(UpdateUpdater.java:158)
            <snip>
            ERROR: Failed to check out http://metis/svn/xxx-software

            (Full log at http://pastebin.com/EzttmrHm)

            Show
            timstyles Tim Styles added a comment - - edited I see this error when I use the SVN plugin (2.5.7) to checkout a repository with externals. The external repositories are on the same SVN server and require the same credentials. We are using a Debian (Jessie) box with Apache and the dav_svn module (http, not https). All software is up to date from stable. Authentication is using OpenLDAP and user jenkins has an account. I can successfully run 'svn update' as jenkins in the same directory, so the issue only occurs with the SVN plugin. The workaround I am using is to check 'Ignore externals' in the subversion section of the job configuration and then add an initial 'Execute shell' build step to run 'svn update'. This successfully completes the partial SVN update done by the SVN plugin. When the SVN plugin tries to update externals I see the following output: Updating http://metis/svn/xxx-software at revision '2016-01-09T21:31:33.950 +0000' org.tmatesoft.svn.core.SVNCancelException: svn: E200015: authentication cancelled at org.tmatesoft.svn.core.internal.wc.SVNErrorManager.cancel(SVNErrorManager.java:37) <snip> at org.tmatesoft.svn.core.internal.wc2.ng.SvnNgUpdate.run(SvnNgUpdate.java:38) <snip> at hudson.scm.subversion.UpdateUpdater$TaskImpl.perform(UpdateUpdater.java:158) <snip> ERROR: Failed to check out http://metis/svn/xxx-software (Full log at http://pastebin.com/EzttmrHm )
            Hide
            recena Manuel Recena Soto added a comment -

            An Tran, By the way, this ticket JENKINS-29340 is completely different and is solved.

            Show
            recena Manuel Recena Soto added a comment - An Tran , By the way, this ticket JENKINS-29340 is completely different and is solved.
            Hide
            recena Manuel Recena Soto added a comment -

            An Tran, I'll try it again but the most important thing is to produce the bug. I'm not sure if AD is involved here.

            Show
            recena Manuel Recena Soto added a comment - An Tran , I'll try it again but the most important thing is to produce the bug. I'm not sure if AD is involved here.
            Hide
            peacemoon An Tran added a comment -

            Manuel Recena Soto I wish I can post our settings here. But it's a complex master slave setup inside an enterprise network.
            One thing I can say that we didn't have this issue before we use the "SVN External" feature. After add that we start facing this error sporadically.

            I found some other tickets about this issue here:

            I tried everything from those tickets but couldn't make the error disappeared.

            Show
            peacemoon An Tran added a comment - Manuel Recena Soto I wish I can post our settings here. But it's a complex master slave setup inside an enterprise network. One thing I can say that we didn't have this issue before we use the "SVN External" feature. After add that we start facing this error sporadically. I found some other tickets about this issue here: Subversion fails to update externals once after external is changed. : https://issues.jenkins-ci.org/browse/JENKINS-25070 E200015: ISVNAuthentication provider did not provide credentials : https://issues.jenkins-ci.org/browse/JENKINS-29340 / Check for changes in folders linked via svn:externals fails due to missing credentials: https://issues.jenkins-ci.org/browse/JENKINS-21785 NullPointer & authentication cancelled occure immediately on SVN checkout: https://issues.jenkins-ci.org/browse/JENKINS-27977 I tried everything from those tickets but couldn't make the error disappeared.

              People

              • Assignee:
                recena Manuel Recena Soto
                Reporter:
                fleuryro Romuald Fleury
              • Votes:
                1 Vote for this issue
                Watchers:
                9 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: