Consumption workflow - Survey and Observation( with and without rubric) created using KP for Manage Learn Usecase. #18
aks30
started this conversation in
General Discussions
Replies: 1 comment 2 replies
-
@maheshkumargangula, @vinukumar-vs and @vrayulu can you please help Akash with the API design proposed above? |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Purpose:
Come up with a workflow and solution to utilize observation and surveys created using VDN to be consumed within current and upcoming Manage Learn programs via the current consumption channels enabled for Manage Learn users (Portal and App)
Context:
So far Observations(with and w/o rubric) and Survey are created using Manage Learn APIs exposed for the implementation team(the partners raise tickets for the same and give the necessary data in a CSV). These questions are then consumed using Manage learn player both on the app and portal.
We have during the past few months enabled creation of observation and survey using the creation portal(KP) thereby moving towards having all the questions in one common storage on the platform as well as removing the dependency on the implementation team. We are also working to migrate all the old and current observation and survey questions to KP. Going forward all new question sets will be created in KP only.
This document talks about how these question sets created using KP will be consumed for Manage Learn programs and usecase via the existing portal and app.
Solution:
Once a question set in VDN is identified to be used within a Manage Learn program we will duplicate the same question set in VDN and change the visibility to Private. It will delink the original question set to the one being used in the program so that any change in the original template doesn’t affect an ongoing program and within a program, the meta of it can be modified e.g. name, description, etc.
At present, the consumption side APIs for observation and survey are being used in Manage learn programs get the data from MongoDB. With all the new question sets now being created using KP, we will now switch the current APIs to get data from the questionSet read API transform the same(for backward compatibility) and pass it in API response. The transformed structure will be stored in Redis for faster retrieval for repeated access.
Migration Plan here
Plan for transforming the KP response into MongoDB response format as to not alter consumption API responses:
Implementation Design:
1) New APIs in Manage Learn to map a questionSet from KP to a program ===> questionsetId, programId
Repo to change: ml-survey-service
Api Endpoint: program/observation/create
API Request:
Success Response:
Error Response:
Endpoints to use
Copy_Questionset: https://dock.sunbirded.org/api/questionset/v1/copy/{questionsetId to copy}
Update_Questionset: https://dock.sunbirded.org/api/questionset/v1/update
Publish_Questionset: https://dock.sunbirded.org/api/questionset/v1/publish/{copiedQuestionsetdo_id}
Read_Questionset: https://dock.sunbirded.org/api/questionset/v1/hierarchy/{$copiedQuestionsetdo_id}?mode=edit
Implementation:
2) New Manage learn API to Update any QuestionSet already mapped to a program ===> solutionObjectId (from request params) and updated data (from request body) ===>
Repo to change: ml-survey
Api Endpoint: program/observation/update/:solutionId
Assumption: only name or description will be updated
Request:
Success Response:
Error Response :
End points to use:
Update_Questionset: https://dock.sunbirded.org/api/questionset/v1/update
Publish_Questionset: https://dock.sunbirded.org/api/questionset/v1/publish/{copiedQuestionsetdo_id}
Implementation:
Below list of Manage Learn APIs which need to change to read data from Questionset read API or redis :
Cc - @vijiurs, @kiranharidas187 @aishwaryashikshalokam, @priyanka-TL, @VISHNUDAS-tunerlabs, @Shakthieshwari, @Prateek-slokam, @MeghnaSL, @joffinjoy, @githubpiyush
Beta Was this translation helpful? Give feedback.
All reactions