Azure / Azure/azure-iot-sdk-python
[Technical Question] IoTHubModuleClient method send_message takes lot of time
- Langage dominant
- Python
- Étoiles
- 438
- Forks
- 380
- Merge moyen
- 22 h 17 min
- PR mergées (30 j)
- 22
Description
Hi Team,
I am trying to use send_message method of the async IoTHubModuleClient class
```
# The client object is used to interact with your Azure IoT hub.
module_client = IoTHubModuleClient.create_from_edge_environment()
# Connect the client.
await module_client.connect()
async def send_test_message(i):
print("sending message #" + str(i))
msg = Message("test wind speed " + str(i))
msg.message_id = uuid.uuid4()
msg.correlation_id = "correlation-1234"
msg.custom_properties["tornado-warning"] = "yes"
await module_client.send_message(msg)
print("done sending message #" + str(i))
```
i tried measuring the time taken for **send_message** and it is around 300 milliseconds. Is there a way to reduce this time ?

Guide de contribution
Ouvrir le guide de contribution
Piste de recherche
Aucun fichier du dépôt ni aucun test n’est nommé ; commencez au point d’entrée async IoTHubModuleClient.send_message et comparez le timing autour de await. Une résolution utile établirait si les ~300 ms signalées sont attendues ou identifierait une modification reproductible qui les réduit.
Rédigé par le modèle d'indexation à partir du texte de l'issue.
Évaluation
- Stack technique
- azure, python
- Domaine
- embedded-iot, networking
- Type d'issue
- Bug
- Difficulté
- 4/5
- Temps estimé
- 3-5 jours
- Activité
- À l'abandon
- Clarté
- À clarifier
- Accessibilité débutants
- 20/100