-
Notifications
You must be signed in to change notification settings - Fork 408
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
leshan demo server: endpoint in COAPLOG #845
Comments
I'm not sure to understand why you are now using NOTIFICATIONS events + read/observe RESPONSE from But looking at EVENT_COAP_LOG point of view I think it makes sense to add the "ep" property. |
You can just copy/paste the code (I don't mind not being the author) As for why: we're doing a project where we wanted to save all sensor measurements in a Solid pod, but if you want to read for example the Sensor Units, you won't get there with observe (since they don't change). We wanted the leshan demo server web interface to remain the control interface and we just hook our application into the event stream. |
Ok I will add it.
Ok I don't know so much about Solid Pod, but keep in mind you actually plug on CoAP layer and not LWM2M one. |
(added in master : 02b3c5d) |
Thanks for the headsup around blockwise transfer. |
For a university project, we wrote an application which hooks into the RESTful API of the leshan demo server.
We used the events emitted by the server.
We started with NOTIFICATION events, which contain the endpoint in their JSON object ("ep": "iot-device1")
Then we switched to COAPLOG events (because we needed also Read and the first Observe answers), but there we saw that there is no JSON property indicating from which endpoint this comes.
This might (or might not) be a little enhancement for the demo server to be more directly useful.
We (roughly) fixed it with this code in EventServlet.java:
where trace is the function we replaced
Greetings
The text was updated successfully, but these errors were encountered: