Comments (6)
I think Sunspot at some point used #solr_index that was aliased to index if that wasn't defined already. This is a dead simple solution and it worked well for them. So I suggest doing that with elastic_search_index
being the canonical method name.
from retire.
Yeah, that's what @pacoguzman suggests in #9. There's no discussion it's the easiest, simplest way to accomplished the isolation.
I don't like the semantics of that, though. With tire_index
, or elasticsearch_index
, it still makes some sense. But what about tire_mapping
or elasticsearch_mapping
(and settings
)? This has nothing to do with Tire not ElasticSearch, but with the index corresponding to the model.
And then, what about eg. MyClass.percolate
? That would have to be also „prefixed”, for consistency... How would the source look like when all the Tire methods would be prefixed like this in a lame attempt of achieving isolation? How would the RDoc look like? Silly.
So, no easy answers here...
from retire.
Well, elastic_search_mapping
still has something to do with ES in my opinion because if you stop using ES or provide full-text search at all, that method won't be necessary. I think it is not one of those cases when readability or semantics are the most important properties. The goal is to avoid method conflicts and still keep names meaningful (to me that means "hinting at ES"). Going for readability is likely to yield a solution that will be significantly more complex and will take days to develop & fully test out.
from retire.
from retire.
So, @antares, it was a bit more of work in the end :), but I just could not have stand having a Tire::Model::Search::ClassMethods::es_search
and Tire::Model::Search::ClassMethods::es_index
and es_<WHATEVER>
in the source.
Many thanks to my guiding light @svenfuchs for keeping me on the straight path! :)
from retire.
haha :)
you're welcome, buddy
<3
from retire.
Related Issues (20)
- empty array HOT 2
- Elasticsearch 1.2.1, empty hash should be removed. HOT 5
- T
- Can I use regexp query via tire? HOT 1
- Persistence module does not provide updating a record. HOT 2
- "uninitialized constant" error on import rake task HOT 3
- Sort by field value other model (table)
- How can we use tire with multitenant app?
- Timeout option on activerecord? HOT 1
- Boost hits based on date HOT 2
- is there a way to use tire with zeus-parallel_tests?
- Custom Mapping on Hstore Columns
- Elasticsearch(0.90.9) failed to download 230K records(~80mb), with Tire gem(0.4.2).Below was the error message
- Elasticsearch(0.90.9) failed to download 230K records(~80mb), with Tire gem(0.4.2).Below was the error message
- import:all tasks: models load HOT 1
- Regarding nested query
- Support to `search_type: scan` HOT 1
- Ordering doesn't work without RoR shutdown HOT 1
- d
- Querying Association Trouble? HOT 1
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 retire.