Commit Graph

3954 Commits

Author SHA1 Message Date
Guozhang Wang 91c207c2c6 MINOR: Make streams quick start more interactive
1. Make the WordCountDemo application to not stop automatically but via "ctrl-C".
2. Update the quickstart html file to let users type input messages one-by-one, and observe added output in an interactive manner.
3. Some minor fixes on the parent documentation page pointing to streams sub-pages, added a new recommended Scala version number.

Author: Guozhang Wang <wangguoz@gmail.com>

Reviewers: Michael G. Noll <michael@confluent.io>, Damian Guy <damian.guy@gmail.com>

Closes #3515 from guozhangwang/KMinor-interactive-quickstart
2017-07-25 11:34:16 -07:00
Matthias J. Sax 5d798511b1 KAFKA-3856 (KIP-120) step two: extract internal functions from public facing TopologyBuilder class
- extract InternalTopologyBuilder from TopologyBuilder
 - deprecate all "leaking" methods from public TopologyBuilder API
 - changed TopologyDescription and all nested classed into interfaces

Author: Matthias J. Sax <matthias@confluent.io>

Reviewers: Eno Thereska <eno.thereska@gmail.com>, Bill Bejeck <bbejeck@gmail.com>, Guozhang Wang <wangguoz@gmail.com>

Closes #3536 from mjsax/kafka-3856-extract-internal-topology-builder
2017-07-24 11:03:27 -07:00
Dong Lin fc93fb4b61 KAFKA-4763; Handle disk failure for JBOD (KIP-112)
Author: Dong Lin <lindong28@gmail.com>

Reviewers: Jiangjie Qin <becket.qin@gmail.com>, Jun Rao <junrao@gmail.com>, Ismael Juma <ismael@juma.me.uk>, Onur Karaman <okaraman@linkedin.com>

Closes #2929 from lindong28/KAFKA-4763
2017-07-22 12:35:32 -07:00
Ismael Juma 91b5fc737b MINOR: Give correct instructions for retaining previous unclear leader election behaviour
Author: Ismael Juma <ismael@juma.me.uk>

Reviewers: Rajini Sivaram <rajinisivaram@googlemail.com>

Closes #3561 from ijuma/fix-upgrade-note-for-unclean-leader-election
2017-07-22 10:36:12 +01:00
Ismael Juma 7727d7a9a5 MINOR: Improve log warning to include the log name
Author: Ismael Juma <ismael@juma.me.uk>

Reviewers: Rajini Sivaram <rajinisivaram@googlemail.com>

Closes #3562 from ijuma/tweak-log-warning
2017-07-22 10:35:02 +01:00
Ewen Cheslack-Postava c71e7fa3a3 MINOR: Don't imply that ConsumerGroupCommand won't work with non-Java clients
Author: Ewen Cheslack-Postava <me@ewencp.org>

Reviewers: Ismael Juma <ismael@juma.me.uk>

Closes #3564 from ewencp/minor-consumer-group-command-message
2017-07-21 19:36:43 -07:00
Derrick Or 300f48018c MINOR: Add Streams landing page
Content and assets for the updated Streams API landing page

Author: Derrick Or <derrickor@gmail.com>

Reviewers: Michael G. Noll <michael@confluent.io>, Guozhang Wang <wangguoz@gmail.com>

Closes #3540 from derrickdoo/streams-landing-page
2017-07-21 19:16:14 -07:00
ppatierno 6c6cf014f6 KAFKA-5481: ListOffsetResponse isn't logged in the right way with trace level enabled
Added toString() method to ListOffsetResponse for logging

Author: ppatierno <ppatierno@live.com>
Author: Paolo Patierno <ppatierno@live.com>

Reviewers: Ewen Cheslack-Postava <ewen@confluent.io>

Closes #3383 from ppatierno/kafka-5481
2017-07-21 16:55:38 -07:00
Hooman Broujerdi da42977a00 MINOR: Added safe deserialization implementation
Author: Hooman Broujerdi <hoomanb@hoomanb.usersys.redhat.com>

Reviewers: Randall Hauch <rhauch@gmail.com>, Ewen Cheslack-Postava <ewen@confluent.io>

