GSoC Experience

During last 3 months I enjoyed my life working with an open source project belonged to Sustainable Computing Research Group(SCoRe) organization and it was a great pleasure for me to work with them. In this period my contribution was to the newly started project called Drone-Comm which is a community platform. In this project I developed backend API and frontend user interfaces under guidance of my 2 mentors Mr.Charitha Madusanka and Mr.Eranjan Kandegedara. This article has a summary of the work I have done during GSoC 2017.

What I have done?

In this project I have developed separate backend and frontend. As the backend I have implemented RESTful API using NodeJS and MongoDB as the database to persist system information. Frontend is developed using Angular 4 framework.

Architecture

The below diagram shows overall architecture of the system. Backend(REST API) is using 3-tier architecture. It’s included tiers are,

  1. Controller(Presentation tier)
  2. Service(Business tier)
  3. Repository(Data Access tier)
Diagram 1

Work done

First I designed Database for Drone Comm and then developed backend platform as a RESTful API. In below we discuss services supported by Drone Comm platform REST API.

Authentication Service

Drone Comm platform is using JSON Web Token(JWT) authentication mechanism to maintain access control of Drone Comm platform. Client application wants to send login request to the REST API before calling the other services of the REST API in Drone Comm platform. If authentication credentials of the login request are correct (login is success), then platform generates and sends JSON web token to the client as a response to login request. This token acts as the shared key in this platform. Then client must attach this token as request header with future API calls after the login request. Because client’s all APIs calls except login and registration go through authentication filter. In this filter, it checks the token is attached with a valid request or not. If the token is valid, then request is forwarded to the route to continue service. Otherwise, Filter builds failed response and send to client.

When a user get registered, an email verification also has to be done. Persisting user detail, generating verification key and sending verification key to given email are happening when user register in Drone Comm. After that process, user needs to login in to the email account and and verify email, for activating the user account in Drone Comm.

Mainly this service provides above features.

User profile service

This service maintains user profile and drone information. That is, it provides functionalities to persist, find, modify and delete profile and drone information.

Drone Task Service(Drone Request Service)

Managing drone task requests and responses is done in this service. Drone Comm has 2 type of users. Those are,

  • Drone Client

Mainly a Drone Client can discover community available drone details, create drone request tasks, publish those tasks and select the drone pilot that client wants.

  • Drone Pilot

Pilot discovers available drone tasks and bids for selected tasks. Pilot has drone client use cases.

Drone Clients can request tasks using this service and drone pilot can view those drone task requests and response or bid them.

In this case each drone pilot maintains a separate queue to get notifications of newly added drone task requests. This design pattern is similar to Publisher Subscriber message pattern. Drone Clients are the publishers who publish requests and Drone Pilots are the subscribers.

Next part of Drone Comm is the front end as a web application. I have developed few user interface components to use Drone Comm platform easily. In below you can see some screenshots of the Drone Comm web application.

USer login interface
USer registration interface
Email Verification
Create user new drone
Create New Drone Task

Github Repository : https://github.com/Amila1991/Drone-Comm

Drone Comm API Documentation : https://drive.google.com/openid=1hbae5COEZc82dPIb3Jp3H5eDjJp8n1SFj0j6_l1avbU

)
Welcome to a place where words matter. On Medium, smart voices and original ideas take center stage - with no ads in sight. Watch
Follow all the topics you care about, and we’ll deliver the best stories for you to your homepage and inbox. Explore
Get unlimited access to the best stories on Medium — and support writers while you’re at it. Just $5/month. Upgrade