Key Information

Register
Submit
The challenge is finished.

Challenge Overview

For this challenge, we'd like to create an API will do Elasticsearch Queries to figure out the numbers that we currently populated in the right side of challenge listing page (https://beta-community-app.topcoder.com/challenges)

By defining the queries, you can use count API (https://www.elastic.co/guide/en/elasticsearch/reference/current/search-count.html) to calcuate the related numbers. that is related to 

- All Challenges (this means all the challenges that is public or the current user have access to)
- My Challenges (all the challenges, the current user have access to, if anonymous, the field should be 0)
- Open For Registrations (same query as All Challenges, plus checking for Regisration phase with Open status)
- Ongoing Challenges (this is not need to be queried, it should be <<All Challenges>> - <<Open For Registrations>>

General Requirements

- Please use the mm-features branch for development
- The endpoint should be like GET /challenges/metadata, please properly update the swagger.yaml file to describe the new API properly and clearly
- The endpoint should make the ES Queries against the configured challenge listing index, and properly returning the result
- Query Performance should be a big consideration for this challenge, please write the query effectively
- For local testing, you can try create some challenges through direct app, you can also create more fake challenges and directly push to elasticsearch.

Local Setup

1. Following https://github.com/appirio-tech/tc-common-tutorials/tree/master/docker/direct-app to run all dependent services
1.1 you need to build from the latest code of direct app (see https://github.com/appirio-tech/tc-common-tutorials/tree/master/docker/direct-app#build-and-run-with-docker-compose)
1.2 also the elasticsearch service should be up, run like (docker-compose up -d elasticsearch)
2. Run the elasticsearch feeder service using mm-features branch, you probably should change the ports (8080, 8081 in src/main/resources/elasticsearch-feeder-service.yaml) due to port conflict.
3. Create some challenges through direct app, so the elasticsearch feeder will get the data populated into elasticsearch and they will be used by challenge service.

Final Submission Guidelines

- Code Changes based on mm-features branch of challenge service
- Setup and Verification Steps

ELIGIBLE EVENTS:

Topcoder Open 2019

REVIEW STYLE:

Final Review:

Community Review Board

Approval:

User Sign-Off

SHARE:

ID: 30074629