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
Adding support for epmin/epmax #18
Comments
|
@asoloway64 This seems like a good addition to the other conditional attributes we have. I do think some additional clarifications would be necessary. How should the CoAP endpoint (an origin server, or the LWM2M client) handle an incoming Observe request which contains epmin/epmax query parameters, but does not have any other attributes present? |
|
@bsilverajan These values only have context when other conditional attributes are present such that a measurement must take place and report potentially generated. If no report would ever be generated, then these parameters that guide when a measurement takes place provide no value. Would you like me to capture the above text somewhere? How about in each table entry: "This value is ignored if other conditional attributes are not provided". |
|
I'm not sure we should be "configuring the device" using query parameters on a GET/observe. |
|
Checking the content on the OMA spec, I am wondering if epmin/epmax make sense from REST pov. Query parameters are used to operate on the state of a resource and not to modify the internal mechanisms nor behaviour of the sensor. Thus evaluation periods would be out of the scope of what a query parameter should do IMO. I'll copy this comment in the OMA issue tracker too if that's OK. |
|
I equate the definition of epmin/epmax to pmin/pmax as they control when a notification report is/can be generated and have noting to do directly with the behavior of the sensor. pmin/pmax have nothing to do with the state of a resource but only when that state is evaluated/reported. epmin/epmax is similar. |
|
Do you perhaps have an example that shows the effects of epmin/epmax? |
|
In the dynlink call yesterday, Klaus showed an example of where the device wakes up every second to check the value of an observed resource. How does the device know to wake up every second to read that sensor? That is how the epmin and epmax values are used. |
|
I have created pull request #20 to address this issue. I did not create an example as I wasn't sure the format that we would wish that example represented. Let's discuss during the interim meeting. |
|
Here is text to consider for the example: |
|
This has been accepted into the draft, so the issue can be closed. |
OMA LwM2M added support for additional attributes that should be reflected back into the dynlink draft to avoid fragmentation. Those attributes are called Minimum Evaluation Period (epmin) and Maximum Evaluation Period (epmax).
The current LwM2M Core Spec currently has this statement:
"The behavior of all Attributes SHOULD follow [DynLink] except epmin and epmax, which are only defined in this specification."
The goal would be to change that statement to:
"The behavior of all Attributes SHOULD follow [DynLink]."
Below is text to consider for the inclusion in the dynlink draft:
"The "Minimum Evaluation Period" (epmin) and "Maximum Evaluation Period" (epmax) values can be used to configure the device to perform reporting evaluations. After the expiry of epmin, the device MAY immediately perform an evaluation per the "Notification Conditions" above. After the expiry of epmax, the device MUST perform an evaluation per the "Notification Conditions". If both the epmin and epmax attributes are defined, the epmin must be less than the epmax."
These are the table entries from the LwM2M Core Specification:
Minimum Evaluation Period | "epmin" "=" 1DIGIT | Resource | Resource Resource Instance Object Object Instance | No | RW | Integer | - | Readable Resource
Notes: The Minimum Evaluation Period Attribute indicates the minimum time in seconds the LwM2M Client MUST wait between two evaluations of reporting criteria. In the absence of this parameter, the Evaluation Minimum Period is not defined.
Maximum Evaluation Period | "epmax" "=" 1DIGIT | Resource | Resource Resource Instance Object
Object Instance | No | RW | Integer | - | Readable Resource
Notes: The Maximum Evaluation Period Attribute indicates the maximum time in seconds the LwM2M Client MAY wait between two evaluations of reporting criteria. When the Maximum Evaluation Period expires after the previous evaluation, a new evaluation MUST occur. In the absence of this parameter, the Maximum Evaluation Period is not defined.
The text was updated successfully, but these errors were encountered: