sarama

Sarama is a Go library for Apache Kafka.

MIT License

Stars
11K
Committers
291

Bot releases are visible (Hide)

sarama - Version 1.24.0 (2019-10-09)

Published by bai about 5 years ago

New Features:

  • Add sticky partition assignor (1416).
  • Switch from cgo zstd package to pure Go implementation (1477).

Improvements:

  • Allow creating ClusterAdmin from client (1415).
  • Set KafkaVersion in ListAcls method (1452).
  • Set request version in CreateACL ClusterAdmin method (1458).
  • Set request version in DeleteACL ClusterAdmin method (1461).
  • Handle missed error codes on TopicMetaDataRequest and GroupCoordinatorRequest (1464).
  • Remove direct usage of gofork (1465).
  • Add support for Go 1.13 (1478).
  • Improve behavior of NewMockListAclsResponse (1481).

Bug Fixes:

  • Fix race condition in consumergroup example (1434).
  • Fix brokerProducer goroutine leak (1442).
  • Use released version of lz4 library (1469).
  • Set correct version in MockDeleteTopicsResponse (1484).
  • Fix CLI help message typo (1494).

Known Issues:

sarama - Version 1.23.1 (2019-07-22)

Published by d1egoaz about 5 years ago

Bug Fixes:

  • Fix fetch delete bug record (1425).
  • Handle SASL/OAUTHBEARER token rejection (1428).
sarama - Version 1.23.0 (2019-07-02)

Published by bai over 5 years ago

New Features:

  • Add support for Kafka 2.3.0 (1418).
  • Add support for ListConsumerGroupOffsets v2 (1374).
  • Add support for DeleteConsumerGroup (1417).
  • Add support for SASLVersion configuration (1410).
  • Add kerberos support (1366).

Improvements:

  • Improve sasl_scram_client example (1406).
  • Fix shutdown and race-condition in consumer-group example (1404).
  • Add support for error codes 77—81 (1397).
  • Pool internal objects allocated per message (1385).
  • Reduce packet decoder allocations (1373).
  • Support timeout when fetching metadata (1359).

Bug Fixes:

  • Fix fetch size integer overflow (1376).
  • Handle and log throttled FetchResponses (1383).
  • Refactor misspelled word Resouce to Resource (1368).
sarama - Version 1.22.1 (2019-04-29)

Published by bai over 5 years ago

Improvements:

  • Use zstd 1.3.8 (1350).
  • Add support for SaslHandshakeRequest v1 (1354).

Bug Fixes:

  • Fix V5 MetadataRequest nullable topics array (1353).
  • Use a different SCRAM client for each broker connection (1349).
  • Fix AllowAutoTopicCreation for MetadataRequest greater than v3 (1344).
sarama - Version 1.22.0 (2019-04-09)

Published by bai over 5 years ago

New Features:

  • Add Offline Replicas Operation to Client (1318).
  • Allow using proxy when connecting to broker (1326).
  • Implement ReadCommitted (1307).
  • Add support for Kafka 2.2.0 (1331).
  • Add SASL SCRAM-SHA-512 and SCRAM-SHA-256 mechanismes (1331).

Improvements:

  • Unregister all broker metrics on broker stop (1232).
  • Add SCRAM authentication example (1303).
  • Add consumergroup examples (1304).
  • Expose consumer batch size metric (1296).
  • Add TLS options to console producer and consumer (1300).
  • Reduce client close bookkeeping (1297).
  • Satisfy error interface in create responses (1154).
  • Please lint gods (1346).

Bug Fixes:

  • Fix multi consumer group instance crash (1338).
  • Update lz4 to latest version (1347).
  • Retry ErrNotCoordinatorForConsumer in new consumergroup session (1231).
  • Fix cleanup error handler (1332).
  • Fix rate condition in PartitionConsumer (1156).
sarama - Version 1.21.0 (2019-02-24)

Published by bai over 5 years ago