Closes #3563 from rhauch/deserialization-validation
2017-07-21 16:02:36 -07:00
Stephane Roset 4a7064d1ae KAFKA-5512; Awake the heartbeat thread when timetoNextHeartbeat is equal to 0
Author: Stephane Roset <stephane@roset.me>

Reviewers: Ismael Juma <ismael@juma.me.uk>, Jason Gustafson <jason@confluent.io>

Closes #3442 from rosets/KAFKA-5512
2017-07-21 08:47:54 -07:00
Ismael Juma 08b775c322 KAFKA-5608; Follow-up to fix potential NPE and clarify method name
Author: Ismael Juma <ismael@juma.me.uk>

Reviewers: Ewen Cheslack-Postava <me@ewencp.org>

Closes #3553 from ijuma/kafka-5608-follow-up
2017-07-21 13:42:52 +01:00
Damian Guy 1110f66fa7 KAFKA-3741; allow users to specify default topic configs for internal topics
Allow users to specify default topic configs for streams internal topics by supplying properties from `TopicConfig` with a prefix.
Supplied defaults are used when creating the internal topics. They are overridden by the configs supplied along with the `InternalTopicConfig`

Author: Damian Guy <damian.guy@gmail.com>

Reviewers: Matthias J. Sax <matthias@confluent.io>, Guozhang Wang <wangguoz@gmail.com>

Closes #3459 from dguy/kafka-3741
2017-07-21 12:15:40 +01:00
Vahid Hashemian beb0ad9bbb MINOR: Make Kafka Connect step in quickstart more Windows friendly
Author: Vahid Hashemian <vahidhashemian@us.ibm.com>

Reviewers: Ewen Cheslack-Postava <ewen@confluent.io>

Closes #2498 from vahidhashemian/doc/connect_quickstart_update
2017-07-20 22:06:46 -07:00
Stephane Maarek ad6c53d89e KAFKA-5468: WorkerSourceTask offset commit loglevel changes
changed log level for source connector worker task when committing offsets

Author: Stephane Maarek <stephane@simplemachines.com.au>

Reviewers: Ewen Cheslack-Postava <ewen@confluent.io>

Closes #3367 from simplesteph/KAFKA-5468
2017-07-20 21:55:50 -07:00
huxihx cd207dd3fe KAFKA-5431; cleanSegments should not set length for cleanable segment files
For a compacted topic with preallocate enabled, during log cleaning, LogCleaner.cleanSegments does not have to pre-allocate the underlying file size since we only want to store the cleaned data in the file.

It's believed that this fix should also solve KAFKA-5582.

Author: huxihx <huxi_2b@hotmail.com>

Reviewers: Jun Rao <junrao@gmail.com>

Closes #3525 from huxihx/log_compact_test
2017-07-20 21:49:27 -07:00
ppatierno 1d2d0bac9e MINOR: Fixed misleading reference to HTTPS instead of SSL support in the doc
Author: ppatierno <ppatierno@live.com>

Reviewers: Ewen Cheslack-Postava <ewen@confluent.io>

Closes #3487 from ppatierno/ssl-doc-https
2017-07-20 20:16:15 -07:00
ppatierno 8a81566214 KAFKA-5410; Fix taskClass() method name in Connector and flush() signature in SinkTask
Author: ppatierno <ppatierno@live.com>

Reviewers: Ewen Cheslack-Postava <ewen@confluent.io>

Closes #3269 from ppatierno/connect-doc
2017-07-20 19:51:09 -07:00
Colin P. Mccabe 9ae09e8059 KAFKA-5623: ducktape kafka service: do not assume Service contains num_nodes
…m_nodes

Author: Colin P. Mccabe <cmccabe@confluent.io>

Reviewers: Ewen Cheslack-Postava <ewen@confluent.io>

Closes #3557 from cmccabe/KAFKA-5623
2017-07-20 19:34:16 -07:00
Vahid Hashemian 5bb53e034e KAFKA-5534; KafkaConsumer `offsetForTimes` result should include partitions with no offset
For topics that support timestamp search, if no offset is found for a partition, the partition should still be included in the result with a `null` offset value. This `KafkaConsumer` method currently excludes such partitions from the result.

