[ 
https://issues.apache.org/jira/browse/KAFKA-4200?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15509782#comment-15509782
 ] 

ASF GitHub Bot commented on KAFKA-4200:
---------------------------------------

GitHub user benstopford opened a pull request:

    https://github.com/apache/kafka/pull/1896

    KAFKA-4200: Fix throttle argument in kafka-reassign-partitions.sh

    Simple jira which alters two things: 
    
    1. kafka-reassign-partitions --verify prints Throttle was removed 
regardless of whether a throttle was applied. It should only print this if the 
value was actually changed.
    
    2. --verify should exception if the —throttle argument. (check generate too)
    
    To test this I extracted all validation logic into a separate method and 
added a test which covers the majority of combinations. The validation logic 
was retained as is, other than implementing (2) and adding validation to the 
--broker-list option which you can currently apply to any of hte main actions 
(where it is ignored). Requirement 1 was tested manually (as it's just 
println). 
    
    Testing:
    - Build passes locally. 
    - System test reassign_partitions_test.py also passes.
     

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/benstopford/kafka KAFKA-4200

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/kafka/pull/1896.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #1896
    
----
commit f85efead9c468d5d6e906a5c11f573a36d620244
Author: Ben Stopford <benstopf...@gmail.com>
Date:   2016-09-21T09:26:50Z

    KAFKA-4200: kafka-reassign-partitions —-verify prints "Throttle was 
removed" regardless of whether a throttle was applied. It should only print 
this if the value was actually changed. Tested this maually ensuring the value 
is not printed when we call verify whilst the rebalance is running, but does 
print the value when running verify when the throttle completes. Rerunning 
verify after the throttle completes also does not print the line.

commit 843c00c3cbee354fcfb1f0fdda5f77addd4b6eb4
Author: Ben Stopford <benstopf...@gmail.com>
Date:   2016-09-21T12:15:37Z

    KAFKA-4200: kafka-reassign-partitions —-verify prints "Throttle was 
removed" regardless of whether a throttle was applied. It should only print 
this if the value was actually changed. Tested this maually ensuring the value 
is not printed when we call verify whilst the rebalance is running, but does 
print the value when running verify when the throttle completes. Rerunning 
verify after the throttle completes also does not print the line.

----


> Minor issue with throttle argument in kafka-reassign-partitions.sh
> ------------------------------------------------------------------
>
>                 Key: KAFKA-4200
>                 URL: https://issues.apache.org/jira/browse/KAFKA-4200
>             Project: Kafka
>          Issue Type: Bug
>    Affects Versions: 0.10.1.0
>            Reporter: Ben Stopford
>            Assignee: Ben Stopford
>
> 1.
> kafka-reassign-partitions —-verify prints Throttle was removed regardless of 
> whether a throttle was applied. It should only print this if the value was 
> actually changed. 
> 2.
> —verify should exception if the —throttle argument. (check generate too)



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to