•  
      request #3242 Appearance of superfluous push operations when migrating a repo to Gerrit
    Infos
    #3242
    Patrick Renaud (patrick.renaud)
    2013-05-28 16:51
    2013-05-01 20:28
    2063
    Details
    Appearance of superfluous push operations when migrating a repo to Gerrit
    The trace of gerrit ssh operations initiated by Tuleap when migrating a repo ends with three successive push operations:

    [2013-05-01 11:45:56,873 -0400] 0e715341 tuleap-gerrit-admin-user a/1000001 LOGIN FROM my-tuleap-test-server
    [2013-05-01 11:45:57,759 -0400] 0e715341 tuleap-gerrit-admin-user a/1000001 'git-receive-pack patrick/repo3' 3ms 524ms 0
    [2013-05-01 11:45:58,030 -0400] 0e715341 tuleap-gerrit-admin-user a/1000001 LOGOUT
    [2013-05-01 11:45:58,984 -0400] 6ea9efb2 tuleap-gerrit-admin-user a/1000001 LOGIN FROM my-tuleap-test-server
    [2013-05-01 11:45:59,731 -0400] 6ea9efb2 tuleap-gerrit-admin-user a/1000001 'git-receive-pack patrick/repo3' 4ms 387ms 0
    [2013-05-01 11:46:00,008 -0400] 6ea9efb2 tuleap-gerrit-admin-user a/1000001 LOGOUT
    [2013-05-01 11:46:00,958 -0400] ee94ff6f tuleap-gerrit-admin-user a/1000001 LOGIN FROM my-tuleap-test-server
    [2013-05-01 11:46:01,456 -0400] ee94ff6f tuleap-gerrit-admin-user a/1000001 'git-receive-pack patrick/repo3' 3ms 134ms 0
    [2013-05-01 11:46:01,696 -0400] ee94ff6f tuleap-gerrit-admin-user a/1000001 LOGOUT

    A single push operation from Tuleap to Gerrit should probably be sufficient to send all the existing data to Gerrit. Although the above seems a bit excessive it causes no apparent harm.

    Can you descrive the reason behind this?
    SCM/Gerrit
    5.12
    Empty
    • [ ] enhancement
    • [ ] internal improvement
    patricia.carrasco@ericsson.com, vladimir.cantiru@ericsson.com, Emilio Palmiero (empa)
    Stage
    Manuel Vacelet (vaceletm)
    Closed
    2013-05-28
    Attachments
    Empty
    References
    References list is empty

    Follow-ups

    User avatar
    • Status changed from Waiting for information to Verified
    • Assigned to changed from None to Manuel Vacelet (vaceletm)
    User avatar
    Yes it does. It confirms my suspicions. All is good then! :-)

    Thank you Manuel. You may close this ticket now.
    User avatar
    Hi Patrick,

    The first push is for refs/meta/config
    The second push is for branches (refs/heads)
    The third push is for tags (refs/tags)

    Does it answer the question ?
    User avatar
    Hi,

    Each command below results in a single 'git-receive-pack' operation on the server; this accounts for two such operations. We need to understand the source of the third (or first!) incantation of it.

    I suspect it may occur as a result of pushing a change to the ACL (refs/meta/config). Can you please confirm if my assumption is correct?

    • Is an Enhancement or an internal improvement? set to
    User avatar
    dylan bowden (dylan)2013-05-16 15:47
    Hi,

    From online documentation such as http://manpages.ubuntu.com/manpages/dapper/man1/git-receive-pack.1.html, I understand that 'git-receive-pack' is a command that is not called directly by a user but rather by 'git push' indirectly. Having looked at the Tuleap sources, there are indeed no instances of 'git-receive-pack' in the code and specifically not within the repository migration part.
    Thus, I began looking for instances of 'git push'. There are indeed multiple git pushes for various refs within the Tuleap migration code:

    git push $gerrit_project_url refs/heads/*:refs/heads/*; git push $gerrit_project_url refs/tags/*:refs/tags/*

    It is plausible that, through the inner-workings of git, one of these two actions results in a double instance of 'git-receive-pack'.

    Do you wish for us to dig deeper or is that enough information?
    Dylan