Author: Vahid Hashemian <vahidhashemian@us.ibm.com>

Reviewers: Ismael Juma <ismael@juma.me.uk>, Jason Gustafson <jason@confluent.io>

Closes #3460 from vahidhashemian/KAFKA-5534
2017-07-20 17:38:30 -07:00
Apurva Mehta cdff011fe0 KAFKA-5610; WriteTxnMarker handler should return UNKNOWN_TOPIC_OR_PARTITION if replica is not available
Before this patch, we would instead return the non-retriable `UNSUPPORTED_FOR_MESSAGE_FORMAT` causing markers to be lost.

Author: Apurva Mehta <apurva@confluent.io>

Reviewers: Ismael Juma <ismael@juma.me.uk>, Jason Gustafson <jason@confluent.io>

Closes #3550 from apurvam/KAFKA-5610-handleWriteTxnMarker-should-handle-emigration
2017-07-20 13:05:51 -07:00
Ewen Cheslack-Postava 9b7a6ee2a9 MINOR: Apply extra serialized rsync step to both parallel and serial paths
Author: Ewen Cheslack-Postava <ewen@confluent.io>

Reviewers: Ismael Juma <ismael@juma.me.uk>, Eno Thereska <eno.thereska@gmail.com>

Closes #3546 from ewencp/fix-rsync
2017-07-20 10:49:06 -07:00
Matthias J. Sax b04bed022a KAFKA-3856; Cleanup Kafka Stream builder API (KIP-120)
Author: Matthias J. Sax <matthias@confluent.io>

Reviewers: Damian Guy <damian.guy@gmail.com>, Bill Bejeck <bbejeck@gmail.com>

Closes #2301 from mjsax/kafka-3856-topology-builder-API
2017-07-20 18:47:47 +01:00
umesh chaudhary e0099e1f58 KAFKA-5556; Fix IllegalStateException in KafkaConsumer.commitSync due to missing future completion check
This PR makes `commitOffsetsSync` method check whether future is completed after client's poll or not.

Author: umesh chaudhary <umesh9794@gmail.com>

Reviewers: Ismael Juma <ismael@juma.me.uk>, Jason Gustafson <jason@confluent.io>

Closes #3489 from umesh9794/KAFKA-5556
2017-07-20 08:54:25 -07:00
jameschien fe4a469fce KAFKA-4830; Augment KStream.print() to allow users pass in extra parameters in the printed string
I extend `KStream#print()` to `KStream#print(KeyValueMapper<K, V, String>)`.
So I add the following methods :
1. `KStream#print(KeyValueMapper<K, V, String>)`
2. `KStream#print(KeyValueMapper<K, V, String>, String streamName)`
3. `KStream#print(KeyValueMapper<K, V, String>, Serde<K>, Serde<V>)`
4. `KStream#print(KeyValueMapper<K, V, String>, Serde<K>, Serde<V>, String streamName)`

Author: jameschien <jameschien@staff.ruten.com.tw>
Author: jedichien <james.chain1990@gmail.com>
Author: JamesChien <jedichien@users.noreply.github.com>
Author: JamesChien <james.chain1990@gmail.com>

Reviewers: Bill Bejeck <bbejec@gmail.com>, Damian Guy <damian.guy@gmail.com>, Guozhang Wang <wangguoz@gmail.com>

Closes #3085 from jedichien/KAFKA-4830
2017-07-20 14:47:38 +01:00
Ismael Juma 84d2b6a01c MINOR: Simplify SensorAccess usage
I was investigating an exception in this code and found a few
opportunities for making it clearer.

I also added the `out` folder to `.gitignore` as IntelliJ sometimes
uses that as the build folder.

Author: Ismael Juma <ismael@juma.me.uk>

Reviewers: Rajini Sivaram <rajinisivaram@googlemail.com>

Closes #3552 from ijuma/minor-quota-improvements
2017-07-20 14:01:11 +01:00
Balint Molnar 272956f03a KAFKA-5134; Replace zkClient.getChildren method with zkUtils.getChildren
Author: Balint Molnar <balintmolnar91@gmail.com>

