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

Question: Access to message_queue management functions #450

Closed
truschival opened this issue Apr 10, 2018 · 3 comments
Closed

Question: Access to message_queue management functions #450

truschival opened this issue Apr 10, 2018 · 3 comments
Assignees
Labels

Comments

@truschival
Copy link

truschival commented Apr 10, 2018

  • OS and version used: Linux

  • SDK version used: 1.2

Description of the issue question:

Somewhat related to #427. When the connection is (temporarily) I would like to discard older messages or limit the lifetime of messages in the queue.
I have found functions in azureiot/message_queue.h that seem to offer what I am looking for. Unfortunately all functions require a MESSAGE_QUEUE_HANDLE* message_queue argument and I have no idea how I can obtain this handle after/during/between call of IoTHubClient_CreateFromConnectionString and IoTHubClient_SendEventAsync.

Is there any way to access the message_queue?
If not, could you please give me a pointer where to look for limiting the number of queued message and discarding old messages?

Thanks in advance.

@ewertons
Copy link
Contributor

Hi @truschival ,

message_queue is an internal component used in one of the modules within the Azure IoT C SDK.
As we evolve the code we eventually work on individual modules to refactor/advance the code. That's a continuous and independent process, and some modules might use new tools/libraries while others await for their time to enjoy improvements like message_queue.

We do not plan on exposing it though.

You can always limit the overall time a message stays on the queue by calling _SetOption and using option "telemetry_event_send_timeout_secs" (for AMQP; takes size_t* value). MQTT transport does not expose a way to control the maximum queue time.
None of the queues have size caps, so that is not configurable as well.

@ewertons ewertons self-assigned this Apr 10, 2018
@ewertons
Copy link
Contributor

@truschival ,
we will close this issue but please feel free to reopen it if you would like to follow up on the question.

Thank you for using the Azure IoT SDKs.
Please help us improve by filling out this 2-minute customer satisfaction survey

@tameraw
Copy link
Contributor

tameraw commented Apr 23, 2018

@truschival thank you for your contribution to our open-sourced project!  Please help us improve by filling out this 2-minute customer satisfaction survey.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants