-
Notifications
You must be signed in to change notification settings - Fork 54
New release #39
New release #39
Conversation
azure/eventhub/client.py
Outdated
| Run the EventHubClient in blocking mode. | ||
| Opens the connection and starts running all Sender/Receiver clients. | ||
|
|
||
| :rtype: ~azure.eventhub.client.EventHubClient |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Missing correct docstring
| :param epoch: The epoch value for the receiver. | ||
| :type epoch: int | ||
| :param prefetch: The message prefetch count of the receiver. Default is 300. | ||
| :type prefetch: int |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Need to add operation to docstring
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
azure/eventhub/common.py
Outdated
| self._partition_key = types.AMQPSymbol(EventData.PROP_PARTITION_KEY) | ||
| self._annotations = {} | ||
| self._properties = {} | ||
| self._msg_properties = MessageProperties() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
make properties public?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
azure/eventhub/common.py
Outdated
| elif message: | ||
| self.message = message | ||
| self._annotations = message.annotations | ||
| self._properties = message.application_properties |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Get message properties
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
| output['partition_ids'] = [p.decode('utf-8') for p in eh_info[b'partition_ids']] | ||
| return output | ||
|
|
||
| def add_async_receiver(self, consumer_group, partition, offset=None, prefetch=300, operation=None, loop=None): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
rename to remove async
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe next release
| self.close(exception=error) | ||
| raise error | ||
|
|
||
| def selector(self, default): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we need this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Leave for now
| msg_timeout=Sender.TIMEOUT) | ||
| self._handler.open(connection) | ||
|
|
||
| def get_handler_state(self): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Needs docstring
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
| msg_timeout=Sender.TIMEOUT) | ||
| await self._handler.open_async(connection=connection) | ||
|
|
||
| async def has_started(self): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Needs docstring
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
| event_data.message.on_send_complete = lambda o, c: callback(o, Sender._error(o, c)) | ||
| self._handler.queue_message(event_data.message) | ||
|
|
||
| def wait(self): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Need async wait
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
No description provided.