You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@kafka.apache.org by François Langelier <f....@gmail.com> on 2014/08/25 19:13:04 UTC

How retention is working

Hi!
I'm wondering how the retention time is working exactly...

I know that log.retention.{minutes,hours} and retention.ms (by topic) to
set the retention time and that there is log.retention.check.interval.ms
for deleting

But those properties work then i create the topic but can I change the
retention value of a topic after it was created?

If i restart my producer with another value for the retention.ms will it do
the trick?

If so, does all the messages of that topic will have the new retention
time?

Let say i had 1 week for retention and i change it to 1 day,  does at the
new retention check 6 day of retention will be deleted?

Thanks!


François Langelier
Étudiant en génie Logiciel - École de Technologie Supérieure
<http://www.etsmtl.ca/>
Capitaine Club Capra <http://capra.etsmtl.ca/>
VP-Communication - CS Games <http://csgames.org> 2014
Jeux de Génie <http://www.jdgets.com/> 2011 à 2014
Magistrat Fraternité du Piranha <http://fraternitedupiranha.com/>
Comité Organisateur Olympiades ÉTS 2012
Compétition Québécoise d'Ingénierie 2012 - Compétition Senior

Re: How retention is working

Posted by Philip O'Toole <ph...@yahoo.com.INVALID>.
Retention is per topic, per Kafka broker, it is nothing to do with the Producer. You do not need to restart the Producer for retention changes to take effect. You do, however, need to restart the broker however. Once restarted, all messages will then be subject to the new policy.

Philip

 
-----------------------------------------
http://www.philipotoole.com 


On Monday, August 25, 2014 10:13 AM, François Langelier <f....@gmail.com> wrote:
 


Hi!
I'm wondering how the retention time is working exactly...

I know that log.retention.{minutes,hours} and retention.ms (by topic) to
set the retention time and that there is log.retention.check.interval.ms
for deleting

But those properties work then i create the topic but can I change the
retention value of a topic after it was created?

If i restart my producer with another value for the retention.ms will it do
the trick?

If so, does all the messages of that topic will have the new retention
time?

Let say i had 1 week for retention and i change it to 1 day,  does at the
new retention check 6 day of retention will be deleted?

Thanks!


François Langelier
Étudiant en génie Logiciel - École de Technologie Supérieure
<http://www.etsmtl.ca/>
Capitaine Club Capra <http://capra.etsmtl.ca/>
VP-Communication - CS Games <http://csgames.org> 2014
Jeux de Génie <http://www.jdgets.com/> 2011 à 2014
Magistrat Fraternité du Piranha <http://fraternitedupiranha.com/>
Comité Organisateur Olympiades ÉTS 2012
Compétition Québécoise d'Ingénierie 2012 - Compétition Senior