Challenge Overview
Project Overview
This project will build NodeJS REST APIs for TopCoder Platform.
Competition Task Overview
We are building platform APIs on our NodeJS Framework which will execute raw sql directly to fetch / update the data in database.
This contest should write the raw querfies for following APIs, prepare test data and provide manual verification steps via website (it means you need to deploy /tc on your VM)
API Specification: http://docs.tcapi.apiary.io/
Queries for following APIs are required in this contest:
- Algorithm Member SRM Statistics - /v2/data/srm/statistics/{handle}
- Top Ranked SRM Members - /v2/data/srm/statistics/tops?rankType={rankType}
We already have some queries in query tool, you can find them here: https://coder.topcoder.com/internal/database/scripts/trunk
We don't have exactly same queries for algorithm SRM but you can find some similar queries in https://coder.topcoder.com/internal/database/scripts/trunk/topcoder_dw/query_tool/
Note: Test Data is an important task for this contest. You must prepare the test data carefully to make sure it could cover all cases.
Parameterized queries
The queries must be parameterized. Please use same format for the parameters in the existing query tool queries and provide demo value to test it.
It needs to support sorting, paging and input parameters to the query. You must use the same parameter names and approach that is already used elsewhere, such as /v2/develop/challenges.
You can request a VM with informix installed.
Submission Format
For each query:
- Parameteried Query File: {api name} e.g. get_srm_statistics
- Test Data File:
- {api name}.insert Insert Test Data e.g. get_srm_statistics.insert
- {api name}.delete Clean Test Data e.g. get_srm_statistics.delete
- Test Case File: {api name}.tests
- Two lines for each test case. First line is document and second line is the test query
- e.g.
- get_srm_statistics.tests
- -- get srm statistics
- select ..... from .... where handle = 'iRabbit'
Virtual Machine (VM)
VM specific information is found here: http://www.topcoder.com/wiki/display/docs/VM+Image+2.5
Upon registration as a submitter or reviewer you will need to request a VM based on the TopCoder systems image. The VM will be active through aggregation review, after which it will be terminated except for the winner's and the reviewers'. To request your image, please post in contest forum.
Before requesting your VM, you need to ensure that you have an SSH key created and in your member profile. Instructions to do so are here: http://www.topcoder.com/wiki/display/projects/Generate+SSH+Key, and instructions to connect afterwards are here: http://www.topcoder.com/wiki/display/projects/Connect+Using+SSH+Key.
Please realize that VMs are currently issued manually. We make every attempt to issue the VM as soon as it is requested, however, there may be delays of up to 12 hours depending on time of day when you request. We encourage everyone to request a VM as soon as possible to minimize any such delays.
VMs will be granted only during registration phase!
Technology Overview
- SQL
Final Submission Guidelines
- Parameterized Queries with document
- Deployment Guide (Verification Steps are very important)
- Test Data Insert Script
- Test Cases