[JIRA] [subversion-plugin] (JENKINS-30197) Migration from Subversion 1.x to 2.5.1+ can fail (ClassCastException on SCM)

4 views
Skip to first unread message

tom.gl@free.fr (JIRA)

unread,
Aug 28, 2015, 8:26:01 AM8/28/15
to jenkinsc...@googlegroups.com
Thomas de Grenier de Latour created an issue
 
Jenkins / Bug JENKINS-30197
Migration from Subversion 1.x to 2.5.1+ can fail (ClassCastException on SCM)
Issue Type: Bug Bug
Assignee: Unassigned
Components: subversion-plugin
Created: 28/Aug/15 12:25 PM
Priority: Major Major
Reporter: Thomas de Grenier de Latour

The Credentials migration code added in subversion-plugin 2.5.1 fails when hitting a job which is not (anymore?) using SubversionSCM, but which still has a "subversion.credentials" file in its job directory.

SEVERE: Failed SubversionSCM.perJobCredentialsMigration
java.lang.Error: java.lang.reflect.InvocationTargetException
at hudson.init.TaskMethodFinder.invoke(TaskMethodFinder.java:109)
at hudson.init.TaskMethodFinder$TaskImpl.run(TaskMethodFinder.java:169)
at org.jvnet.hudson.reactor.Reactor.runTask(Reactor.java:282)
at jenkins.model.Jenkins$7.runTask(Jenkins.java:903)
at org.jvnet.hudson.reactor.Reactor$2.run(Reactor.java:210)
at org.jvnet.hudson.reactor.Reactor$Node.run(Reactor.java:117)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
at java.lang.Thread.run(Thread.java:745)
Caused by: java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at hudson.init.TaskMethodFinder.invoke(TaskMethodFinder.java:105)
... 8 more
Caused by: java.lang.ClassCastException: hudson.plugins.git.GitSCM cannot be cast to hudson.scm.SubversionSCM
at hudson.scm.PerJobCredentialStore.migrateCredentials(PerJobCredentialStore.java:120)
at hudson.scm.SubversionSCM$DescriptorImpl.migratePerJobCredentials(SubversionSCM.java:1651)
at hudson.scm.SubversionSCM.perJobCredentialsMigration(SubversionSCM.java:1582)
... 13 more

Add Comment Add Comment
 
This message was sent by Atlassian JIRA (v6.4.2#64017-sha1:e244265)
Atlassian logo

recena@gmail.com (JIRA)

unread,
Aug 28, 2015, 8:37:02 AM8/28/15
to jenkinsc...@googlegroups.com
Manuel Jesús Recena Soto started work on Bug JENKINS-30197
 
Change By: Manuel Jesús Recena Soto
Status: Open In Progress

recena@gmail.com (JIRA)

unread,
Aug 28, 2015, 8:37:02 AM8/28/15
to jenkinsc...@googlegroups.com

recena@gmail.com (JIRA)

unread,
Aug 28, 2015, 8:38:01 AM8/28/15
to jenkinsc...@googlegroups.com
Manuel Jesús Recena Soto updated an issue
The Credentials migration code added in subversion-plugin 2.5.1 fails when hitting a job which is not (anymore?) using SubversionSCM, but which still has a "subversion.credentials" file in its job directory.

{code}
SEVERE: Failed SubversionSCM.perJobCredentialsMigration
java.lang.Error: java.lang.reflect.InvocationTargetException
    at hudson.init.TaskMethodFinder.invoke(TaskMethodFinder.java:109)
    at hudson.init.TaskMethodFinder$TaskImpl.run(TaskMethodFinder.java:169)
    at org.jvnet.hudson.reactor.Reactor.runTask(Reactor.java:282)
    at jenkins.model.Jenkins$7.runTask(Jenkins.java:903)
    at org.jvnet.hudson.reactor.Reactor$2.run(Reactor.java:210)
    at org.jvnet.hudson.reactor.Reactor$Node.run(Reactor.java:117)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
    at java.lang.Thread.run(Thread.java:745)
Caused by: java.lang.reflect.InvocationTargetException
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:606)
    at hudson.init.TaskMethodFinder.invoke(TaskMethodFinder.java:105)
    ... 8 more
Caused by: java.lang.ClassCastException: hudson.plugins.git.GitSCM cannot be cast to hudson.scm.SubversionSCM
    at hudson.scm.PerJobCredentialStore.migrateCredentials(PerJobCredentialStore.java:120)
    at hudson.scm.SubversionSCM$DescriptorImpl.migratePerJobCredentials(SubversionSCM.java:1651)
    at hudson.scm.SubversionSCM.perJobCredentialsMigration(SubversionSCM.java:1582)
    ... 13 more

{code}

scm_issue_link@java.net (JIRA)

unread,
Aug 29, 2015, 3:57:03 PM8/29/15
to jenkinsc...@googlegroups.com
SCM/JIRA link daemon commented on Bug JENKINS-30197
 
Re: Migration from Subversion 1.x to 2.5.1+ can fail (ClassCastException on SCM)

Code changed in jenkins
User: Manuel Recena
Path:
src/main/java/hudson/scm/SubversionSCM.java
http://jenkins-ci.org/commit/subversion-plugin/606d95849828e2294fa372ddf9be6e0f90e5cb48
Log:
Merge pull request #135 from thomasgl-orange/fix-migrateCredentials-ClassCastException

JENKINS-30197 ClassCastException when migrating credentials

Compare: https://github.com/jenkinsci/subversion-plugin/compare/ab24371826eb...606d95849828

recena@gmail.com (JIRA)

unread,
Aug 29, 2015, 3:58:01 PM8/29/15
to jenkinsc...@googlegroups.com

recena@gmail.com (JIRA)

unread,
Sep 7, 2015, 3:17:02 PM9/7/15
to jenkinsc...@googlegroups.com

tom.gl@free.fr (JIRA)

unread,
Feb 11, 2020, 3:27:04 AM2/11/20
to jenkinsc...@googlegroups.com
Thomas de Grenier de Latour closed an issue as Fixed
 

Closing my old resolved issues...

Change By:
Status: Resolved Closed
This message was sent by Atlassian Jira (v7.13.6#713006-sha1:cc4451f)
Atlassian logo
Reply all
Reply to author
Forward
0 new messages