Reviewers: Ismael Juma <ismael@juma.me.uk>

Closes #3097 from baluchicken/KAFKA-5134-2
2017-07-20 12:48:17 +01:00
Jeff Klukas 0816e47bfe MINOR: Docs update, Java clients use Kafka Metrics
This contribution is my original work and I license the work to the project under the project's open source license.

Author: Jeff Klukas <jeff@klukas.net>

Reviewers: Ismael Juma <ismael@juma.me.uk>

Closes #3249 from jklukas/docs-no-more-yammer-metrics-in-client
2017-07-20 12:31:17 +01:00
Paolo Patierno 1b8aed6dc5 MINOR: Implement ConfigEntry.toString()
Author: Paolo Patierno <ppatierno@live.com>

Reviewers: Manikumar Reddy <manikumar.reddy@gmail.com>, Ismael Juma <ismael@juma.me.uk>

Closes #3551 from ppatierno/admin_config_entry
2017-07-20 11:30:50 +01:00
Jeff Widman 43aa14f2dc MINOR: Clarify wording in server.properties comment
Author: Jeff Widman <jeff@jeffwidman.com>

Reviewers: Ismael Juma <ismael@juma.me.uk>

Closes #2851 from jeffwidman/patch-3
2017-07-20 10:18:45 +01:00
Ewen Cheslack-Postava f50af9c31d KAFKA-5608: Add --wait option for JmxTool and use in system tests to avoid race between JmxTool and monitored services
Author: Ewen Cheslack-Postava <me@ewencp.org>
Author: Ewen Cheslack-Postava <ewen@confluent.io>

Reviewers: Ismael Juma <ismael@juma.me.uk>, Jason Gustafson <jason@confluent.io>

Closes #3547 from ewencp/wait-jmx-metrics
2017-07-19 21:39:51 -07:00
Vahid Hashemian f87d58b796 MINOR: Code Cleanup
Clean up includes:

- Switching try-catch-finally blocks to try-with-resources when possible
- Removing some seemingly unnecessary `SuppressWarnings` annotations
- Resolving some Java warnings
- Closing unclosed Closable objects
- Removing unused code

Author: Vahid Hashemian <vahidhashemian@us.ibm.com>

Reviewers: Balint Molnar <balintmolnar91@gmail.com>, Guozhang Wang <wangguoz@gmail.com>, Matthias J. Sax <matthias@confluent.io>, Ismael Juma <ismael@juma.me.uk>, Jason Gustafson <jason@confluent.io>

Closes #3222 from vahidhashemian/minor/code_cleanup_1706
2017-07-19 10:51:28 -07:00
Vahid Hashemian 3bfc073f03 MINOR: Make 'Topic-Level Configs' a doc section for easier access
Author: Vahid Hashemian <vahidhashemian@us.ibm.com>

Reviewers: Ismael Juma <ismael@juma.me.uk>

Closes #3415 from vahidhashemian/doc/make_topic_config_a_section
2017-07-19 14:25:02 +01:00
Ewen Cheslack-Postava fc0ea25025 MINOR: Add another common error case for CorruptRecordException's error message
Author: Ewen Cheslack-Postava <me@ewencp.org>

Reviewers: Ismael Juma <ismael@juma.me.uk>

Closes #3541 from ewencp/corrupt-record-null-key-compacted-topic
2017-07-18 13:00:46 -07:00
Gwen Shapira ea8845bbd6 KAFKA-5384: Enable topic deletion by default
https://cwiki.apache.org/confluence/display/KAFKA/KIP-162+-+Enable+topic+deletion+by+default

Author: Gwen Shapira <cshapi@gmail.com>

Reviewers: Ismael Juma

Closes #3241 from gwenshap/KAFKA-5384
2017-07-18 08:57:06 -07:00
Kamal C bbc3900185 MINOR: Use static imports in KafkaLog4jAppender
Instead of redefining the constants.

Author: Kamal C <kamal.chandraprakash@gmail.com>

Reviewers: Ismael Juma <ismael@juma.me.uk>

