Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [leshan-dev] Info Queue Mode Leshan server

Hello, I am newbie in this field. I understand that the Queue mode of Leshan server is not enabled by default,
can anyone explain precisely step by step how to activate and how to test the functionality of this operation mode?

Thks

2016-10-21 18:36 GMT+02:00 Simon Bernard <contact@xxxxxxxxxxxxxxx>:

Hi,

   Currently, the code about Queue Mode in Leshan is pretty experimental (and not activated by default). Moreover, there are recent changes about QueueMode in the LWM2M specification.

   To be honest with this last changes I have doubts about the way we started to implement this. We try to implement a message queue but I think we should go for a different approach. IMHO, Leshan should detect when a client is present or not and relay that to the application layer.

   If you really want to test Leshan with the current QueueMode Implementation, you could try to modify LeshanServerDemo and use QueueMode classes. (see  QueueModeLeshanServer)
   But this will not be straightforward :/
Simon


Le 21/10/2016 à 14:31, Jacopo Piani a écrit :
Hi,
I am a student at the University of Udine (Italy), for my degree in electronic engineering I'm working on a thesis on the protocols for low power sensor networks: CoAP, OMA LWM2M,...etc. In order to test my sensor network, I'm using the Eclipse Leshan public server (https://github.com/eclipse/leshan). My work scenario consists of two or more nodes connected to a Wi-Fi bridge that communicates with the public Leshan server. When the nodes (LWM2M clients) are registered with Binding Mode paratemer "U" (UDP), the system works perfectly. The nodes are registered correctly on the Leshan server (web page) and I can observe the different resources of the nodes without problems.



Now I would like to implement the Queue mode of LWM2M protocol. I read that the Leshan server also supports this feature (https://github.com/eclipse/leshan/pull/126). Reading the LWM2M protocol and how Leshan implements the Queue mode, I found some differencies.

With the Leshan implementation if the Leshan server by querying a client receives a request timeout, then it understands that the node is sleeping and puts the packages in a queue, when the client makes the registration update, then the queue is emptied.

Instead according to the LWM2M protocol Queue mode a node must wait a precise time interval (seconds) from the last CoAP message it sent to the LWM2M Server before intentionally goes offline. In other words, the server does not to need to receive a request timeout to understand that the node is sleeping, it is sufficient that the server is not speaking from a precise time interval with the node to understand that the node went to sleep.
In Leshan implementation of the Queue mode I do not find any referencies about this time interval, beyond which the node goes to sleep.   


In addition to this I did a test, I set the LWM2M Binding Mode equal to "UQ", so the node registered properly in Queue mode on the Leshan public server. Then I unplugged the USB of the node and asked the server to query this node. I got exactly a request timeout error as when the node had Binding Mode set to "U" so (without Queue mode active): I would have expected something different. So I don't understand how the Leshan server interprets the request timeout error as a state of sleep by the node.



Could I have some clarifications on the considerations stated here?
Could you explain how to test the Queue mode with the Leshan server?

Thank you very much,
Yours faithfully
Jacopo Piani


_______________________________________________
leshan-dev mailing list
leshan-dev@xxxxxxxxxxx
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/leshan-dev


_______________________________________________
leshan-dev mailing list
leshan-dev@xxxxxxxxxxx
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/leshan-dev



Back to the top