In a nod to improving the performance of its Bing.com search services, Microsoft recently transitioned Bing.com to run on .NET Core 2.1, which is an upgrade from the .NET Framework it ran on previously.
The change was unveiled in an Aug. 20 post on The .NET Blog by Mukul Sabharwal of the Bing.com engineering team.
“The main reasons driving Bing.com’s adoption of .NET Core are performance (server latency), support for side-by-side and app-local installation independent of the machine-wide installation,” wrote Sabharwal.
“In anticipation of those improvements, we started an effort to make the code portable across .NET implementations, rather than relying on libraries only available on Windows and only with the .NET Framework,” he wrote. “The team started the effort with .NET Standard 1.x, but the reduced API surface caused non-trivial complications for our code migrations. With the 20,000+ APIs that returned with .NET Standard 2.0, all that changed, and we were able to quickly shift gears from code modifications to testing.”
After fixing some bugs, Microsoft released the new NET Core 2.1 code to production for Bing.com, he added.
With .NET Core 2.1 replacing the old .NET Framework, latency within the Microsoft Bing internal production servers has dropped by 34 percent, according to the post.
Among the significant performance changes for developers in .NET Core 2.1 are vectorization of string.Equals & string.IndexOf/LastIndexOf, which helps improve performance for string-heavy workloads like HTML rendering and manipulation, as well as devirtualization support for EqualityComparer<T>.Default and Software Write Watch for Concurrent Garbage Collection, which led to reduction in CPU usage in the application.
The use of .NET Core 2.1 also now brings Brotli compression algorithm support to the .NET library ecosystem, wrote Sabharwal. Bing.com uses Brotli to dynamically compress the content and deliver it to supporting browsers.
Runtime agility is now improved under .NET Core 2.1 because the new ability to have an xcopy version of the runtime inside an application means newer versions of the runtime can be adopted at a much faster pace, he added.
“We’re excited about the future and are collaborating closely with the .NET team to help them qualify their future updates,” wrote Sabharwal. “The .NET Core team is excited because of our large catalog of functional tests and an additional large codebase to measure real-world performance improvements on, as well as our commitment to providing both Bing.com users fast results and our own developers working with the latest software and tools.”
The Bing.com search engine runs on thousands of servers spanning many data centers across the globe, handling thousands of search queries from users every second around the world, as well as from Microsoft partners using the Microsoft Cognitive Services APIs and from users of Microsoft’s personal digital assistant, Cortana.
“Our users demand both relevancy and speed in those results, thus performance and reliability are key components in running a successful cloud service such as Bing,” wrote Sabharwal.
“As gatekeepers of that front-end platform at Bing, we consider developer productivity and feature agility as additional key components in our definition of success,” he wrote. “Hundreds of developers rely on this platform to get their features to production, and they expect it to run like clockwork.”