adlnet / xAPI-Spec

The xAPI Specification describes communication about learner activity and experiences between technologies.
https://adlnet.gov/projects/xapi/
899 stars 405 forks source link

question: omitted 'registration' parameter of State Resource #1086

Open sir-sigurd opened 5 years ago

sir-sigurd commented 5 years ago

When registration parameter is omitted the behavior of State Resource is not quite clear for me.

For example when Multiple Document DELETE with omitted registration is requested, does it delete all States for the specified activityId and agent or just States that were created with no registration specified?

garemoko commented 5 years ago

That's an interesting question and I agree that as the spec currently reads, this is ambiguous not just for multiple document delete, but also for multiple document get and for single document get and delete. We should update this to make it clearer.

The way Watershed LRS implements this, which I believe is what was intended, is that 'no registration' is treated as if it is itself a registration. So if you send a GET or DELETE request with no registration, you will only get or delete state documents that were stored with no registration.

For single document GET at least, this seems to be the only practical interpretation since the expected response is a single document, and if the intention was that the LRS should return documents with any registration, that could be multiple documents. And if we take that interpretation for single document GET, that pushes us towards the same interpretation for multiple document GET and for single/multiple document DELETE. (Single document DELETE is also implied to only affect a single document).

But yes, it definitely could be made clearer.