damienbod / ElasticsearchCRUD

Elasticsearch .NET netstandard API
http://damienbod.com/2014/09/22/elasticsearch-crud-net-provider/
176 stars 49 forks source link

ElasticsearchString attribute appears to not work #154

Open tbrettallen opened 8 years ago

tbrettallen commented 8 years ago

I've decorated properties in a few of my classes with [ElasticsearchString(Index = StringIndex.not_analyzed)] on several of my classes, and when they're saved to Elasticsearch, the created index still marks them as analyzed.

Attempted to debug this myself, but could not find where this is checked anywhere in ElasticsearchCRUD. Is this feature not yet implemented?

damienbod commented 8 years ago

should be, I'll have a look, which version are you using?

greetings Damien

damienbod commented 8 years ago

works with the preview version and Elastic version number": "2.3.1", I checked the mapping and its not analyzed.

Maybe an attribute property is no longer supported.

https://github.com/damienbod/ElasticsearchCRUD/blob/master/ElasticsearchCrudAspNet5/src/ElasticsearchGermanAnalyzer/ElasticsearchProvider.cs#L85

hope this helps

greetings Damien

tbrettallen commented 8 years ago

Thanks! Elasticsearch 2.3.1 and was latest version of your code. It's a console application as I have an NServiceBus endpoint handling all elasticsearch updates.

That source file returns 404.

Which source files should I look at to reimplement this functionality?

I saw you've made changes since I've last looked at this. Was any of that related?

damienbod commented 8 years ago

sorry, I've updated to netstandard 1.4.

Usage: https://github.com/damienbod/ElasticsearchCRUD/blob/master/src/ElasticsearchGermanAnalyzer/ElasticsearchProvider.cs#L85

The console app is a demo which uses this.

The changes I made are just porting the application to netstandard 1.4, so from version 2.3.3.1 onwards, only net461 or higher is supported.

I would like to support net451, but its too much effort testing for both.

Greetings Damien

tbrettallen commented 8 years ago

I use 4.6.1 :)

I'll test the console app and if the non_analyzed option doesn't work still I'll use that to try to fix it. Thanks!

damienbod commented 8 years ago

Great, thanks