camaraproject / DeviceStatus

Repository to describe, develop, document and test the Device Status API family
Apache License 2.0
11 stars 33 forks source link

SubscriptionExpireTime in not mandatory in subscription API #156

Closed Chintanlodariya closed 2 months ago

Chintanlodariya commented 4 months ago

If the subscription API from the client is without "subscriptionExpireTime," as it is not a mandatory parameter, what should be the recommended default value that needs to be configured in the API, as this needs to be passed towards NEF for the subscription?

as per 29.122- 5.3.2.1.2 (Note2): Inclusion of either "maximumNumberOfReports" (with a value higher than 1) or "monitorExpireTime" makes the Monitoring Request a Continuous Monitoring Request, where the SCEF sends Notifications until either the maximum number of reports or the monitoring duration indicated by the property "monitorExpireTime" is exceeded. The "maximumNumberOfReports" with a value 1 makes the Monitoring Request a One-time Monitoring Request. At least one of "maximumNumberOfReports" or "monitorExpireTime" shall be provided.

bigludo7 commented 4 months ago

@Chintanlodariya For me this up to your implementation. As API server, your rule perhaps will be to no offer longer than 12 months subscription (I guess privacy issue could enter in the mix). If the API consumer did not provide subscriptionExpireTime that's fine and you will set the expire attribute in the response with the value you offer as provider.

Globally for this topic the 'rules' are here.

maxl2287 commented 2 months ago

@Chintanlodariya to be more precise based on @bigludo7's comment:

When none subscriptionExpireTime and subscriptionMaxEvents are not provided, client side has to trigger a DELETE operation to terminate it.

see ApiDesignGuidelines

Is this okay for you and we can close this issue? Otherwise you may create an issue on Commonalities to discuss this more?