Project Wrapup

by 9:52 PM 0 comments
Yes! It's almost over. GSoC 2016 is in the final week of the journey. So in this post, I will briefly explain the work I've done along with a link to each deliverable.

Summary

For this project I have implemented several things. Listed down are the tasks that I did.
  1. JBrowse Comments Track
  2. Express back-end 
    • Host an instance of JBrowse
    • Github authentication strategy 
    • Implement route to write changes of comment track back to the data file
  3. Sails hooks to replace the functionality of the express back-end
Next I will describe the tasks and the outcomes of each of the tasks mentioned above very shorty.

JBrowse Comments Track

Following are the new technologies that were encountered while implementing the comments track.
  • dojo framework
  • dojo/xhr 
  • dojo/query
  • disqus comment platform/API
  • facebook comments
The most challenging part of this task was understanding the JBrowse code base, how the tracks, data, data stores and decorators are related, the flow of events, data structures used and how html elements are lazily rendered. 

I have added the changes to my local fork and created a pull request(#802) to the main repository. Before I was given a separate branch, I worked in the master branch of my local fork. Here are the links to the commits section of each branch.
To see the Comments Track in action, clone the main GMOD/jbrowse repository, checkout the jSocialize branch, setup JBrowse as instructed in the main Readme.md file, and then host JBrowse in any web server like apache or NodeJs. Shown below is an screenshot of the comments Track with sample data.


I have implemented my own version of ExpressJs based NodeJs web server for hosting JBrowse. More details can be found in the next section.

The main documentation can be found at the following wiki page.


Express Back-end 

The implementation of this expressJs based NodeJs server for hosting JBrowse can be found at following link.

Though we can host Jbrowse with this server, the primary requirement of this server is to provide the back-end API for writing comment track meta data back to the trackdata.json file. This is accomplished by implementing a RESTful POST endpoint. The Sails hook implementation which is explained in the next section was built to accomplish the same task since the actual server component of JBrowse is being written in Sails.js.

A secondary functionality of the express back-end server is providing an OAuth authentication strategy using passport-github2. Details on how to setup the server for this can be found in the main Readme file at the repository.

Technologies and learning materials that I came across while implementing this feature are

  • NodeJs
  • ExpressJs
  • EmbeddedJs
  • Passport / passport-github2
  • NCList data structure
  • ArrayRepr decorators 

Sails Hook

The sails hook was implemented to accomplish the task of writing comments track metadata back to the data source. Following links are related to this implementation.

The npm package can be installed to any sails core application by issuing npm i sails-hook-jbrowse command.


Future Works

Other than the above tasks which were implemented completely, I am in the process of implementing the following tasks. I am planning to finish these tasks in my free time after the GSoC program.


~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

0 comments:

Post a Comment