New Features:

  • Add CreateAclRequest, DescribeAclRequest, DeleteAclRequest (#1236).
  • Add DescribeTopic, DescribeConsumerGroup, ListConsumerGroups, ListConsumerGroupOffsets admin requests (#1178).
  • Implement SASL/OAUTHBEARER (#1240).

Improvements:

  • Add Go mod support (#1282).
  • Add error codes 73—76 (#1239).
  • Add retry backoff function (#1160).
  • Maintain metadata in the producer even when retries are disabled (#1189).
  • Include ReplicaAssignment in ListTopics (#1274).
  • Add producer performance tool (#1222).
  • Add support LogAppend timestamps (#1258).

Bug Fixes:

  • Fix potential deadlock when a heartbeat request fails (#1286).
  • Fix consuming compacted topic (#1227).
  • Set correct Kafka version for DescribeConfigsRequest v1 (#1277).
  • Update kafka test version (#1273).
sarama - Version 1.20.1 (2019-01-10)

Published by vvuibert almost 6 years ago

New Features:

  • Add optional replica id in offset request (1100).

Improvements:

  • Implement DescribeConfigs Request + Response v1 & v2 (1230).
  • Reuse compression objects (1185).
  • Switch from png to svg for GoDoc link in README (1243).
  • Fix typo in deprecation notice for FetchResponseBlock.Records (1242).
  • Fix typos in consumer metadata response file (1244).

Bug Fixes:

  • Revert to individual msg retries for non-idempotent (1203).
  • Respect MaxMessageBytes limit for uncompressed messages (1141).
sarama - Version 1.20.0 (2018-12-10)

Published by bai almost 6 years ago

New Features:

  • Add support for zstd compression (#1170).
  • Add support for Idempotent Producer (#1152).
  • Add support support for Kafka 2.1.0 (#1229).
  • Add support support for OffsetCommit request/response pairs versions v1 to v5 (#1201).
  • Add support support for OffsetFetch request/response pair up to version v5 (#1198).

Improvements:

  • Export broker's Rack setting (#1173).
  • Always use latest patch version of Go on CI (#1202).
  • Add error codes 61 to 72 (#1195).

Bug Fixes:

  • Fix build without cgo (#1182).
  • Fix go vet suggestion in consumer group file (#1209).
  • Fix typos in code and comments (#1228).
sarama - Version 1.19.0 (2018-09-27)

Published by bai about 6 years ago

New Features:

  • Implement a higher-level consumer group (#1099).

Improvements:

  • Add support for Go 1.11 (#1176).

Bug Fixes:

  • Fix encoding of MetadataResponse with version 2 and higher (#1174).
  • Fix race condition in mock async producer (#1174).
sarama - Version 1.18.0 (2018-09-07)

Published by bai about 6 years ago

New Features:

  • Make Partitioner.RequiresConsistency vary per-message (#1112).
  • Add customizable partitioner (#1118).
  • Add ClusterAdmin support for CreateTopic, DeleteTopic, CreatePartitions, DeleteRecords, DescribeConfig, AlterConfig, CreateACL, ListAcls, DeleteACL (#1055).

Improvements:

  • Add support for Kafka 2.0.0 (#1149).
  • Allow setting LocalAddr when dialing an address to support multi-homed hosts (#1123).
  • Simpler offset management (#1127).

Bug Fixes:

  • Fix mutation of ProducerMessage.MetaData when producing to Kafka (#1110).
  • Fix consumer block when response did not contain all the expected topic/partition blocks (#1086).
  • Fix consumer block when response contains only constrol messages (#1115).
  • Add timeout config for ClusterAdmin requests (#1142).
  • Add version check when producing message with headers (#1117).
  • Fix MetadataRequest for empty list of topics (#1132).
  • Fix producer topic metadata on-demand fetch when topic error happens in metadata response (#1125).
sarama - Version 1.17.0 (2018-05-30)

Published by bai over 6 years ago

New Features:

  • Add support for gzip compression levels (#1044).
  • Add support for Metadata request/response pairs versions v1 to v5 (#1047, #1069).
  • Add versioning to JoinGroup request/response pairs (#1098).
  • Add support for CreatePartitions, DeleteGroups, DeleteRecords request/response pairs (#1065, #1096, #1027).
  • Add Controller() method to Client interface (#1063).

Improvements:

  • ConsumerMetadataReq/Resp has been migrated to FindCoordinatorReq/Resp (#1010).
  • Expose missing protocol parts: msgSet and recordBatch (#1049).
  • Add support for v1 DeleteTopics Request (#1052).
  • Add support for Go 1.10 (#1064).
  • Claim support for Kafka 1.1.0 (#1073).

Bug Fixes:

  • Fix FindCoordinatorResponse.encode to allow nil Coordinator (#1050, #1051).
  • Clear all metadata when we have the latest topic info (#1033).
  • Make PartitionConsumer.Close idempotent (#1092).
sarama - Version 1.16.0 (2018-02-12)

Published by eapache over 6 years ago

New Features:

  • Add support for the Create/Delete Topics request/response pairs (#1007, #1008).
  • Add support for the Describe/Create/Delete ACL request/response pairs (#1009).
  • Add support for the five transaction-related request/response pairs (#1016).

Improvements:

  • Permit setting version on mock producer responses (#999).
  • Add NewMockBrokerListener helper for testing TLS connections (#1019).
  • Changed the default value for Consumer.Fetch.Default from 32KiB to 1MiB which results in much higher throughput in most cases (#1024).
  • Reuse the time.Ticker across fetch requests in the PartitionConsumer to reduce CPU and memory usage when processing many partitions (#1028).
  • Assign relative offsets to messages in the producer to save the brokers a recompression pass (#1002, #1015).

Bug Fixes:

  • Fix producing uncompressed batches with the new protocol format (#1032).
  • Fix consuming compacted topics with the new protocol format (#1005).
  • Fix consuming topics with a mix of protocol formats (#1021).
  • Fix consuming when the broker includes multiple batches in a single response (#1022).
  • Fix detection of PartialTrailingMessage when the partial message was truncated before the magic value indicating its version (#1030).
  • Fix expectation-checking in the mock of SyncProducer.SendMessages (#1035).
sarama - Version 1.15.0 (2017-12-08)

Published by eapache almost 7 years ago

New Features:

  • Claim official support for Kafka 1.0, though it did already work (#984).
  • Helper methods for Kafka version numbers to/from strings (#989).
  • Implement CreatePartitions request/response (#985).

Improvements:

  • Add error codes 45-60 (#986).

Bug Fixes:

  • Fix slow consuming for certain Kafka 0.11/1.0 configurations (#982).
  • Correctly determine when a FetchResponse contains the new message format (#990).
  • Fix producing with multiple headers (#996).
  • Fix handling of truncated record batches (#998).
  • Fix leaking metrics when closing brokers (#991).
sarama - Version 1.14.0 (2017-11-13)

Published by eapache almost 7 years ago

New Features:

  • Add support for the new Kafka 0.11 record-batch format, including the wire protocol and the necessary behavioural changes in the producer and consumer. Transactions and idempotency are not yet supported, but producing and consuming should work with all the existing bells and whistles (batching, compression, etc) as well as the new custom headers. Thanks to Vlad Hanciuta of Arista Networks for this work. Part of (#901).

Bug Fixes:

  • Fix encoding of ProduceResponse versions in test (#970).
  • Return partial replicas list when we have it (#975).
sarama - Version 1.13.0 (2017-10-04)

Published by eapache about 7 years ago

New Features:

  • Support for FetchRequest version 3 (#905).
  • Permit setting version on mock FetchResponses (#939).
  • Add a configuration option to support storing only minimal metadata for extremely large clusters (#937).
  • Add PartitionOffsetManager.ResetOffset for backtracking tracked offsets (#932).

Improvements:

  • Provide the block-level timestamp when consuming compressed messages (#885).
  • Client.Replicas and Client.InSyncReplicas now respect the order returned by the broker, which can be meaningful (#930).
  • Use a Ticker to reduce consumer timer overhead at the cost of higher variance in the actual timeout (#933).

Bug Fixes:

  • Gracefully handle messages with negative timestamps (#907).
  • Raise a proper error when encountering an unknown message version (#940).
sarama - Version 1.12.0 (2017-05-08)

Published by eapache over 7 years ago

New Features:

  • Added support for the ApiVersions request and response pair, and Kafka version 0.10.2 (#867). Note that you still need to specify the Kafka version in the Sarama configuration for the time being.
  • Added a Brokers method to the Client which returns the complete set of active brokers (#813).
  • Added an InSyncReplicas method to the Client which returns the set of all in-sync broker IDs for the given partition, now that the Kafka versions for which this was misleading are no longer in our supported set (#872).
  • Added a NewCustomHashPartitioner method which allows constructing a hash partitioner with a custom hash method in case the default (FNV-1a) is not suitable (#837, #841).

Improvements:

  • Recognize more Kafka error codes (#859).

Bug Fixes:

  • Fix an issue where decoding a malformed FetchRequest would not return the correct error (#818).
  • Respect ordering of group protocols in JoinGroupRequests. This fix is transparent if you're using the AddGroupProtocol or AddGroupProtocolMetadata helpers; otherwise you will need to switch from the GroupProtocols field (now deprecated) to use OrderedGroupProtocols (#812).
  • Fix an alignment-related issue with atomics on 32-bit architectures (#859).
sarama - Version 1.11.0 (2016-12-20)

Published by eapache almost 8 years ago

New Features:

  • Metrics! Thanks to Sébastien Launay for all his work on this feature
    (#701,
    #746,
    #766).
  • Add support for LZ4 compression
    (#786).
  • Add support for ListOffsetRequest v1 and Kafka 0.10.1
    (#775).
  • Added a HighWaterMarks method to the Consumer which aggregates the
    HighWaterMarkOffset values of its child topic/partitions
    (#769).

Bug Fixes:

  • Fixed producing when using timestamps, compression and Kafka 0.10
    (#759).
  • Added missing decoder methods to DescribeGroups response
    (#756).
  • Fix producer shutdown when Return.Errors is disabled
    (#787).
  • Don't mutate configuration in SyncProducer
    (#790).
  • Fix crash on SASL initialization failure
    (#795).
sarama - Version 1.10.1 (2016-08-30)

Published by eapache about 8 years ago

Bug Fixes:

  • Fix the documentation for HashPartitioner which was incorrect
    (#717).
  • Permit client creation even when it is limited by ACLs
    (#722).
  • Several fixes to the consumer timer optimization code, regressions introduced
    in v1.10.0. Go's timers are finicky
    (#730,
    #733,
    #734).
  • Handle consuming compressed relative offsets with Kafka 0.10
    (#735).
sarama - Version 1.10.0 (2016-08-02)

Published by eapache about 8 years ago

Important: As of Sarama 1.10 it is necessary to tell Sarama the version of
Kafka you are running against (via the config.Version value) in order to use
features that may not be compatible with old Kafka versions. If you don't
specify this value it will default to 0.8.2 (the minimum supported), and trying
to use more recent features (like the offset manager) will fail with an error.

Also: The offset-manager's behaviour has been changed to match the upstream
java consumer (see #705 and #713). If you use the offset-manager, please ensure
that you are committing one greater than the last consumed message offset or else
you may end up consuming duplicate messages.

New Features:

  • Support for Kafka 0.10
    (#672,
    #678,
    #681, and others).
  • Support for configuring the target Kafka version
    (#676).
  • Batch producing support in the SyncProducer
    (#677).
  • Extend producer mock to allow setting expectations on message contents
    (#667).

Improvements:

  • Support nil compressed messages for deleting in compacted topics
    (#634).
  • Pre-allocate decoding errors, greatly reducing heap usage and GC time against
    misbehaving brokers (#690).
  • Re-use consumer expiry timers, removing one allocation per consumed message
    (#707).

Bug Fixes:

  • Actually default the client ID to "sarama" like we say we do
    (#664).
  • Fix a rare issue where Client.Leader could return the wrong error
    (#685).
  • Fix a possible tight loop in the consumer
    (#693).
  • Match upstream's offset-tracking behaviour
    (#705).
  • Report UnknownTopicOrPartition errors from the offset manager
    (#706).
  • Fix possible negative partition value from the HashPartitioner
    (#709).
sarama - Version 1.9.0 (2016-05-16)

Published by eapache over 8 years ago

New Features:

  • Add support for custom offset manager retention durations
    (#602).
  • Publish low-level mocks to enable testing of third-party producer/consumer
    implementations (#570).
  • Declare support for Golang 1.6
    (#611).
  • Support for SASL plain-text auth
    (#648).

Improvements:

  • Simplified broker locking scheme slightly
    (#604).
  • Documentation cleanup
    (#605,
    #621,
    #654).

Bug Fixes:

  • Fix race condition shutting down the OffsetManager
    (#658).