Closes #3349 from Kamal15/log4j2
2017-07-18 16:50:29 +01:00
Ismael Juma 454f0f1ca1 MINOR: Remove flaky assertion in verifyCloseOldestConnectionWithStagedReceives
This seems to fail a lot in Jenkins although it always passes locally
for me. Removing the assertion to restore Jenkins stability while
we investigate in more detail.

Author: Ismael Juma <ismael@juma.me.uk>

Reviewers: Damian Guy <damian.guy@gmail.com>, Rajini Sivaram <rajinisivaram@googlemail.com>

Closes #3543 from ijuma/remove-selector-test-assertion
2017-07-18 09:52:24 +01:00
Ewen Cheslack-Postava d663005fdd MINOR: Do not wait for first line of console consumer output since we now have a more reliable test using JMX
Waiting for the first line of output was added in KAFKA-2527 when JmxMixin was originally added as a heuristic to
determine when the process was ready. We've since determined this is not good enough given JmxTool's limitations
and now include a separate, more reliable check before starting JmxTool. This check is also dangerous since a
consumer that is started before data is available in the topic, it won't output anything to stdout and only logs
errors to a separate log file. This means we may have a long delay between starting the process and starting JMX
monitoring.

Since we have a more reliable check for liveness via JMX now (and in cases that need it, partition assignment
metrics via JMX), we should no longer need to wait for the first line of output.

Author: Ewen Cheslack-Postava <me@ewencp.org>

Reviewers: Ismael Juma <ismael@juma.me.uk>, Apurva Mehta <apurva@confluent.io>

Closes #3447 from ewencp/dont-wait-first-line-console-consumer
2017-07-17 21:24:45 -07:00
Rajini Sivaram 28c83d9667 KAFKA-5587; Remove channel only after staged receives are delivered
When idle connections are closed, ensure that channels with staged
receives are retained in `closingChannels` until all staged receives
are completed. Also ensure that only one staged receive is completed
in each poll, even when channels are closed.

Author: Rajini Sivaram <rajinisivaram@googlemail.com>

Reviewers: Jun Rao <junrao@gmail.com>, Ismael Juma <ismael@juma.me.uk>

Closes #3526 from rajinisivaram/KAFKA-5587
2017-07-17 23:58:22 +01:00
Jan Burkhardt e2fe19d22a KAFKA-5600; Fix group loading regression causing stale metadata/offset cache
the while loop was too big and need to be closed earlier
to see the fix, ignore whitespace since most of it is indentation

this bug was introduced by commit
5bd06f1d54

Author: Jan Burkhardt <jan.burkhardt@just.social>

Reviewers: Ismael Juma <ismael@juma.me.uk>, Jason Gustafson <jason@confluent.io>

Closes #3538 from bjrke/trunk
2017-07-17 11:51:57 -07:00
Jeremy Custenborder 6d7a81b478 KAFKA-5579: check for null
Author: Jeremy Custenborder <jcustenborder@gmail.com>

Reviewers: Randall Hauch <rhauch@gmail.com>, Ewen Cheslack-Postava <ewen@confluent.io>

Closes #3517 from jcustenborder/KAFKA-5579
2017-07-17 10:45:31 -07:00
Rajini Sivaram cf94b188f1 MINOR: Use correct connectionId in SocketServer log message
Also add connection id to KafkaChannel exception message

Author: Rajini Sivaram <rajinisivaram@googlemail.com>

Reviewers: Jason Gustafson <jason@confluent.io>, Ismael Juma <ismael@juma.me.uk>

Closes #3529 from rajinisivaram/MINOR-log-connection-id
2017-07-17 09:41:29 +01:00
Xianyang Liu d0ce0a95de MINOR: Correct the ConsumerPerformance print format
Currently, the output of `ConsumerPerformance` looks strange. The `header` format as follow:
```
"time, threadId, data.consumed.in.MB, MB.sec, data.consumed.in.nMsg, nMsg.sec"
```
while the `body` as follow:
```
println("%s, %d, %.4f, %.4f, %d, %.4f".format(dateFormat.format(endMs), id, totalMBRead,
        1000.0 * (mbRead / elapsedMs), messagesRead, ((messagesRead - lastMessagesRead) / elapsedMs) * 1000.0))
```

