Skip to content

Releases: elastic/elasticsearch-net

6.0.0

01 Feb 23:18

Choose a tag to compare

GA release of NEST and Elasticsearch.Net 6.0 🎉

A huge thank you to the community who kicked the tires on the 6.0 prereleases that we've been putting out and providing invaluable feedback 🖖

Check out the blog post on the NEST 6.0 release that highlights some of the main features within this major release.

Also check out 5.x -> 6.x breaking changes

Features

  • #2979 exists responses no longer need a custom deserializer
  • #2967 Keyed aggregations
  • #2934 Allow mapping CLR types dynamically on Connection Settings
  • #2939 Make retry for BulkAll pluggable
  • #2983 Split Time out into two types for Time values and Date Math expressions
  • #3009 Auto routing

Enhancements

  • #2355 Add missing properties to Error property on ServerError
  • #2683 Allow analysis components to be specified in Analyze API requests
  • #2684 Support details when using explain on Analyze API
  • #2851 Add phrase_limit for FVH highlighting
  • #2879 Add settings to Rollover index requests
  • #2890 Include classic similarity in index settings
  • #2922 Allow non-string values for Sort "missing" field
  • #2938 Add support for normalizer on the Analyze API

Bug fixes

  • #2828 Change extended_bounds type on Date Histogram aggregations. Thanks @FabienLavocat 👍
  • #2847 Add shard_min_doc_count parameter on Significant Terms Aggregation.
  • #2849 Add params property to phrase_suggest_collate.
  • #2921 Make terms aggregation order assignative rather than additive
  • #2897 GetMany returns empty list after connection failure
  • #2942 Azure repository missing constructor
  • #2941 Ensure verbatim queries send an empty array

Misc

  • #2948 MultiSearchServerError on SearchResponse is no longer needed

Removals

  • #2933 Remove script file related APIs

View the full list of issues and PRs

2.5.7

19 Jan 06:07

Choose a tag to compare

Features & Enhancements

  • #2886 Add ReadSingleOrEnumerableJsonConverter attribute to allow single common_words values to be deserialized
  • #2868 Adding sigma property to extended stats aggregation. thanks @jonyadamit 👍
  • #2911 Set HttpClientHandler.UseProxy=false on DisableAutomaticProxyDetection==true. thanks @codeh 👍
  • #2943 Support non string values for sort missing value
  • #2829 Support DateMath for DateHistogram ExtendedBounds
  • #2847 Add shard_min_doc_count to Significant Terms Aggregation
  • #2851 Add phrase_limit to highlighting
  • #2968 Add additional sort options to Top Hits Aggregation
  • #2965 Add Params to PhraseSuggestCollate
  • #2924 / #2966 Include similarity in index settings

Bug Fixes

  • #2893 Correct serialized property name on AsciiFoldingTokenFilter
  • #2930 Fix all instance of ConfigureAwait(false)
  • #2812 / #2941 Verbatim sends an empty array
  • #2816 / #2942 Fix AzureRepository constructor

View the full list of issues and PRs

6.0.0-rc1

02 Jan 02:15

Choose a tag to compare

6.0.0-rc1 Pre-release
Pre-release

Introduction

The second release of the Elastic .NET packages, to address issues found by customers in the 6.0.0-beta1 release.

These packages are designed to be used in conjunction with Elasticsearch 6.x

Features & Enhancements

  • #2997 Added another hook for properties of type object that need optionally flow through the source converter.
  • #2995 Cannot serialize/deserialize document containing a JoinField without an ElasticClient/SourceSerializer on hand
  • #2977 Add Params to PhraseSuggestCollate (forward port to master)
  • #2971 Add version to PutTemplateRequest
  • #2969 Add Settings, Aliases and Mappings to RollOverIndexRequest
  • #2968 Add additional sort options to Top Hits Aggregation
  • #2817 Setting {dynamic_type} as part of the mapping
  • #2804 BulkAll() retry configuration

Bug Fixes

  • #2999 / #2991 type on has_parent query should be parent_type
  • #2992 Throw a better error message when Join<TParent, TChild>() is called multiple times with different children
  • #2980 Fix/remaining custom converters
  • #2183 Lazily resolve JsonSerializers in JsonNetSerializer

Deprecations

  • #2993 Fix/6.1 deprecations

Misc

  • #2953 TODO cleanup
  • #2940 Added tests for highlighting on inner hits

View the full list of issues and PRs

5.6.0

22 Dec 06:00

Choose a tag to compare

This is a large update to the 5.x version of the client! The REST API specs that are used to generate large parts of the client have been updated to 5.6.5.

This release includes all 32 of the Machine Learning APIs available within X-Pack 🤖 📈

