You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@kafka.apache.org by ijuma <gi...@git.apache.org> on 2016/12/17 15:02:35 UTC

[GitHub] kafka pull request #2271: MINOR: Improvements to Record related classes (WIP...

GitHub user ijuma opened a pull request:

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

    MINOR: Improvements to Record related classes (WIP)

    Jason recently cleaned things up significantly by consolidating the Message/Record classes into the common Java code in the clients module. While reviewing that, I noticed a few things that could be improved a little more.
    
    I am creating the PR now so that Jenkins can run, but it's a work in progress. In addition, we should review and merge https://github.com/apache/kafka/pull/2268 before this is reviewed.

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

    $ git pull https://github.com/ijuma/kafka records-minor-fixes

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

    https://github.com/apache/kafka/pull/2271.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 #2271
    
----
commit a02bb2ad56c7b4d96cd0b188ca6129442085e3db
Author: Ismael Juma <is...@juma.me.uk>
Date:   2016-12-16T17:29:12Z

    MINOR: Replace TopicAndPartition with TopicPartition in `Log` and `ReplicaManager`
    
    And other code that calls those two classes. To be done separately: Controller and
    ZkUtils.

commit 40bee6847d98c92b1af6a1a1466dfe9f3eadfb8a
Author: Ismael Juma <is...@juma.me.uk>
Date:   2016-12-17T14:38:21Z

    Minor fix in `KafkaStreamsTest`
    
    This causes compilation errors in IntelliJ in some scenarios and
    there\u2019s no reason to use `Long` over `long` here.

commit d961bf71339ac4bba34cdffcafa74f341c627358
Author: Ismael Juma <is...@juma.me.uk>
Date:   2016-12-17T14:41:10Z

    Remove unused parameter in `blockingSendAndReceive`

commit 76b3162aeab02afcd3f082aaa518381e12930c55
Author: Ismael Juma <is...@juma.me.uk>
Date:   2016-12-17T14:41:59Z

    Remove `resize` method from `FileRecords` and other minor tweaks

commit 627bee8ba1c4d69fabede41c3bedc89267676e3e
Author: Ismael Juma <is...@juma.me.uk>
Date:   2016-12-17T14:42:41Z

    Use `CompressionType` instead of `GZIPCompressionType` in `GroupCoordinatorIntegrationTest`

commit 94615423780f2053ca6adde6b3564d52113787ce
Author: Ismael Juma <is...@juma.me.uk>
Date:   2016-12-17T14:44:13Z

    Remove duplication and unnecessary verbosity in CRC computation

commit 5ea034d9ea49c4552965a7e2dbb860935535eb1c
Author: Ismael Juma <is...@juma.me.uk>
Date:   2016-12-17T14:44:29Z

    Remove unnecessary exceptions from catch block

commit 2adb37a1caea0edf2594588c3631cf9c8af040c1
Author: Ismael Juma <is...@juma.me.uk>
Date:   2016-12-17T14:46:19Z

    Minor improvements in `MultiSend` and `Send`

commit 9914f5242804412023ff312cc550cace16bedf96
Author: Ismael Juma <is...@juma.me.uk>
Date:   2016-12-17T14:47:07Z

    Comments and whitespace fixes

commit e93dc2aeb6607c7753934967d08261ecdf9beb74
Author: Ismael Juma <is...@juma.me.uk>
Date:   2016-12-17T14:47:28Z

    Remove unnecessary `toSeq`

commit 1a1c39e8efb3a500fc06808a9fc1572bf28a2806
Author: Ismael Juma <is...@juma.me.uk>
Date:   2016-12-17T14:48:03Z

    Replace named inner class by anonymous inner class in `LogCleaner`

commit 6674721d231ad4dea3e9d37ec991612f9a38db26
Author: Ismael Juma <is...@juma.me.uk>
Date:   2016-12-17T14:49:04Z

    Remove `FetchResponseSend`, `PartitionDataSend` and `TopicDataSend`

commit b61bd5e68d077c6c8f2ca4ce828a1d0c11e5f48f
Author: Ismael Juma <is...@juma.me.uk>
Date:   2016-12-17T14:52:27Z

    Make a few classes and fields final
    
    Because we have a few layers of indirection for the classes, we can
    help the JIT a little by declaring them final.

commit aa499e3716c32d40b16f92ddd03b4c0ec8494e64
Author: Ismael Juma <is...@juma.me.uk>
Date:   2016-12-17T14:53:08Z

    Fix typo, `masRecordSize` -> `maxRecordSize`

commit 3eda4f2b759f3696335add2a32651c4c4e814987
Author: Ismael Juma <is...@juma.me.uk>
Date:   2016-12-17T14:55:18Z

    Inline `addResponseData` to avoid unnecessary extra buffer allocation
    
    The memory overhead of a ByteBuffer is relatively large when the payload
    is 4 or 8 bytes. It\u2019s minor, but if we can avoid easily, why not?

commit 735466b9b335f0841fe708af68c1070b75d81d04
Author: Ismael Juma <is...@juma.me.uk>
Date:   2016-12-17T14:58:40Z

    Restore overflow checking code in `MemoryRecords.writeTo` and introduce static `filterTo` method
    
    By making `filterTo` static, it\u2019s clearer that it only needs the shallow entries from `MemoryRecords`.
    Because the method is a little long, it helps to limit the scope of what it can access.

----


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] kafka pull request #2271: MINOR: Improvements to Record related classes (par...

Posted by asfgit <gi...@git.apache.org>.
Github user asfgit closed the pull request at:

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


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---