 
   def push_missing do
     limit = 2_500
-    episode_limit = limit * 3
 
     category_ids = from(c in Category, where: is_nil(c.elastic) or c.elastic == false,
                                        limit: ^limit,


    Logger.info("=== Indexed #{length(podcast_ids)} podcasts ===")


    episode_ids = from(c in Episode, where: is_nil(c.elastic) or c.elastic == false,
                                       limit: ^episode_limit,
                                       select: c.id)
    |> Repo.all()

    for id <- episode_ids, do: Episode.update_search_index(id)

    from(c in Episode, where: c.id in ^episode_ids)
    |> Repo.update_all(set: [elastic: true])

    Logger.info("=== Indexed #{length(episode_ids)} episodes ===")

    Logger.info("=== Indexing finished ===")
  end



    user_ids = from(c in User, where: is_nil(c.elastic) or c.elastic == false,
                               limit: ^limit,
                               select: c.id)
    |> Repo.all()

    for id <- user_ids, do: User.update_search_index(id)