Features & Enhancements

  • #2856 Add Machine Learning APIs
  • #2826 Add SerialDifferencing() to the .Aggs aggregation helper on ISearchResponse<T>
  • #2847 Add shard_min_doc_count parameter for Significant Terms Aggregation
  • #2868 Add sigma property on ExtendedStatsAggregation
  • #2879 Include settings, aliases and mappings on RolloverIndexRequest
  • #2880 and #2971 include version on PutIndexTemplateRequest and GetIndexTemplateResponse
  • #2905 Add terminate_after to Count API
  • #2911 Set HttpClientHandler.UseProxy=false to disable automatic proxy detection. thanks @codeh 👍
  • #2943 Support non-string values for sort missing by introducing a MissingValue property. Deprecate Missing with ObsoleteAttribute and fix in 6.x.
  • #2913 Allow all sort options on fluent lambda API of TopHitsAggregation
  • #2843 Add track_scores to TopHitsAggregation

Bug Fixes

  • #2818 and #2976 Several issues related to representations of Time within the client, including fractional units
  • #2828 and #2962 Support DateMath for DateHistogram ExtendedBounds by introducing an ExtendedBoundsDateMath property of type ExtendedBounds<DateMath>
  • #2837 Added missing bool query filter visit on QueryWalker. thanks @jonyadamit 👍
  • #2849 Add Params property to pass params to the collate query for PhraseSuggestCollate. Document not to use Params on ITemplateQuery, but copy Params over if used.
  • #2864 and #2878 Append date_optional_time to Format when Missing is specified
  • #2871 and #2872 Deserialize error property on MultiGetResponse items
  • #2890 and #2957 Include similarity in index settings and add DFISimilarity
  • #2893 Correct serialized property name for preserve_original on AsciiFoldingTokenFilter
  • #2930 Do not capture synchronization context on async calls
  • #2886 Handle deserialization for a single or array of common words on CommonGramsTokenFilter. thanks @awelburn 👍
  • 9328a14 When pinging a node, use the PingTimeout for the request timeout. thanks @Vaibhav1192 👍
  • #2812 When marking a terms query as Verbatim where the terms is an empty collection, serialize to an empty array
  • #2816 Add overloaded constructor for AzureRepository so that GetRepository does not throw
  • #2817 Allow setting {dynamic_type} as part of the mapping using .Generic()

Deprecations

  • #2845 deprecate PreOffset and PostOffset and introduce Offset on IHistogramAggregation. thanks @jeroenkoknl 👍
  • #2913 Deprecate .Sort() on fluent lambda API of Top Hits aggregation that allows only field sorting.

Misc

  • 20b2606 Add documentation on how to configure JSON.Net Contract Converters
  • #2831 #2865 Resolve JSON.Net version and next major version from Nest.csproj, to fix NU1603 Warnings. thanks @kwilliamssbs 👍

View the full list of issues and PRs

6.0.0-beta1

15 Dec 06:08

Choose a tag to compare

6.0.0-beta1 Pre-release
Pre-release

Introduction

These beta packages have been released in order to solicit feedback from users. Like any beta software it should not be used in a production environment, if you do so it is very much at your own risk and we will be unable to support you.

These packages are designed to be used in conjunction with Elasticsearch 6.x

We are, however, very keen to field any issues that you may have. If you come across a problem please open an issue. Please ensure your issue mentions the 6.0.0-beta1 label.

Major changes

Serialization

The Newtonsoft.Json nuget dependency has been removed and the assembly has now been IL merged into the NEST assembly.

The reasons for this are two-fold:

  • It simplifies the deployment for customers - no more dependancies to manage.
  • It allows us to implement a specialised serialization pipeline in the future, without affecting users.

The Json.NET library has been completely internalized. All methods, properties, classes (etc) have been rewritten into the NEST assembly with internal scope and namespaces moved over to NEST.Json. It should not be possible to access any of the serialization functionality and it should coexist with Newtonsoft.Json references in your project.

Serialization Extensions

The new NEST.JsonNetSerializer package enables you to write a custom serialization path for the types you index into Elasticsearch using Json.NET.

This creates a new extension point within NEST for the serialization of your types.

Single Type Per Index

It is now only possible to have a single type per index, this change is more heavily documented here.

If you have multiple types in an index you'll need to move to a single type per index solution. If you can not do that straight away you can opt in to multiple types, for the time being, by using mapping.single_type index settings.

new IndexSettings(new Dictionary<string, object> {
	{ "mapping.single_type", "false" }
})
{
	NumberOfShards = 2,
	NumberOfReplicas = 0,
};

Breaking Changes

The breaking changes for Elasticsearch 5.x to 6.x are documented here and tracked here.

2.5.6

30 Oct 17:15

Choose a tag to compare

Fixes a property cache that was using GetHashCode() on MemberInfo as key. This could lead to wrong properties being serialized when hashcode collisions occurred. This only affects 2.x.

5.5.0

21 Jul 07:22

Choose a tag to compare

