<div dir="ltr">So, actually I have just to tune�sample_retention_policies to keep and aggregate statistics as long as I need!<div>Is there a way to reset those statistics (during development I think I will make several tests in a day, but I think I&#39;ll keep stats for a day so I need to reset those couters..)?</div>

<div>Moreover, I saw that detailed stats are available only for 10 seconds..do you think it could be feasible to keep detailed data for an entire day or does it occupy too much space on disk?</div><div>For example, I&#39;d like to do something like:</div>

<br>{rabbitmq_management, [{sample_retention_policies,<br>� � � � � � � � � � � � � [{global, � [{60, 5}, {3600, 60}, {86400, 1200}]},<br>� � � � � � � � � � � � � �{basic, � �[{60, 5},{3600, 60}, {86400, 1200}]},<br>� � � � � � � � � � � � � �{detailed, [{10, 5},{3600, 60}, {86400, 1200}]}<br>

� � � � � � � � � � � � ]},<br><br>What is not clear to me is which statistics provides each category..for example, detailed what information does affects?<div>If i ask for /api/queues, will I receive more or less data if I had also detailed infos?</div>

<div>Resolution defined in sample_retention_policies have different granularities in order to perform cumulative stats faster and save disk, right?</div><div>Because I could configure {basic, [{{86400, 5}]} but then I keep all 5-secs samples for all the day and also compute aggregate stats will require to pass all the samples..(correct me if I&#39;m wrong).</div>

<div>Will HTTP api returns cumulative stats only? sample_age and sample_incr parameters are useful only I want all samples, right?</div><div><div><div class="gmail_extra"><br>Thanks for the support,</div><div class="gmail_extra">

Flavio</div><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Jul 25, 2013 at 1:28 PM, Simon MacMullen <span dir="ltr">&lt;<a href="mailto:simon@rabbitmq.com" target="_blank">simon@rabbitmq.com</a>&gt;</span> wrote:<br>

<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div class="im">On 25/07/2013 10:45AM, Flavio Pompermaier wrote:<br>


<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
Yes, probably what I need is to correctly set those two parameters:<br>
� - sample_retention_policies<br>
� - collect_statistics_interval<br>
</blockquote>
<br></div>
It&#39;s not obvious to me that you want to change collect_statistics_interval.<div class="im"><br>
<br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
Are they strictly related or they serve different purposes?<br>
</blockquote>
<br></div>
Well, they both have to do with statistics.<br>
<br>
collect_statistics_interval controls how frequently the various components in RabbitMQ emit stats events. It therefore controls the maximum possible resolution of stats you can get. The expectation is usually that you would leave it alone, but if you had a huge number of not-quite-idle queues / channels / connections you might want to increase it so that your server does not spend all its time emitting stats events.<br>


<br>
sample_retention_policies controls how long the management plugin holds onto statistics, and with what resolution. You might want to change this if you want it to hold statistics for longer.<div class="im"><br>
<br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
How do I ask for global/basic/detailed cumulative stats (like those<br>
collected by sample_retention_policies)?<br>
</blockquote>
<br></div>
Those names refer to different classes of stats you can get through the web UI / HTTP API. See <a href="http://www.rabbitmq.com/management.html#sample-retention" target="_blank">http://www.rabbitmq.com/<u></u>management.html#sample-<u></u>retention</a> for the mapping.<div class="im">

<br>
<br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
I think that I need those metrics..<br>
With a small collect_statistics_interval (1 s) I have more precise data<br>
but more overhead on the broker,<br>
</blockquote>
<br></div>
Yes.<div class="im"><br>
<br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
but changing this parameters require also to change<br>
sample_retention_policies right?<br>
</blockquote>
<br></div>
No.<div class="im"><br>
<br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
Or it just run every 5 s and thus collects 5 samples (for default global<br>
conf for example)..?<br>
</blockquote>
<br></div>
Not sure what you mean. If collect_statistics_interval is shorter than the shortest resolution in sample_retention_policies you&#39;ll be doing more work for no gain.<br>
<br>
Cheers, Simon<br>
<br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div class="im">
<br>
Best,<br>
Flavio<br>
<br>
On Thu, Jul 25, 2013 at 11:28 AM, Simon MacMullen &lt;<a href="mailto:simon@rabbitmq.com" target="_blank">simon@rabbitmq.com</a><br></div><div class="im">
&lt;mailto:<a href="mailto:simon@rabbitmq.com" target="_blank">simon@rabbitmq.com</a>&gt;&gt; wrote:<br>
<br>
� � On 24/07/2013 6:17PM, Flavio Pompermaier wrote:<br>
<br>
� � � � have you ever tried to set statistics interval to something like<br>
� � � � a week?<br>
<br>
<br>
� � I assume you mean sample_retention_policies (i.e. how long we hold<br>
� � stats for) rather than collect_statistics_interval (i.e. how<br>
� � frequently the broker should emit stats for the management plugin to<br>
� � collect).<br>
<br>
� � No I haven&#39;t, although you should be fine as long as you reduce the<br>
� � resolution for data that&#39;s held for longer. Or put up with increased<br>
� � memory use.<br>
<br>
� � � � Does it affect performance?<br>
<br>
<br>
� � Shouldn&#39;t do particularly.<br>
<br>
� � Cheers, Simon<br></div></blockquote></blockquote></div><div dir="ltr"><p></p><p></p><p></p><p></p></div>
</div></div></div></div>