Пример #1
0
        public void ProcessManyBooksForSearch(IList <BookSearchDocument> message)
        {
            Console.ForegroundColor = ConsoleColor.Green;
            Console.WriteLine("-----------------Processing Many SearchDocs now...-----------------");

            var searchDocs = message as IList <BookSearchDocument>;

            if (searchDocs != null)
            {
                _bookSearchRepository.IndexAsync <BookSearchDocument>(searchDocs);
                Console.WriteLine("Bulk of search docs being indexed asynchronously");
            }

            Console.WriteLine("\n-----------------Processing Complete..-----------------");
            Console.ResetColor();
        }