On 25 Feb 2021, at 20:38, sporzio <spo...@gmail.com> wrote:We currently have 2 independent Gerrit servers running to host our projects. One is based on some historical projects and we would like to migrate all those to our newer server which has better capabilities and more storage and will result in less maintenance overall. Is it possible to somehow merge the two together without losing the existing review history from either server?
Thanks in advance for any help.-S
--
--
To unsubscribe, email repo-discuss...@googlegroups.com
More info at http://groups.google.com/group/repo-discuss?hl=en
---
You received this message because you are subscribed to the Google Groups "Repo and Gerrit Discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to repo-discuss...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/repo-discuss/994086ee-3cbc-4f3b-a8b8-950573ff8e44n%40googlegroups.com.
We currently have 2 independent Gerrit servers running to host our projects. One is based on some historical projects and we would like to migrate all those to our newer server which has better capabilities and more storage and will result in less maintenance overall. Is it possible to somehow merge the two together without losing the existing review history from either server?
Google Germany GmbH, Erika-Mann-Strasse 33, 80636 Munich
Registergericht und -nummer: Hamburg, HRB 86891
Sitz der Gesellschaft: Hamburg
Geschäftsführer: Paul Manicle, Halimah DeLaine Prado
>>
>> * All NoteDb commits have to have their server ID (the host that the
>> server uses in author/comitter fields commits rewritten)
Yeah, I never understood why we decide to include the server-id in NoteDb.
>> * All user IDs change, so a mapping needs to be applied to the NoteDb data
And here we could have used e-mails, which aren’t linked to the internals of the old-times user-id sequences.
However, the devil is in the details and some of the “legacy” of ReviewDb stuck with us, such as the change numbers, which were linked to a sequence on the DBMS, that is obviously not portable.
When we moved to NoteDb we just moved that concept to All-Projects.git without getting rid of it.
Bottom line: we are without ReviewDb and the “shortcuts” of updating the DBMS and, at the same time, we haven’t resolved the change number issue either.
It is a very unfortunate position, I know :-(
Luca.
On Tue, Mar 2, 2021 at 11:24 PM Luca Milanesio <luca.mi...@gmail.com> wrote:>>
>> * All NoteDb commits have to have their server ID (the host that the
>> server uses in author/comitter fields commits rewritten)
Yeah, I never understood why we decide to include the server-id in NoteDb.
>> * All user IDs change, so a mapping needs to be applied to the NoteDb data
And here we could have used e-mails, which aren’t linked to the internals of the old-times user-id sequences.
they are considered personal data, so persisting the email is problematic for GDPR purposes. Also, email addresses can actually move between accounts, while account IDs can'tHowever, the devil is in the details and some of the “legacy” of ReviewDb stuck with us, such as the change numbers, which were linked to a sequence on the DBMS, that is obviously not portable.
When we moved to NoteDb we just moved that concept to All-Projects.git without getting rid of it.The numbers are the easiest to fix. You just have to allocate a new one. The change number is not persisted in the NoteDb data for that change, so you could easily assign a change to a new number. The real problem is in the data that has to be rewritten to be be adapted to fit within the destination server (ie. accounts and server ID).
On 3 Mar 2021, at 09:33, David Ostrovsky <david.o...@gmail.com> wrote:On Tue, Mar 2, 2021 at 11:24 PM Luca Milanesio <luca.mi...@gmail.com> wrote:>>
>> * All NoteDb commits have to have their server ID (the host that the
>> server uses in author/comitter fields commits rewritten)
Yeah, I never understood why we decide to include the server-id in NoteDb.
>> * All user IDs change, so a mapping needs to be applied to the NoteDb data
And here we could have used e-mails, which aren’t linked to the internals of the old-times user-id sequences.they are considered personal data, so persisting the email is problematic for GDPR purposes. Also, email addresses can actually move between accounts, while account IDs can'tHowever, the devil is in the details and some of the “legacy” of ReviewDb stuck with us, such as the change numbers, which were linked to a sequence on the DBMS, that is obviously not portable.
When we moved to NoteDb we just moved that concept to All-Projects.git without getting rid of it.The numbers are the easiest to fix. You just have to allocate a new one. The change number is not persisted in the NoteDb data for that change, so you could easily assign a change to a new number. The real problem is in the data that has to be rewritten to be be adapted to fit within the destination server (ie. accounts and server ID).If I look at change number 298465 on gerrit-review: [1]$ git ls-remote | grep 298465ce0ebd524edab6292e407c0122725077429374b7 refs/changes/65/298465/1cb48f1bebd1f58e86a3720749cbdcf75c0345bcd refs/changes/65/298465/2422b89e29a1827cf159a8901965fb3ebfb032923 refs/changes/65/298465/metaWhy it have to be unique across all projects on the gerrit site?
Atlassian's Jira does it too: you have FOO-42 and BAR-42 issues.GitHub does this too: PR 28 are different for bazelbuild and gerrit projects:Of course, multi-tenancy Gerrit installations could emulate that setup, so thatthe changes with the same number could be created:Alternative approach would be to have change number (and sequence) per project.
As the consequence we would have multiple changes with the same number onone gerrit site.We already adapted the URL to include project name:
The query predicate "number:42" wouldn't be unique, though.
The migration path wouldn't be trivial, though, but we should consider resolvingthis technical debt from global database sequence era in the next major Gerrit release 4.0.
Bottom line: we are without ReviewDb and the “shortcuts” of updating the DBMS and, at the same time, we haven’t resolved the change number issue either.
It is a very unfortunate position, I know :-(
Luca.--Han-Wen Nienhuys - Google MunichI work 80%. Don't expect answers from me on Fridays.--Google Germany GmbH, Erika-Mann-Strasse 33, 80636 MunichRegistergericht und -nummer: Hamburg, HRB 86891Sitz der Gesellschaft: HamburgGeschäftsführer: Paul Manicle, Halimah DeLaine Prado
--
--
To unsubscribe, email repo-discuss...@googlegroups.com
More info at http://groups.google.com/group/repo-discuss?hl=en
---
You received this message because you are subscribed to the Google Groups "Repo and Gerrit Discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to repo-discuss...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/repo-discuss/51a7a202-6339-4de7-ba9b-80a508303a87n%40googlegroups.com.
han...@google.com schrieb am Dienstag, 2. März 2021 um 23:44:51 UTC+1:On Tue, Mar 2, 2021 at 11:24 PM Luca Milanesio <luca.mi...@gmail.com> wrote:>>
>> * All NoteDb commits have to have their server ID (the host that the
>> server uses in author/comitter fields commits rewritten)
Yeah, I never understood why we decide to include the server-id in NoteDb.
>> * All user IDs change, so a mapping needs to be applied to the NoteDb data
And here we could have used e-mails, which aren’t linked to the internals of the old-times user-id sequences.
they are considered personal data, so persisting the email is problematic for GDPR purposes. Also, email addresses can actually move between accounts, while account IDs can'tHowever, the devil is in the details and some of the “legacy” of ReviewDb stuck with us, such as the change numbers, which were linked to a sequence on the DBMS, that is obviously not portable.
When we moved to NoteDb we just moved that concept to All-Projects.git without getting rid of it.The numbers are the easiest to fix. You just have to allocate a new one. The change number is not persisted in the NoteDb data for that change, so you could easily assign a change to a new number. The real problem is in the data that has to be rewritten to be be adapted to fit within the destination server (ie. accounts and server ID).If I look at change number 298465 on gerrit-review: [1]$ git ls-remote | grep 298465ce0ebd524edab6292e407c0122725077429374b7 refs/changes/65/298465/1cb48f1bebd1f58e86a3720749cbdcf75c0345bcd refs/changes/65/298465/2422b89e29a1827cf159a8901965fb3ebfb032923 refs/changes/65/298465/metaWhy it have to be unique across all projects on the gerrit site?Atlassian's Jira does it too: you have FOO-42 and BAR-42 issues.
On 3 Mar 2021, at 09:42, 'Han-Wen Nienhuys' via Repo and Gerrit Discussion <repo-d...@googlegroups.com> wrote:On Wed, Mar 3, 2021 at 10:33 AM David Ostrovsky <david.o...@gmail.com> wrote:On Tue, Mar 2, 2021 at 11:24 PM Luca Milanesio <luca.mi...@gmail.com> wrote:>>
>> * All NoteDb commits have to have their server ID (the host that the
>> server uses in author/comitter fields commits rewritten)
Yeah, I never understood why we decide to include the server-id in NoteDb.
>> * All user IDs change, so a mapping needs to be applied to the NoteDb data
And here we could have used e-mails, which aren’t linked to the internals of the old-times user-id sequences.they are considered personal data, so persisting the email is problematic for GDPR purposes. Also, email addresses can actually move between accounts, while account IDs can'tHowever, the devil is in the details and some of the “legacy” of ReviewDb stuck with us, such as the change numbers, which were linked to a sequence on the DBMS, that is obviously not portable.
When we moved to NoteDb we just moved that concept to All-Projects.git without getting rid of it.The numbers are the easiest to fix. You just have to allocate a new one. The change number is not persisted in the NoteDb data for that change, so you could easily assign a change to a new number. The real problem is in the data that has to be rewritten to be be adapted to fit within the destination server (ie. accounts and server ID).If I look at change number 298465 on gerrit-review: [1]$ git ls-remote | grep 298465ce0ebd524edab6292e407c0122725077429374b7 refs/changes/65/298465/1cb48f1bebd1f58e86a3720749cbdcf75c0345bcd refs/changes/65/298465/2422b89e29a1827cf159a8901965fb3ebfb032923 refs/changes/65/298465/metaWhy it have to be unique across all projects on the gerrit site?Atlassian's Jira does it too: you have FOO-42 and BAR-42 issues.The change number has always been globally unique, and Dave at the time took a lot of care to avoid encoding the change number in NoteDb data.
If you break that assumption, you break any and all clients that operate on that assumption.
It's already hard enough to upgrade Gerrit; let's not make it even harder.
On Thu, Feb 25, 2021 at 9:40 PM sporzio <spo...@gmail.com> wrote:We currently have 2 independent Gerrit servers running to host our projects. One is based on some historical projects and we would like to migrate all those to our newer server which has better capabilities and more storage and will result in less maintenance overall. Is it possible to somehow merge the two together without losing the existing review history from either server?With NoteDb, this is technically possible. There are a couple of things that need to be resolved:* All NoteDb commits have to have their server ID (the host that the server uses in author/comitter fields commits rewritten)* All user IDs change, so a mapping needs to be applied to the NoteDb data* New numeric change IDs have to be allocated to avoid conflicts.
It's something we have considered implementing, but we never had anyone need it badly enough to get it prioritized.--Han-Wen Nienhuys - Google MunichI work 80%. Don't expect answers from me on Fridays.--Google Germany GmbH, Erika-Mann-Strasse 33, 80636 Munich
Registergericht und -nummer: Hamburg, HRB 86891
Sitz der Gesellschaft: Hamburg
Geschäftsführer: Paul Manicle, Halimah DeLaine Prado