github Azure/azure-sdk-for-python azure-eventhub_5.0.0b6

latest releases: azure-servicebus_7.13.0b1, azure-eventhub_5.13.0b1, azure-eventhub_5.12.0...
pre-release4 years ago

2019-12-03 5.0.0b6

Breaking changes

  • All exceptions should now be imported from azure.eventhub.exceptions.
  • Introduced separate EventHubSharedKeyCredential objects for synchronous and asynchronous operations.
    For async, import the credentials object from the azure.eventhub.aio namespace.
  • EventData
    • Renamed property application_properties to properties.
    • EventData no longer has attribute last_enqueued_event_properties - use this on PartitionContext instead.
  • EvenDataBatch
    • EventDataBatch.try_add has been renamed to EventDataBatch.add.
    • Renamed property size to size_in_bytes.
    • Renamed attribute max_size to max_size_in_bytes.
  • EventHubConsumerClient and EventHubProducerClient
    • Renamed method get_properties to get_eventhub_properties.
    • Renamed parameters in constructor: host to fully_qualified_namespace, event_hub_path to eventhub_name.
    • Renamed parameters in get_partition_properties: partition to partition_id.
    • Renamed parameter consumer_group_name to consumer_group and moved that parameter from receive method to the constructor of EventHubConsumerClient.
    • Renamed parameter initial_event_position to starting_position on the receive method of EventHubConsumerClient.
    • Renamed parameter event_hub_path to eventhub_name in constructor and from_connection_string method of the client object.
    • EventHubProducerClient.send has been renamed to send_batch which will only accept EventDataBatch object as input.
    • EventHubProducerClient.create_batch now also takes the partition_id and partition_key as optional parameters (which are no longer specified at send).
  • Renamed module PartitionManager to CheckpointStore.
  • Receive event callback parameter has been renamed to on_event and now operates on a single event rather than a list of events.
  • Removed class EventPostition.
    • The starting_position parameter of the receive method accepts offset(str), sequence number(int), datetime (datetime.datetime) or dict of these types.
    • The starting_position_inclusive parameter of the receive method accepts bool or dict indicating whether the given event position is inclusive or not.
  • PartitionContext no longer has attribute owner_id.
  • PartitionContext now has attribute last_enqueued_event_properties which is populated if track_last_enqueued_event_properties is set to True in the receive method.

** New features **

  • Added new parameter idle_timeout in construct and from_connection_string to EventHubConsumerClient and EventHubProducerClient
    after which the underlying connection will close if there is no further activity.

Don't miss a new azure-sdk-for-python release

NewReleases is sending notifications on new releases.