Hydra/Linea Transformation


Reskinning

To reskin Hydra, we edited Javascript and the CSS files to replace color hex codes, replace images, and adjust sizes. Along with this, the newsfeed page that Linea uses was present in Hydra, but was not being utilized, so we enabled it in the updated Linea version. Lastly, an “About” item in the navigation menu that links to the DocGraph website was also added.



Google OAuth

Using OAuth allows for developers to shift the burden of authentication from their own personal implementations to a well-established, third-party entity such as Google. For the user, utilization of OAuth for authentication tends to be much simpler because it eliminates the need to create another account.

OAuth Process




OAuth Implementation

  • We used the OmniAuth gem for Ruby on Rails, which acts as a dissociated black-box for authentication and supports the use of multiple providers and even LDAP.
  • In Linea, the OmniAuth gem generates the code that does the heavy lifting for steps 1 and 2 of the graphic: receiving the token and pushing it back up to the server.
  • The OmniAuth gem also does the heavy-lifting of the token validation server side (step 3), really allowing the developers to focus on generating the proper user session after the user has been authenticated.


Database Transfer

  • Because Hydra and Linea evolved independently, they have different tables within their database, and sometimes different fields within the same table.
  • Hydra and Linea share most (22) tables within their databases, which were easily carried over into the new database.
  • Hydra had 11 tables not in Linea, but these were eliminated because they were empty in Hydra and not referenced in the code.
  • Linea had 3 tables not in Hydra that corresponded to features unique to Linea.
    • These tables were approved to be dropped.
    • We transferred the tables anyway to ensure no data was lost.