Hi Euler, Unfortunately, Git questions are extremely difficult to give accurate answers on, as how you are using Git can differ (there are many different strategies that different institutions use based on their one preference/needs).
Just *one* strategy (that I've seen used) is to create your own custom branch for your site and merge in new versions of the DSpace code when doing an upgrade. In this strategy, you'd do something like: 1) Start your custom branch (named "mysite" in this example) from the DSpace v6.1 tag on a custom fork of the DSpace/DSpace repository, e.g. git checkout -b mysite dspace-6.1 2) Then make any changes to the "mysite" branch that you need. Doing a "git commit" for each. 3) When it's time to upgrade, merge in the new release of DSpace (in this case the DSpace v6.3 tag), e.g. git checkout mysite git merge dspace-6.3 The merge here might create merge conflicts (if you've changed files also changed in the new release). So, you may need to work through merge conflicts file by file before you can commit the changes back to your "mysite" branch. It's also possible to use "git diff" commands to see the differences before doing a merge, e.g. git diff dspace-6.1..mysite (see changes between mysite and v6.1, to see what you've customized) git diff dspace-6.1..dspace-6.3 (see the changes in DSpace between v6.1 and 6.3) I don't have any advice on doing this in IntelliJ, as I'm a novice with IntelliJ. Maybe others can respond to that though, if they use IntelliJ to help with managing their code in Git. As for why your site is still installing 6.1 instead of 6.3, that's really hard to say. My best guess is maybe one (or more) of your POM files (pom.xml) still reference 6.1 (so that the JARs that end up in [dspace]/lib/ and in webapps are still v6.1 JARs instead of v6.3). I'm not sure how that would have occurred though, but you should check whether the "dspace" JAR files have a version of 6.1....if so, then something went wrong in your last Git merge when you tried to upgrade to 6.3. Tim ________________________________ From: [email protected] <[email protected]> on behalf of euler <[email protected]> Sent: Friday, October 11, 2019 5:06 AM To: DSpace Technical Support <[email protected]> Subject: Re: [dspace-tech] Error during OAI import Hi Tim, I installed this DSpace instance using Git checkout when the latest stable release was still version 6.1. I tried many ways to upgrade to 6.3 as you suggested but by using Git and Intellij. After I committed all my local changes in my local branch, I then rebased it to version 6.3. I Did an mvn clean -U package, but after the webapps were deployed, I'm still having the same issue. If I run ./dspace version, it is showing that the version is still 6.1, although, in the web admin control panel, it says 6.3. I also tried deleting all my local and remote tags and then rebasing my local branch onto dspace-6.3 from upstream which points directly to https://github.com/DSpace/DSpace. I also tried merging instead of rebasing but still, my issue persists. I did my rebasing based on these resources: https://blog.jessitron.com/2012/10/13/git-rebase-inside-intellij-idea/. So my additional question now is, what is the best practice in DSpace when rebasing to the latest stable version? Is there a special way on how to rebase my local branch to the latest stable tag release? If I compare my local branch to the tag where I rebased it from, it says that my local branch is fully merged. I'm wondering why my version remained 6.1 despite I rebased it to 6.3? Although looking at the pom files, it is 6.3 but since you state that the error I receive when running oai import was due to the fact that the method was not created until version 6.3. I also don't know why mvn clean -U package has no effect because it obviously did not clear old JARs. Thanks in advance! euler On Thursday, October 10, 2019 at 2:54:22 AM UTC+8, Tim Donohue wrote: Hi euler, That "ItemService.findInArchiveOrWithdrawnNonDiscoverableModifiedSince()" method did not created until version 6.3. So, it sounds to me like you have somehow got some 6.3 related code or JARs running in your 6.1 installation? You should either upgrade to 6.3, or rebuild/reinstall 6.1 by running "mvn -U clean package" (which should clear out any old JARs before rebuilding). Good luck, Tim ________________________________ From: [email protected] <[email protected]> on behalf of euler <[email protected]> Sent: Wednesday, October 9, 2019 4:52 AM To: DSpace Technical Support <[email protected]> Subject: [dspace-tech] Error during OAI import Dear All, When I run oai import, I encountered the following error: $ ./dspace oai import -c -o OAI 2.0 manager action started Clearing index Index cleared Using full import. Full import java.lang.NoSuchMethodError: org.dspace.content.service.ItemService.findInArchiveOrWithdrawnNonDiscoverableModifiedSince(Lorg/dspace/core/Context;Ljava/util/Date;)Ljava/util/Iterator; at org.dspace.xoai.app.XOAI.indexAll(XOAI.java:226) at org.dspace.xoai.app.XOAI.index(XOAI.java:134) at org.dspace.xoai.app.XOAI.main(XOAI.java:560) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.dspace.app.launcher.ScriptLauncher.runOneCommand(ScriptLauncher.java:229) at org.dspace.app.launcher.ScriptLauncher.main(ScriptLauncher.java:81) What could be the reason for this error? I have also a different repository with an almost identical configurations but I'm not having this issue. I am running DSpace version 6.1 XMLUI Mirage2 on Windows Server 2012. Any help would be greatly appreciated. Thanks in advance, euler -- All messages to this mailing list should adhere to the DuraSpace Code of Conduct: https://duraspace.org/about/policies/code-of-conduct/ --- You received this message because you are subscribed to the Google Groups "DSpace Technical Support" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/dspace-tech/9de395e4-0882-4b4c-84ed-d12428ac7719%40googlegroups.com<https://groups.google.com/d/msgid/dspace-tech/9de395e4-0882-4b4c-84ed-d12428ac7719%40googlegroups.com?utm_medium=email&utm_source=footer>. -- All messages to this mailing list should adhere to the DuraSpace Code of Conduct: https://duraspace.org/about/policies/code-of-conduct/ --- You received this message because you are subscribed to the Google Groups "DSpace Technical Support" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]<mailto:[email protected]>. To view this discussion on the web visit https://groups.google.com/d/msgid/dspace-tech/ab486e29-c6d1-41a9-b51e-03e7a348c14c%40googlegroups.com<https://groups.google.com/d/msgid/dspace-tech/ab486e29-c6d1-41a9-b51e-03e7a348c14c%40googlegroups.com?utm_medium=email&utm_source=footer>. -- All messages to this mailing list should adhere to the DuraSpace Code of Conduct: https://duraspace.org/about/policies/code-of-conduct/ --- You received this message because you are subscribed to the Google Groups "DSpace Technical Support" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/dspace-tech/DM5PR22MB0572DF13DCA6113EFBD6BC14ED970%40DM5PR22MB0572.namprd22.prod.outlook.com.