Features & Enhancements

  • #2775 Add remove_index operation to Alias operations.
  • #2795 Add missing fields on simple_query_string query.
  • #2807 Add XPack security role_mapping API to map roles to users, and a token based access API.
  • #2807 The matrix_stats, sig_terms and sampler_agg have additional properties.
  • #2807 Update tests.default.yaml ES version to 5.5.0
  • #2789 Add a StickySniffingConnectionPool - a new connection pool that combines the capabilities of the StickyConnectionPool and SniffingConnectionPools, and allowing for the sorting of the Node collection to be defined externally.
  • #2781 Improved exception message when backpressure does not leave room for the producer to call MoveNext().
  • #2781 Throw an exception when Reindex() produces just enough documents for a single bulk but leaves no slots to call MoveNext() which would free up an awaiting task (fixes #2771).
  • #2779 Can now parse exponential notation for milliseconds time units.

Breaking Changes

Bug Fixes

  • #2791 Use serializer when deserializing LazyDocument to T.
  • #2776 Ensure CancellationTokenRegistration is disposed of correctly.
  • #2780 Move EnterReadLock() outside of try block for SniffingConnectionPool.
  • #2785 Several fixes related to HttpClient + .NET Core + Linux

Deprecations

  • #2807 RefreshRequest fields force and operation_threading have been removed from ES 5.x (as per: elastic/elasticsearch#25234) so have been patched in as noop to preserve binary compatibility. Will be removed in 6.0.

View the full list of issues and PRs

6.0.0-alpha1

12 May 14:58

Choose a tag to compare

6.0.0-alpha1 Pre-release
Pre-release

This marks our first release completely integration tested against Elasticsearch 6.0.0-alpha1.

No big changes from 5.4.0 with the notable exception of

  • WatcherStatsResponse which has been reworked in Elasticsearch 6.0.0.
  • Support for the mapper-attachment plugin is gone (as its also removed from Elasticsearch 6.0.0)

If you have multiple types in a single index you'll need to move to a 1 type per index solution. If you can not do that straight away you can opt in to multiple types for the time being by using mapping.single_type index settings. For instance alpha1 does not come yet with an updated story for parent/child documents mandatory having to live in the same index.

new IndexSettings(new Dictionary<string, object> {
	{ "mapping.single_type", "false" }
})
{
	NumberOfShards = 2,
	NumberOfReplicas = 0,
};

5.4.0

10 May 10:56

Choose a tag to compare

Highlights: Elasticsearch 5.4 feature parity, we are now rolling with the new new csproj files for our builds.

Features & Enhancements

  • #2717 Moved to the new new csproj file. Which means we are now on VS2017 and up (or Rider of course!). There's a ton of infrastructure cleanup work behind this ticket.
  • #2659 Add stored_fields support to top hits aggregations (ty @V1tOr !)
  • #2702 Add support for time_zone in the date range aggregations (ty @adam-mccoy !)
  • #2746 Add support for missing highlight options as well as new options that have been introduced in 5.4
  • #2743 Add support for the new remote info API
  • #2745 Add support for the xpack info AND usage API
  • #2748 Expose num_reduce_phases on search (see elastic/elasticsearch#23288)
  • #2747 Expose word delimiter graph token filter
  • #2744 Add support for the source exists API
  • #2742 Add support for the field caps API

Bug Fixes

  • #2753 Timeouts on .NET core did not surface the same way they did as on full framework.
  • #2735 Do a double read for elasticsearch server errors for requests that can return a valid response for invalid http status codes (_reindex/_update_by_query)
  • #2740 reintroduce show_term_document_count_error which went blatently missing in 5.x
  • #2720 Dateformat.epoch_millis serialized a mispelled variant (ty @JefStat !)
  • #2721 Make sure we can handle fielddata in the old format when mappings are migrated from 2.x to 5.x
  • #2759 Fix HttpClient when used on CentOS, does not allow maxconnections to be set.
  • #2761 adjacent scripted metric aggregation responses failed to parse properly (ty @konbur)

For 6.0 we will rely on a new feauture in elasticsearch called typed_keys which will return aggregation names prefixed with type# which will completely replace the current heuristics based parser which should make parsing bugs less likely to creep in. (Although the current one has held up OK since 2.x).

2.5.5

10 May 11:16

Choose a tag to compare

Highlights: We are now rolling with the new new csproj files for our builds.

Features & Enhancements

  • #2717 Moved to the new new csproj file. Which means we are now on VS2017 and up (or Rider of course!). There's a ton of infrastructure cleanup work behind this ticket.
  • #2659 Add fields support to top hits aggregations (ty @V1tOr !)

Bug Fixes

  • #2753 Timeouts on .NET core did not surface the same way they did as on full framework.
  • #2735 Do a double read for elasticsearch server errors for requests that can return a valid response for invalid http status codes (_reindex/_update_by_query)
  • #2720 Dateformat.epoch_millis serialized a mispelled variant (ty @JefStat !)
  • #2759 Fix HttpClient when used on CentOS, does not allow maxconnections to be set.
  • #2761 adjacent scripted metric aggregation responses failed to parse properly (ty @konbur)