Skip to content

Outdated Attribute Mapping Doc Page #3138

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
bbeda opened this issue Mar 19, 2018 · 8 comments
Closed

Outdated Attribute Mapping Doc Page #3138

bbeda opened this issue Mar 19, 2018 · 8 comments
Assignees

Comments

@bbeda
Copy link

bbeda commented Mar 19, 2018

This page' example is outdated.

https://www.elastic.co/guide/en/elasticsearch/client/net-api/current/attribute-mapping.html

  1. The [Object] attribute doesn't support Store=false
  2. It uses ElasticsearchType attribute with two type names which is not supported in ES6x
@russcam russcam self-assigned this Mar 20, 2018
@russcam
Copy link
Contributor

russcam commented Mar 20, 2018

@bbeda The documentation is generated from tests within the 6.x branch, so is up to date with 6.x source. With that said, this particular documentation page executes unit tests only.

The [Object] attribute doesn't support Store=false

ObjectAttribute inherits from ElasticsearchCorePropertyAttributeBase which has a Store property.

It uses ElasticsearchType attribute with two type names which is not supported in ES6x

You're correct, two document types within one index is not supported. Will update this now.

@russcam
Copy link
Contributor

russcam commented Mar 20, 2018

I've opened #3139 to address point 2

@bbeda
Copy link
Author

bbeda commented Mar 20, 2018

@russcam - I didn't investigate the 1st point. However, when I wanted to confirm that the usage of the two attributes by just copying the code snippet, when I ran it, it threw an exception for the Store property in the attribute, this is why I mentioned it.

@russcam
Copy link
Contributor

russcam commented Mar 20, 2018

No worries @bbeda, which version of NEST are you using?

@bbeda
Copy link
Author

bbeda commented Mar 20, 2018

I am using Nest 6.0.2 with Elasticsearch 6.2.2. I just ran it again, this is the error:
[1] BadResponse: Node: http://localhost:9200/ Took: 00:00:00.2702411 OriginalException: Elasticsearch.Net.ElasticsearchClientException: Request failed to execute. ServerError: Type: mapper_parsing_exception Reason: "Failed to parse mapping [company]: Mapping definition for [employees] has unsupported parameters: [store : false]" CausedBy: "Type: mapper_parsing_exception Reason: "Mapping definition for [employees] has unsupported parameters: [store : false]""

@russcam
Copy link
Contributor

russcam commented Mar 20, 2018

Ah gotcha! I've misunderstood the original issue, my apologies.

I'll look to address; this might be tricky because of the inheritance structure and not breaking binary compatibility. At the very least, I can remove it from the documentation

@bbeda
Copy link
Author

bbeda commented Mar 20, 2018

No problem @russcam . Yes, agreed
Thank you

russcam added a commit that referenced this issue Mar 21, 2018
* Remove multiple types per index from documentation

Closes #3138

* Remove usage of store on [Object] in docs

Add additional XML comments for property mappings
@russcam
Copy link
Contributor

russcam commented Mar 21, 2018

I've updated the docs for 6.x and these should be going live on the website documentation shortly. I've also opened #3145 to revisit the available options for each mapping datatype for 7.x

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants