Comments (1)
Hi @gpetrou,
thanks again for testing the new version and reporting rough edges. That's super helpful 🙂
Semantics for Fields
and Field[]
are actually different. The specification defines Fields
as:
export type Fields = Field | Field[]
We call this a "single-or-many" construct. The ES server accepts the JSON property in a singular form "field"
and in an array form ["field", "..."]
.
Field[]
on the other hand, only accepts the array form.
The old generator incorrectly replaced Field[]
with Fields
which caused an issue with e.g. the stored_fields
that Steve tried to fix in #8018.
The current way of generating these properties is semantically correct, but a litte bit cumbersome to use. A proper fix that I've planned involves removing the [JsonConverter(typeof(FieldsConverter))]
attribute from the Fields
class. Afterwards, the generator will emit Field[]
properties using the Fields
type again, but dynamically places converter attributes on the properties - depending on the semantics (either FieldsConverter
or FieldArrayConverter
).
I expect to release this improvement already in the beginning of the next week.
from elasticsearch-net.
Related Issues (20)
- Cannot retrieve mapping of index with `icu_collation_keyword` field HOT 6
- cannot instantiate new DynamicTemplate when creating index. HOT 4
- Default index is not used in query with 8.13.15 client HOT 1
- Missing properties in aggregation API HOT 3
- Improve documentation for error handling
- Elastic.Transport.UnexpectedTransportException when calling elasticClient.MachineLearning.InferTrainedModelAsync HOT 1
- Support for using input_output option in inference processor
- CI: Automate reference documentation
- Intervals query is missing the option to set Field HOT 3
- Fluent API for composite aggregation sources
- IndexSettingsConverter tries to deserialize routing_path as collection of string even if there is a string in raw JSON response HOT 1
- ESQL Arrow support
- Implement Connectors API
- Add back TermsRangeQuery in the Elasticsearch .Net Client HOT 1
- error in elastic client when trying to get the mappings HOT 5
- Cannot run knn query using elasticClient.RequestResponseSerializer HOT 4
- Improve usability of `FiltersAggregation`
- Adding document to Elastic with Client.IndexAsync doesn't await result; also ambigious function parameters HOT 7
- ElasticsearchClient.Indicies.GetAsync throws UnexpectedTransportException
- IndexSettings NumberOfShards and NumberOfReplicas are objects, not int/long as expected HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from elasticsearch-net.