Skip to content
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

Make ignore_unmapped work for sorting cross-index queries. #7039

Closed
wants to merge 4 commits into from

Conversation

jpountz
Copy link
Contributor

@jpountz jpountz commented Jul 25, 2014

Close #2255

@jpountz jpountz added the review label Jul 28, 2014
@@ -36,7 +36,7 @@

private Object missing;

private Boolean ignoreUnmapped;
private Object ignoreUnmapped;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Was wondering why this is an Object rather then a String?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I added a setter with a String parameter but there was already also one with a boolean parameter. So I made the variable an object internally so that it can be either a Boolean or a String.

@markharwood
Copy link
Contributor

ignore_umapped still sounds like something that should be a boolean value.
Would unmapped_type be clearer?

Mapper.Builder<?, ?> builder = typeParser.parse(fieldName, ImmutableMap.<String, Object>of(), parserContext);
Settings indexSettings = context.indexShard().indexService().settingsService().getSettings();
BuilderContext builderContext = new BuilderContext(indexSettings, new ContentPath(1));
fieldMapper = (FieldMapper<?>) builder.build(builderContext);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can we maybe share these on an index level, instead of doing the whole build process over and over? just a set of static (index level) common types?

@jpountz
Copy link
Contributor Author

jpountz commented Jul 30, 2014

@areek @markharwood @kimchy Pushed new commits to address your concerns.

@kimchy
Copy link
Member

kimchy commented Aug 1, 2014

LGTM

@jpountz jpountz added v2.0.0 and removed review labels Aug 1, 2014
@jpountz jpountz closed this Aug 1, 2014
@jpountz jpountz deleted the fix/ignore_unmapped branch August 1, 2014 13:31
@clintongormley clintongormley added the :Search/Search Search-related issues that do not fall into other categories label Jun 7, 2015
@clintongormley clintongormley changed the title Sort: Make ignore_unmapped work for cross-index queries. Make ignore_unmapped work for sorting cross-index queries. Jun 7, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
>bug release highlight :Search/Search Search-related issues that do not fall into other categories v1.4.0.Beta1 v2.0.0-beta1
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Shard failures when searching multiple indices with a type filter and sort field
5 participants