Company
Date Published
Author
Stuart Cam • Russ Cam
Word count
872
Language
English
Hacker News points
None

Summary

Stuart Cam and Russ Cam discuss the challenges and solutions of upgrading Elasticsearch servers and codebases, particularly when using different major versions of the NEST client and Elasticsearch server. They explain the compatibility issues between client and server versions, noting that using a 6.x .NET client with a 7.3 Elasticsearch cluster is not recommended due to differences in request and response object formats. To solve this, they propose using namespaced versions of NEST and Elasticsearch.Net clients available through their continuous integration (CI) server, allowing developers to reference different client assemblies tied to specific major versions. By replacing official Nuget packages with those from the CI package source and prefixing existing types, developers can use both the 6.x and 7.x clients simultaneously in the same project, facilitating a gradual migration to newer versions. The authors stress that this approach is temporary and should be used to aid the transition, as CI packages do not offer the same level of support as official releases. The article also touches on the use of AssemblyRewriter in their CI process to rewrite assemblies for performance benchmarking, emphasizing the utility of these packages for other users facing similar upgrade challenges. They conclude by recommending the Elasticsearch Service on Elastic Cloud for a straightforward upgrade path.