--
--
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.
For more options, visit https://groups.google.com/d/optout.
On 28 May 2015, at 09:18, 开心果 <7852...@qq.com> wrote:Hi Luca,That's what I want to know. Thanks a lot.
One more question, I know I can call "ssh -p <port> <host> gerrit stream-events" to get events, but not sure where to get JSON in gerrit server (ubuntu OS). Could you please help to advice?
BR,
Ying------------------ 原始邮件 ------------------发件人: "Luca Milanesio";<luca.mi...@gmail.com>;发送时间: 2015年5月28日(星期四) 下午2:46收件人: "开心果"<ying...@gmail.com>;抄送: "repo-discuss"<repo-d...@googlegroups.com>; "sy990361"<sy99...@hotmail.com>;主题: Re: how to monitor replication.log
On 1 Jun 2015, at 11:01, 开心果 <7852...@qq.com> wrote:
Hi Luca,
I know this is really good way to monitor replication plugin log. About how to monitor the log, we still have questions with command "ssh -p 29418 lucamilanesio@localhost gerrit stream-events". If try to write a script to call this command and we want to stop it after no new stream events added, then parse the logs. Could you please help to advice how to stop this command running inside script?
BR,
Ying------------------ 原始邮件 ------------------发件人: "Luca Milanesio";<luca.mi...@gmail.com>;发送时间: 2015年5月28日(星期四) 晚上6:05收件人: "开心果"<7852...@qq.com>;
You received this message because you are subscribed to a topic in the Google Groups "Repo and Gerrit Discussion" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/repo-discuss/0ZFK5T9DgkE/unsubscribe.
To unsubscribe from this group and all its topics, send an email to repo-discuss...@googlegroups.com.
I see … you’d like something like the stream events but saved to a log file. That doesn’t exist yet but you can easily create it yourself ;-)Luca.
On 1 Jun 2015, at 11:01, 开心果 <7852...@qq.com> wrote:
Hi Luca,
I know this is really good way to monitor replication plugin log. About how to monitor the log, we still have questions with command "ssh -p 29418 lucamilanesio@localhost gerrit stream-events". If try to write a script to call this command and we want to stop it after no new stream events added, then parse the logs. Could you please help to advice how to stop this command running inside script?
BR,
Ying
------------------ 原始邮件 ------------------
发件人: "Luca Milanesio";<luca.mi...@gmail.com>;发送时间: 2015年5月28日(星期四) 晚上6:05收件人: "开心果"<7852...@qq.com>;
抄送: "repo-discuss"<repo-dis...@googlegroups.com>; "sy990361"<sy99...@hotmail.com>;
主题: Re: how to monitor replication.log
Hi Ying,see below a sample session:lucamilanesio@skywalker-mac:github (master)$ ssh -p 29418 lucamilanesio@localhost gerrit stream-events
{"submitter":{"name":"Luca Milanesio","email":"lu...@milanesio.org","username":"lucamilanesio"},"refUpdate":{"oldRev":"d5fa13216c9882a3d3ecfba70e1fc4f91bd79657","newRev":"c563626a3166f029c60c92c12e678ba5738b5364","refName":"refs/meta/config","project":"lucamilanesio/rome"},"type":"ref-updated","eventCreatedOn":1432807398}
{"project":"lucamilanesio/rome","ref":"refs/meta/config","targetNode":"github.com","status":"succeeded","refStatus":"OK","type":"ref-replicated","eventCreatedOn":1432807414}
{"project":"lucamilanesio/rome","ref":"refs/meta/config","nodesCount":1,"type":"ref-replication-done","eventCreatedOn":1432807414}As you can see the replication start, status and end are provided as single-line JSON element in the stream events output.Luca.
On 28 May 2015, at 09:18, 开心果 <7852...@qq.com> wrote:
Hi Luca,
That's what I want to know. Thanks a lot.
One more question, I know I can call "ssh -p <port> <host> gerrit stream-events" to get events, but not sure where to get JSON in gerrit server (ubuntu OS). Could you please help to advice?
BR,
Ying------------------ 原始邮件 ------------------
发件人: "Luca Milanesio";<luca.mi...@gmail.com>;发送时间: 2015年5月28日(星期四) 下午2:46收件人: "开心果"<ying...@gmail.com>;
抄送: "repo-discuss"<repo-dis...@googlegroups.com>; "sy990361"<sy99...@hotmail.com>;
Hi,
It actually can be done.
Setup a rabbitmq server with the rabbitmq plugin in Gerrit. Then use logstash to read from the rabbitmq server and write to file or stdout. This delivers a json stream of gerrit events.
Going one step further you can use logstash to store the event data in an elasticsearch index and use kibana or grafana to display the event data in a realtime updated graph.
In the end rabbitmq is way more reliable than gerrit streamevents as well, because the persistency guarantees you will never loose any event.
Kind regards,
Remy
>>>>>> <mailto:repo-discuss+unsub...@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
>>>>>> <mailto:repo-discuss+unsub...@googlegroups.com>.
>>>>>> For more options, visit https://groups.google.com/d/optout.
>>>>>
>>>>
>>>
>>
>>
>> --
>> --
>> To unsubscribe, email repo-discuss...@googlegroups.com
>> <mailto:repo-discuss+unsub...@googlegroups.com>
>> More info at http://groups.google.com/group/repo-discuss?hl=en
>>
>> ---
>> You received this message because you are subscribed to a topic in
>> the Google Groups "Repo and Gerrit Discussion" group.
>> To unsubscribe from this topic, visit
>> https://groups.google.com/d/topic/repo-discuss/0ZFK5T9DgkE/unsubscribe.
>> To unsubscribe from this group and all its topics, send an email
>> to repo-discuss...@googlegroups.com
>> <mailto:repo-discuss+unsub...@googlegroups.com>.
>> For more options, visit https://groups.google.com/d/optout.
>
> --
> --
> To unsubscribe, email repo-discuss...@googlegroups.com
> <mailto:repo-discuss%2Bunsu...@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
> <mailto:repo-discuss+unsub...@googlegroups.com>.
> For more options, visit https://groups.google.com/d/optout.
>
> --
> --
> 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
> <mailto:repo-discuss+unsub...@googlegroups.com>.