So we get the follow result:
```
time, data.consumeed.in.MB, MB.sec, data.consumeed.in.nMsg, nMsg.Sec
09:52:00, 0, 1100.3086, 220.0177, 563358, 112649.0702
```
So the `header` and `body` mismatching.

And also, this pr makes the functions more readable.

Author: Xianyang Liu <xianyang.liu@intel.com>

Reviewers: Ismael Juma <ismael@juma.me.uk>

Closes #3417 from ConeyLiu/consumertest
2017-07-14 13:50:38 -07:00
Guozhang Wang 873eeae9f7 MINOR: Change log level for group member failure from debug to info
Author: Guozhang Wang <wangguoz@gmail.com>

Reviewers: Jason Gustafson <jason@confluent.io>

Closes #3523 from guozhangwang/KMinor-group-coordinator-member-failure-info-log4j
2017-07-14 13:32:32 -07:00
Ismael Juma 1685e7112c MINOR: Enable a number of xlint scalac warnings
Update the code where possible to fix the warnings. The unused
warning introduced in Scala 2.12 is quite handy and provides
a reason to compile with Scala 2.12.

Author: Ismael Juma <ismael@juma.me.uk>

Reviewers: Jason Gustafson <jason@confluent.io>

Closes #3464 from ijuma/scala-xlint
2017-07-14 11:44:42 -07:00
Balint Molnar e391045473 KAFKA-5127; Replace pattern matching with foreach where the case None is ignored
Author: Balint Molnar <balintmolnar91@gmail.com>

Reviewers: Vahid Hashemian <vahidhashemian@us.ibm.com>, Ismael Juma <ismael@juma.me.uk>, Jason Gustafson <jason@confluent.io>

Closes #2919 from baluchicken/KAFKA-5127
2017-07-14 09:57:14 -07:00
Gregor Uhlenheuer 2d2e9adb5d KAFKA-5584; Fix integer overflow in Log.size
It may lead to wrong metrics and it may break
size-based retention.

Author: Gregor Uhlenheuer <kongo2002@googlemail.com>

Reviewers: Ismael Juma <ismael@juma.me.uk>

Closes #3521 from kongo2002/KAFKA-5584
2017-07-12 17:20:19 -07:00
Evgeny Veretennikov 0547a08254 MINOR: typo in variable name "unkownInfo"
Author: Evgeny Veretennikov <evg.veretennikov@gmail.com>

Reviewers: Apurva Mehta <apurva@confluent.io>, Ismael Juma <ismael@juma.me.uk>

Closes #3433 from evis/unkown_info_typo
2017-07-12 16:24:58 -07:00
Kamal C ef27515943 MINOR: Typo error corrected in the KStream Javadoc.
Author: Kamal C <kamal.chandraprakash@gmail.com>

Reviewers: Matthias J. Sax <matthias@confluent.io>, Damian Guy <damian.guy@gmail.com>

Closes #3520 from Kamal15/stream_doc
2017-07-12 13:17:21 -07:00
Joel Dice 8068a3560b MINOR: consume from outputTopic in EosIntegrationTest.runSimpleCopyTest
Previously, the code mistakenly consumed from inputTopic, which
worked, but didn't actually verify that the messages were correctly
copied from inputTopic to outputTopic.

Author: Joel Dice <jdice@mersive.com>

Reviewers: Matthias J. Sax <matthias@confluent.io>, Damian Guy <damian.guy@gmail.com>

Closes #3522 from dicej/trunk
2017-07-12 13:06:45 -07:00
Eno Thereska 4416739915 MINOR: Upgraded RocksDB to 5.3.6
Solves a problem as described here: https://groups.google.com/forum/#!topic/confluent-platform/cR02K2o6BIw

Author: Eno Thereska <eno.thereska@gmail.com>

Reviewers: Damian Guy <damian.guy@gmail.com>

Closes #3472 from enothereska/minor-upgrade-rocksdb-5.1.2
2017-07-11 12:03:51 -07:00