-
Notifications
You must be signed in to change notification settings - Fork 34
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unable to run the command line extension with 6.x RTC #44
Comments
Hi Could you provide details to your used rtc-version and the libs you used? You could also try to run the provided docker image: https://github.com/rtcTo/rtc2git-docker |
No problem. I have patched https://github.com/rtcTo/rtc2git to suit my use cases for now and in case there is a need to switch to the Java variant, I will end up using the Docker Image probably. |
I am facing the same issue now that after cloning and while running the launch configuration rtc2git Error: |
There is currently no solution. It seems rtc2gitcli not compatible with the rtc 6.x libs. I dont know if the docker image is facing the same problem. Maybe you can make it with rtc2git, investigate the issue here yourself or wait. |
We use RTC 5.0.2. so it is not the case with 6.x libs right? |
sorry, I used scmtools 6.x before. but now am using 5.0.2 and now getting the below error - How can I get rid of this one. com.ibm.team.rtc.cli.infrastructure.internal.core.ISubcommandDefinition$LoadOptionsException: org.eclipse.core.runtime.CoreException: Plug-in to.rtc.cli.migrate was unable to load class to.rtc.cli.migrate.git.MigrateToGitOptions. |
Please create a separate issue for that. Also please include if you workspace has any errors. |
ok, logged #46 |
Ran into the same issue (despite it building fine, no errors, no issues with the target platform as per the Wiki, all Maven dependencies downloading locally just fine.) There is a workaround you can do (I've verified this is working on my RTC 6.0.4 instance) to get this working outside of the Eclipse run configuration. Once you have everything building/compiling fine in Eclipse, right-click on the cli.extension project from Eclipse Navigator (or whatever project you called it during import), select Export, expand Plug-in Development and select Deployable plug-ins and fragments, hit Next. Choose a directory destination to export this plug-in jar to (I used the target directory within the project), and hit Finish. That will export this jar, go to the directory and copy it (was named, by default, to.rtc.cli.migrate_1.0.1.jar in my instance) to the plugins directory in your SCMTools directory (.../path/to/jazz/scmtools/eclipse/plugins). Once you drop the plug-in .jar in that directory, open a command-line and go to the eclipse directory in that same SCMTools instance where scm.exe exists.
You should see the command migrate-to-git |
@solzun thanks. I am upgrading from RTC v5.0.2 to RTC 6.0.6. I am able to run the migration tool following your steps. |
Thanks a lot solzun for giving this workaround. This will help a lot of people :) |
seems that the above solution not working on 6.0.5 |
What is the issue you receive on 6.0.5? The only gotcha I have noticed that was introduced after 6.0.2 is that the "scm load" fails if the repository workspace was loaded elsewhere prior to executing the integration. The load command now has an override/force switch to load the sandbox regardless of the server knows it was previously loaded elsewhere. |
Exact same issue that is on very first message here, got resolved with downgrade to 6.0.4 |
I followed solzun's workaround and I can see the command migrate-to-git when I run scm help from the command line window inside the SCMtools eclipse directory. But, when I try to run the rtc2git.launch inside of Eclipse, I still get the same error. Is there something else I need to do in Eclipse to get it to work? |
@amgriffi After you copied the jar which is mentioned in solzun's workaround, you dont need eclipse for starting rtc2gitcli. (therefore you dont need to run the rtc2git.launch inside eclipse). You simply type scm -help in your regular cmd or in the scmtools folder (where you copied the jar), then it should work :) EDIT: Sorry for my late answer |
@WtfJoke Yes, thank you, I eventually figured that out. |
Hello, I am performing RTC to git migration using cli.extension
I am facing below error |
@solzun , can't find export option in your provided solution Once you have everything building/compiling fine in Eclipse, right-click on the cli.extension project from Eclipse Navigator (or whatever project you called it during import), select Export, expand Plug-in Development and select Deployable plug-ins and fragments, hit Next. Choose a directory destination to export this plug-in jar to (I used the target directory within the project), and hit Finish. |
@solzun I am able to run migrate-to-git command following your steps. But now I am getting following error. Can you please help on this [2019-12-05 17:43:33] org.eclipse.jgit.api.errors.JGitInternalException: Exception caught during execution of add command |
I perfromed migration for some of my project from RTC to Bitbucket, however observed some descripencies.
|
Could you please share exact steps? Have you performed migration with this tool? |
Yes, I had the same error, what I found is that for the first few changesets, typically, where the team established the entire codebase so there are probably thousands of files in those first few commits, the Git commit didn't yet finish before control released back to the Java process orchestrating the entire workflow and you run into what is probably a filesystem contention/race-condition issue. I simply restart the process over-and-over until it finished and ran, which it did, so I wrapped my "scm migrate-to-git" calls in a loop (Powershell, Bash, whatever you want to use) to keep restarting it until it worked. |
If you aren't seeing history, it's probably something one of two things happening:
|
Strange, it's a good thing that IBM supports n-1 compatibility, so using 6.0.4's CLI should work even going into the current 7.x releases, we'll be doing this again soon, so I'll check compatibility with 7.x. I'm pretty sure I did this with 6.0.6.1 with modern iFix patches applied, but it's been years, I can't recall off the top of my head. I'll report here if it's an issue. |
The README.MD on the landing page for this repo explains the steps, the command is the best part to understand: This is also key:
Really, if you want to successfully run this, you need to understand the concepts of what you're doing, once you know, you can work backwards into RTC Eclipse to set everything up and validate it. When I have to re-run this and get it fresh in my head again, I'll update the README.MD documentation to be more specific, but for now, this is what I recall:
The key thing here is you need to 'zeroize/nullify' the history for one of the workspaces, and I cannot recall if it's the SOURCE_WORKSPACE or TARGET_WORKSPACE, meaning, you need to add all the same component(s) from your flow target of history and then right-click those components in RTC Eclipse and reset them to "1: Initial Baseline" which is the first baseline of any component when it first is created and empty. This sets the history to nothing for the workspace. When you kick off the script, what it does is it diffs the workspace against the flow target's history, aggregates the total amount of changesets, orders them by created date (it should do this by delivery date, but I don't think this feature was around in RTC when this plugin was written, probably a good pull request to make it an option so your history is "harmonized" in RTC-speak), then it puts those changesets, in created order, in an array and just walks through the loop: accept the changeset into the TARGET_WORKSPACE, load it to disk, then git-commit it, amend the Git commit to match the author and commit-time, then wash-rinse-repeat until you've processed all changesets. When I run this again soon, I'll put in a PR for the README.MD to really nail this down. |
Hello,
I ran the steps mentioned at https://github.com/rtcTo/rtc2gitcli/wiki/Setup but I get the following error while running the launch configuration rtc2git
Error:
Problem running 'help':
Unknown subcommand "migrate-to-git". Try 'scm help' for more information.
Any pointers for me to proceed?
The text was updated successfully, but these errors were encountered: