Navigation

    FusionAuth
    • Login
    • Search
    • Home
    • Categories
    • Recent
    • Popular
    • Pricing
    • Contact us
    • Docs

    SOLVED What is the advantage of using ElasticSearch as the search engine?

    Q&A
    elastic search user search
    1
    4
    6334
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • dan
      dan last edited by

      What is the advantage of using ES over the database as the search engine?

      From the docs we can choose either, but I am interested to know what I would be missing if I were to use DB as the search engine instead of Elastic.

      --
      FusionAuth - Auth for devs, built by devs.
      https://fusionauth.io

      1 Reply Last reply Reply Quote 0
      • dan
        dan last edited by

        TL:DR, Elasticsearch is much more powerful than DB. But if you only have a couple thousand users and don’t need to perform sophisticated queries, the upside is that you don’t need to run Elasticsearch as a separate component.

        The DB search doesn’t provide the full search query capabilities that ES does. It also won’t scale to millions of users nearly as well as ES does.
        This doc has some information on the differences: https://fusionauth.io/docs/v1/tech/apis/users#search-for-users

        Some higher level details here as well : https://fusionauth.io/docs/v1/tech/core-concepts/users#user-search

        --
        FusionAuth - Auth for devs, built by devs.
        https://fusionauth.io

        1 Reply Last reply Reply Quote 0
        • dan
          dan last edited by

          You can always change your mind as well. If you start with db for ease of development, setup and maintenance, you can then later switch to elastic, and perform a reindex operation to initialize the elasticsearch index.

          Or vice versa. It just requires a config change, a restart and then an index operation to move to Elasticsearch.

          --
          FusionAuth - Auth for devs, built by devs.
          https://fusionauth.io

          1 Reply Last reply Reply Quote 1
          • dan
            dan last edited by

            Here's a doc about how to switch search engines: https://fusionauth.io/docs/v1/tech/tutorials/switch-search-engines

            --
            FusionAuth - Auth for devs, built by devs.
            https://fusionauth.io

            1 Reply Last reply Reply Quote 0
            • First post
              Last post