Key Information

Register
Submit
The challenge is finished.

Challenge Overview

As part of the larger Boat-In-a-Box project, the client would like to develop a web-based tool to assist in creating various scenarios.

Scenario is a time series data set containing data about ships. The user is able to place ships onto the map and for each one he can set a "Course" including a Heading, a Speed (in knots), the amount of travel time, and the start time. Ships can also change direction and speed during the scenario.

 

In this challenge we'll develop NodeJS backend to support the above tool. The requirements are as follows:
1. Create user management service that will support only login endpoint and will return the jwt token used to access all other API endpoints. Users will be manually added to the database and we'll support only username/password based authentication.
2. 
Create Scenario management service that will manage scenarios (all operations are bound to specific user). It will have these endpoints:

        create (scenario)

        update (scenario)

        delete (id)

        list()

        get(id)

        simulate(id) - see below for details

        download(id)
Scenario can be described by the following data model

    {

        id - unique scenario id

        name - scenario name

        totalDuration - scenario duration in minutes

        ships : [

            {

                id - unique ship id (just a number sequence, not mongo ids),

                name - ship name,

                locations : [

                    {

                        startTime - seconds since scenario start,

                        position : [lon,lat],

                        speed - knots,

                        heading,

                        duration - minutes

                    }

                ]

            }

        ]

    }

 

Each of the ship.location objects contains one point of the ship's path in the scenario. Scenario simulation consists of interpolating all the ships positions in discrete time intervals for the duration of the scenario. More specifically, simulation endpoint should return position/heading for each of the ships for every time point of the simulation (seconds).

Download endpoint should run the above simulation, write the data in AIS format and return the file for download. AIS format encoding is described at http://catb.org/gpsd/AIVDM.html#_aivdm_aivdo_sentence_layer and http://www.bosunsmate.org/ais/


MongoDb should be used as database and mongoose as DAL



Final Submission Guidelines

Submit a complete source code for the application

Submit a readme/verification guide

Submit a postman file for verifying the service endpoints

ELIGIBLE EVENTS:

2017 TopCoder(R) Open

REVIEW STYLE:

Final Review:

Community Review Board

Approval:

User Sign-Off

SHARE:

ID: 30056447