Add backlog quota configuration on topic - #2659
Conversation
|
I think we should also try to think of a more general approach for this problem. Right now, the only per-topic policy override is for the authorization settings. While is good to add backlog retention override, in future we might need to add more for each policy tunable. For sake of setting a format in the policies metadata, we could have a map with all the per-topic overrides that can support all the available policies. Then we can kind of reuse the same code for setting specific policies on the namespace, to apply also for the single topic case. |
|
regarding the context of this change, @codelipenghui has identified the policies can be overridden at topic level. and he is working on adding those policies to topic level. I believe that is his first change. regarding the approach for topic level policy, are you suggesting making a more general approach? Can you describe more about your suggested approach? It is a bit unclear to me how this can be made with a general map. |
Following configurations can overwrite in topic level:
Should we need a issue to tracker them. |
|
@codelipenghui yes. let's create an issue as a master issue for tracking the support of topic-level policies. |
There was a problem hiding this comment.
For now, copy the namespace policy as the topic policy. I think no need to copy the namespace policy, just set current configuration to the topic policy, otherwise change the namespace policy can't affect topics which has it's local policy(copy from the namespace before).
|
#2688 This is the master ticket to tracking this PR |
|
@merlimat can you spend some time reviewing this? |
|
it seems that this PR would need address system topic first. |
…ersistentTopicsBase.
5a226f2 to
df62825
Compare
|
run java8 tests |
|
run java8 tests |
|
Close via #7646 |
Motivation
Support set backlog quota on topic level.
Modifications
Support
get-backlog-quotason topic level.Support
set-backlog-quotaon topic level.Support
remove-backlog-quotaon topic level.Results
If set backlog quota on a topic, backlog policy will use the backlog quota setting on topic, otherwise back to use backlog quota setting on namespace which topic belong to.