A native/desktop music search app using electron

We were engaged to build a portable solution of a complex web platform which allows users to search through around 1 million tracks, then download and stream them. Electron.js presented itself as an obvious fit since it would allow us to apply our experience with web-technologies and use it to build a native application.

The added challenge to this project is that the electron application had to run entirely offline, so all functionality had to be provided by the application itself. That is to say: no API calls to provide search results using fancy server-side tech.

Technology Overview

Full-text search

The web-based version of this platform relied on a SOLR-cluster for providing full-text search functionality. Using this would be either impossible, or ill-advised, so we turned to sqlite instead. Sqlite comes with a handy feature that provides full-text search functionality.

Although of course sqlite is very far from a drop-in replacement for SOLR, we found that the performance and the relevancy of the results were impressive. The client thankfully agreed.

Building & Publishing the Electron Application (CI/CD)

The electron application needed to run on the latest versions of both OSX and Windows. In order to build a Windows installer or DMG the application needed to be built on the particular target operating system. We decided to use Github Actions for this purpose, which turned out to be fairly straight-forward.

The job that ran the test suite would be executed on each push and each pull request. The job that published the built artifacts (to S3) on each tagged release.

The result was that developers could then simply create a new release simply by typing make version in the terminal. The developer would then be prompted what kind of semantic release she was making (major|minor|patch|pre-release) after which the tagged commit would be pushed and the build plan would build the artifacts and push them to S3, from where they could be distributed.