Open GoogleCodeExporter opened 9 years ago
> But the issue is, Gerrit is merging the changes order in a strange way. First 389
> is merged and then 338 got merged.
I doubt that Gerrit did this merge in the wrong order. Have you checked the
commit graph of your repository?
Original comment by edwin.ke...@gmail.com
on 26 Jun 2015 at 5:53
[deleted comment]
You are correct. When I checked the commit graph, It is in the correct order.
But I dont know why the page "http://ip_address:8080/#/q/status:merged" (please
see the screen shot attached) is showing the merge order in the wrong order.
Whenever "submit" button is clicked on gerrit code-review screen, I am calling
the hook "change-merged" and in the hook I am using the below command to read
all the list of changes got merged.
GET http://ip_address:8080/changes/?q=status:merged
So, here this page status:merged is getting updated in the wrong order thats
why my list is also in the wrong when I am reading them. How can I read the
commits which got merged in the correct order.
Original comment by arunjobe...@gmail.com
on 26 Jun 2015 at 1:47
> But I dont know why the page "http://ip_address:8080/#/q/status:merged (please
> see the screen shot attached) is showing the merge order in the wrong order.
Query results like this are always sorted by last-updated timestamp and not by
merge order. It is not possible to choose a different sorting.
> How can I read the commits which got merged in the correct order.
Use git to fetch the branch and inspect the branch history.
Original comment by edwin.ke...@gmail.com
on 26 Jun 2015 at 1:54
[deleted comment]
> How can I read the commits which got merged in the correct order.
Use git to fetch the branch and inspect the branch history.
I am not sure if I can use git fetch or not. Because, multiple commits come
from multiple projects(repositories). For all the projects we are using this
Gerrit code review process. All of them must go through code review process. If
that is the case, each change could be from different every other.
No matter what projects I get, I am trying to populate the list and trying to
connect them with a ticketing system.
I am still confused :(
Original comment by arunjobe...@gmail.com
on 26 Jun 2015 at 2:07
Then you should maybe listen to the Gerrit stream-events [1]. This will give
you the merged events in the right order.
[1] https://gerrit-review.googlesource.com/Documentation/cmd-stream-events.html
Original comment by edwin.ke...@gmail.com
on 26 Jun 2015 at 2:14
Thank you for the link. I think stream events are using ssh, but in my case
both git and gerrit are on the same linux box. I am wondering that, I can not
ssh to the same box.
Original comment by arunjobe...@gmail.com
on 26 Jun 2015 at 2:17
You should be able to connect via SSH to Gerrit from the same machine. Pay
attention that Gerrit's SSH daemon by default listens on port 29418. Have a
look at [1].
[1] https://gerrit-review.googlesource.com/Documentation/user-upload.html#ssh
Original comment by edwin.ke...@gmail.com
on 26 Jun 2015 at 2:25
As the documentation says... I have generated the ssh keys from the box (where
actually Gerrit and Git both are residing in the same box) and pasted the keys
in Gerrit web interface.
This is like doing the ssh to the same box
and also "change-merged" hook file is obviously on the same box...
however, i tried as the document says to see my luck.. but this is what i am
getting .. below is the error:
[gerrituser@gerritbox01 .ssh]$ ssh -p 29418 gerrituser@gerritbox01
Warning: the RSA host key for '[gerritbox01]:29418' differs from the key for
the IP address '[##.##.##.##]:29418'
Offending key for IP in /home/gerrituser/.ssh/known_hosts:1
Matching host key in /home/gerrituser/.ssh/known_hosts:2
Are you sure you want to continue connecting (yes/no)? yes
Permission denied (publickey).
[gerrituser@gerritbox01 .ssh]$
Original comment by arunjobe...@gmail.com
on 26 Jun 2015 at 2:55
Also for your information, we are not using ssh to clone/push. we are using http
git clone http://username@##.##.##.##:8080/repository_name
Original comment by arunjobe...@gmail.com
on 26 Jun 2015 at 3:52
Original issue reported on code.google.com by
arunjobe...@gmail.com
on 25 Jun 2015 at 11:03Attachments: