Giter VIP home page Giter VIP logo

typesense / showcase-songs-search Goto Github PK

View Code? Open in Web Editor NEW
157.0 11.0 16.0 5.04 MB

A site to instantly search 32M songs from the MusicBrainz songs database, using Typesense Search (an open source alternative to Algolia / ElasticSearch) ⚡ 🎵 🔍

Home Page: https://songs-search.typesense.org

License: Apache License 2.0

HTML 25.24% JavaScript 70.67% SCSS 4.09%
typesense instantsearch-js typesense-instantsearch-adapter musicbrainz

showcase-songs-search's Introduction

🎶 MusicBrainz Song Search, powered by Typesense

This is a demo that showcases some of Typesense's features using a 32 Million database of songs.

View it live here: songs-search.typesense.org

Tech Stack

This search experience is powered by Typesense which is a blazing-fast, open source typo-tolerant search-engine. It is an open source alternative to Algolia and an easier-to-use alternative to ElasticSearch.

The songs dataset is from MusicBrainz which is an open music encyclopedia that collects music metadata and makes it available to the public. Please contribute to it if you're able to!

The app was built using the Typesense Adapter for InstantSearch.js and is hosted on DigitalOcean's App Platform.

The search backend is powered by a geo-distributed 3-node Typesense cluster running on Typesense Cloud, with nodes in Oregon, Frankfurt and Mumbai.

Repo structure

  • src/ and index.html - contain the frontend UI components, built with Typesense Adapter for InstantSearch.js
  • scripts/indexer - contains the script to index the MusicBrainz data into Typesense.
  • scripts/data - contains a 1K sample subset of the MusicBrainz songs database. But you can download the full dataset from their website.
  • scripts/benchmarking - contains a k6 script to load test the Typesense Server.

Development

To run this project locally, install the dependencies and run the local server:

npm install -g parcel-bundler # Need to use NPM for this: https://github.com/parcel-bundler/parcel/issues/1036#issuecomment-559982275

yarn
yarn run typesenseServer
ln -s .env.development .env
BATCH_SIZE=1000 yarn run indexer
yarn start

Open http://localhost:3000 to see the app.

Deployment

The app is hosted on DigitalOcean App Platform.

Pushing to master will deploy the app to production.

showcase-songs-search's People

Contributors

brettinternet avatar jasonbosco avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

showcase-songs-search's Issues

Selecting filters produce a lot of pemding requests

Description

When i select random filters fastly a lot of requests are spammed in the network tab and they are pending so i need to wait all of them to finish to see the end result. Probably some type of wait timer should be implement lets say 1 second before a request is sent.

Steps to reproduce

Select multiple filters, watch browser network tab.

Expected Behavior

Send requests some time after user finish selecting filters.

Actual Behavior

Spamming requests on every click leading to a lot of pending requests and data not loading until all finished.

Metadata

Typsense Version: songs-search.typesense.org

OS: songs-search.typesense.org

查询结果没有任何东西

Description

没有任何查询结果。示例程序按示例可以运行,但没有查询结果。

Steps to reproduce

Expected Behavior

Actual Behavior

Metadata

Typesense Version:

OS:

songs doen't appear

Description

Steps to reproduce

Expected Behavior

Actual Behavior

I am trying to install locally. I follow the steps, but when I put yarn run typesenseServer, I have the next messages
Captura de pantalla de 2023-11-21 18-44-07
Captura de pantalla de 2023-11-21 18-44-39
I20231121 17:37:27.815099 83 raft_server.h:55] Peer refresh succeeded!
I20231121 17:37:37.816156 80 raft_server.cpp:430] Term: 6, last_index index: 6, committed_index: 6, known_applied_index: 6, applying_index: 0, pending_index: 0, disk_index: 6, pending_queue_size: 0
I20231121 17:37:37.816299 83 raft_server.h:55] Peer refresh succeeded!
I20231121 17:37:47.817185 80 raft_server.cpp:430] Term: 6, last_index index: 6, committed_index: 6, known_applied_index: 6, applying_index: 0, pending_index: 0, disk_index: 6, pending_queue_size: 0
I20231121 17:37:47.817239 83 raft_server.h:55] Peer refresh succeeded!
I20231121 17:37:57.818413 80 raft_server.cpp:430] Term: 6, last_index index: 6, committed_index: 6, known_applied_index: 6, applying_index: 0, pending_index: 0, disk_index: 6, pending_queue_size: 0
I20231121 17:37:57.818523 83 raft_server.h:55] Peer refresh succeeded!
I20231121 17:38:07.819366 80 raft_server.cpp:430] Term: 6, last_index index: 6, committed_index: 6, known_applied_index: 6, applying_index: 0, pending_index: 0, disk_index: 6, pending_queue_size: 0
I20231121 17:38:07.819473 83 raft_server.h:55] Peer refresh succeeded!
I20231121 17:38:17.820418 80 raft_server.cpp:430] Term: 6, last_index index: 6, committed_index: 6, known_applied_index: 6, applying_index: 0, pending_index: 0, disk_index: 6, pending_queue_size: 0
I20231121 17:38:17.820564 83 raft_server.h:55] Peer refresh succeeded!
And this is infinity. Then I stop it with CTRL+C and I have the searcher, but no data.

Metadata

Typesense Version:

OS:

How is the musicbrainz data collated?

MusicBrainz provides Musicbrainz data by Postgres server, or by JSON dumps. I'm assuming the example data here is collated from the JSON dumps, but how is the data file for the single schema format generated?

Ensure selected values remain visible

Description

Under certain circumstances selected values become invisible, so user cannot deselect them.

Steps to reproduce

  1. search for "e". Facets appear.
  2. select Artist -> Various Artists
  3. select Release date -> 2020s (it just became visible)
  4. deselect Artist -> Various Artists
  5. Release date -> 2020s is still selected but disappears, so we cannot deselect it if we want to

Expected Behavior

Maybe instantsearch can be configured/forced to keep showing selected values (preferably not in "show more" expansion area)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.