You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-user@lucene.apache.org by TOM <to...@foxmail.com> on 2017/11/09 10:56:35 UTC
A problem of tracking the commits of Lucene using SHA num
Thanks for your patience and helps.
Recently, I acquired a batch of commits’ SHA data of Lucene, of which the time span is from 2010 to 2015. In order to get original info, I tried to use these SHA data to track commits. First, I cloned Lucene repository to my local host, using the cmd git clone https:// https://github.com/apache/lucene-solr.git. Then, I used git show [commit SHA] to get commits’ history record, but failed with the CMD info like this:
>> git show be5672c0c242d658b7ce36f291b74c344de925c7
>> fatal: bad object be5672c0c242d658b7ce36f291b74c344de925c7
After that, I cloned another mirror of Apache Lucene & Solr (https://github.com/mdodsworth/lucene-solr, the update ended at 2014/08/30), and got the right record like this:
Moreover, I tried to track a commit using its title msg. However, for a same commit, e.g. LUCENE-5909: Fix stupid bug, I found different SHA nums from the two above mirror repositories (https://github.com/apache/lucene-solr/commit/3c0d111d07184e96a73ca6dc05c6227d839724e2 and https://github.com/mdodsworth/lucene-solr/commit/4bc8dde26371627d11c299f65c399ecb3240a34c), which confused me.
In summary, 1) did the method to generate SHA num of commit change once before? 2) because the second mirror repository ended its update since 2014, how can I track the whole commits of my dataset?
Thanks so much!
Re: A problem of tracking the commits of Lucene using SHA num
Posted by Chris Hostetter <ho...@fucit.org>.
: In the first few weeks of 2016, the Lucene/Solr project migrated from
: svn to git. Prior to this, there was a github mirror of the subversion
: repository, but when the official repository was converted, that github
: mirror was completely deleted, and replaced with an exact mirror of the
: official git repository.
the old "mirror" wasn't really a "mirror" so much as it was a "real time
svn-to-git conversion" that happened on the fly and generated synthetic
git SHAs for every svn commit.
: It is very likely that every SHA hash in github changed when that
: happened. If the information you are referencing was built from github
it is not just likeley, it is something that absolutely happened, and was
discussed at at the time: anyone who had a fork of the "github svn-to-git
mirror" needed to abandon it and re-clone the "new" migration which had
completley differnet SHAs
FWIW: the "mdodsworth/lucene-solr" repo you found on github appears to be
some random github user who cloned the "old" github mirror circa
~2014 (prior to the converstion) but never "fetched" new commits after
that, nor deleted it once the "real" svn-to-git migration for lucene-solr
took place.
It's possible if you have a lot of old SHAs that you want to correlate to
commits, that you could use that repo to try and identify some of the
commits -- but as shawn said: knowing where exactly that list or arbitrary
SHAs came from is kind of important for identifying exactly what they
mean.
Also -- What exactly are you trying to do? what is your objective?
https://people.apache.org/~hossman/#xyproblem
XY Problem
Your question appears to be an "XY Problem" ... that is: you are dealing
with "X", you are assuming "Y" will help you, and you are asking about "Y"
without giving more details about the "X" so that we can understand the
full issue. Perhaps the best solution doesn't involve "Y" at all?
See Also: http://www.perlmonks.org/index.pl?node_id=542341
-Hoss
http://www.lucidworks.com/
Re: A problem of tracking the commits of Lucene using SHA num
Posted by Shawn Heisey <ap...@elyograg.org>.
On 11/9/2017 3:56 AM, TOM wrote:
> Thanks for your patience and helps.
>
> Recently, I acquired a batch of commits’ SHA data of Lucene, of which the time span is from 2010 to 2015. In order to get original info, I tried to use these SHA data to track commits. First, I cloned Lucene repository to my local host, using the cmd git clone https:// https://github.com/apache/lucene-solr.git. Then, I used git show [commit SHA] to get commits’ history record, but failed with the CMD info like this:
>
>>> git show be5672c0c242d658b7ce36f291b74c344de925c7
Where did this information originate?
In the first few weeks of 2016, the Lucene/Solr project migrated from
svn to git. Prior to this, there was a github mirror of the subversion
repository, but when the official repository was converted, that github
mirror was completely deleted, and replaced with an exact mirror of the
official git repository.
https://issues.apache.org/jira/browse/LUCENE-6937
It is very likely that every SHA hash in github changed when that
happened. If the information you are referencing was built from github
*before* the official repository was changed, it is likely that it is
completely useless now. The fact that your information covers 2010 to
2015 probably means that it was generated from that repository that no
longer exists.
Thanks,
Shawn