Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[EventHub&ServiceBus] Improve the token refresh timing and update to uamqp 1.5.0 #22348

Merged
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions sdk/eventhub/azure-eventhub/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,9 @@ This version and all future versions will require Python 3.7+. Python 2.7 and 3.

### Other Changes

- Improved token refresh timing to prevent potentially blocking main flow when the token is about to get expired soon.
- Updated uAMQP dependency to 1.5.0.

## 5.6.1 (2021-10-06)

### Bugs Fixed
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -341,6 +341,7 @@ def _create_auth(self):
custom_endpoint_hostname=self._config.custom_endpoint_hostname,
port=self._config.connection_port,
verify=self._config.connection_verify,
refresh_window=300,
)

def _close_connection(self):
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -205,6 +205,7 @@ async def _create_auth_async(self) -> authentication.JWTTokenAsync:
custom_endpoint_hostname=self._config.custom_endpoint_hostname,
port=self._config.connection_port,
verify=self._config.connection_verify,
refresh_window=300,
)
await auth.update_token()
return auth
Expand Down
2 changes: 1 addition & 1 deletion sdk/eventhub/azure-eventhub/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,6 @@
packages=find_packages(exclude=exclude_packages),
install_requires=[
"azure-core<2.0.0,>=1.14.0",
"uamqp>=1.4.3,<2.0.0",
"uamqp>=1.5.0,<2.0.0",
]
)
3 changes: 3 additions & 0 deletions sdk/servicebus/azure-servicebus/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@

### Other Changes

- Improved token refresh timing to prevent potentially blocking main flow when the token is about to get expired soon.
- Updated uAMQP dependency to 1.5.0.

## 7.4.0 (2021-11-09)

### Features Added
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -184,6 +184,7 @@ def create_authentication(client):
timeout=client._config.auth_timeout,
http_proxy=client._config.http_proxy,
transport_type=client._config.transport_type,
refresh_window=300,
)


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@ async def create_authentication(client):
timeout=client._config.auth_timeout,
http_proxy=client._config.http_proxy,
transport_type=client._config.transport_type,
refresh_window=300,
)


Expand Down
2 changes: 1 addition & 1 deletion sdk/servicebus/azure-servicebus/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@
'azure',
]),
install_requires=[
"uamqp>=1.4.3,<2.0.0",
"uamqp>=1.5.0,<2.0.0",
'azure-common~=1.1',
'msrest>=0.6.17,<2.0.0',
'azure-core<2.0.0,>=1.14.0',
Expand Down
6 changes: 3 additions & 3 deletions shared_requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ msrest>=0.6.21
msrestazure<2.0.0,>=0.4.32
azure-mgmt-core<2.0.0,>=1.2.0
requests>=2.18.4
uamqp~=1.2.0
uamqp~=1.5.0
enum34>=1.0.4
certifi>=2017.4.17
aiohttp>=3.0
Expand Down Expand Up @@ -174,9 +174,9 @@ opentelemetry-sdk<2.0.0,>=1.5.0,!=1.10a0
#override azure-eventhub-checkpointstoreblob-aio azure-core<2.0.0,>=1.20.1
#override azure-eventhub-checkpointstoreblob-aio aiohttp<4.0,>=3.0
#override azure-eventhub-checkpointstoretable azure-core<2.0.0,>=1.14.0
#override azure-eventhub uamqp>=1.4.3,<2.0.0
#override azure-eventhub uamqp>=1.5.0,<2.0.0
#override azure-appconfiguration msrest>=0.6.10
#override azure-servicebus uamqp>=1.4.3,<2.0.0
#override azure-servicebus uamqp>=1.5.0,<2.0.0
#override azure-servicebus msrest>=0.6.17,<2.0.0
#override azure-servicebus azure-core<2.0.0,>=1.14.0
#override azure-synapse-accesscontrol azure-core>=1.20.0,<2.0.0
Expand Down