Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

The Synapse Certified User test is represented in a JSON format so that the prompts, responses, and answer key are easily extracted.  Since this format would be prohibitively awkward for the author to edit, we allow the quiz to be written as a simple text file and use ad an ad hoc parser to generate the required JSON.  The procedure for doing this is as follows: 


1) Clone the git repository: https://github.com/Sage-Bionetworks/QuizTextToJSONConverter

...

3) Run the sole Java class in the cloned repo' (QuizTextToJSONConverter), ensuring that "quiz.txt" is on the classpath.  The generated JSON will be printed to stdout.

4) (Optional) Paste the output into http://www.freeformatter.com/json-formatter.html to format it in a user readable form.

5) Put the JSON into a file named repositoryThis creates a file "repository-managers.certifiedUsersTestDefault.json".

64) Upload into the S3 bucket proddata.sagebase.org under the production AWS account.Within 60 seconds the newly uploaded quiz will be available in Synapse.  To make the modification immediately available use the name "repository-managers.certifiedUsersTestDefault_v4.json".  If the priority is to maintain a history, then increment the name in S3 and update the file name in the Synapse code base here: https://github.com/Sage-Bionetworks/Synapse-Repository-Services/blob/develop/services/repository-managers/src/main/java/org/sagebionetworks/repo/manager/CertifiedUserManagerImpl.java#L57 . The change will not be available in Synapse until the following stack release however it gives the editor a chance to check the appearance of the quiz prior to production deployment.