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

I wonder why the firmware image/5/0/0 CoAP method is POST. #526

Open
JeongByungYeol opened this issue May 26, 2021 · 2 comments
Open

I wonder why the firmware image/5/0/0 CoAP method is POST. #526

JeongByungYeol opened this issue May 26, 2021 · 2 comments
Labels

Comments

@JeongByungYeol
Copy link

Hello
Here's a question.

http://www.openmobilealliance.org/release/LightweightM2M/V1_2-20201110-A/HTML-Version/OMA-TS-LightweightM2M_Transport-V1_2-20201110-A.html
In this document, Write selects PUT and POST.
PUT: Replacement
POST: Partial update for multi-instance resources only »/{Object ID}/{Object instance ID}/{Resource ID}
It says like this.

Send firmware images on firmware update
http://www.openmobilealliance.org/release/LightweightM2M/V1_2-20201110-A/HTML-Version/OMA-TS-LightweightM2M_Core-V1_2-20201110-A.html#Figure-E62-1-Example-of-a-LwM2M-Server-pushing-a-firmware-image-to-a-LwM2M-client

The firmware object is Single Instance.
In the example above, why was it delivered in post format?

@sbernard31
Copy link

My guess this is a specification error.
(Not the first time there is error in examples, some of them are reported for several years and still not fixed 😞 #281)

Reading http://www.openmobilealliance.org/release/LightweightM2M/V1_2-20201110-A/HTML-Version/OMA-TS-LightweightM2M_Transport-V1_2-20201110-A.html#6-4-4-0-644-Device-Management-and-Service-Enablement-Interface

You can see that POST on /{Object ID}/{Object Instance ID}/{Resource ID} is :

  • either an EXECUTE request
  • or a WRITE (Partial Update) for Multiple-Instance Resources

@mojanm
Copy link

mojanm commented May 27, 2021

Agreed, it should be PUT and not POST.
Another minor point being that it's legacy from v1.0.x where a single spec covered both Core and Transport. From v1.1 the Core Spec is meant to be Transport agnostic. Therefore, technically no explicit example should use CoAP methods or any other binding??

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

4 participants