Ivan,
1) The multi_field type allows you to define different ways that a *single
field value* will be indexed. Your example below will work and will index a
single value as string/not_analyzed, and then as an int (use "integer" for
int)
2) The document coming in will contain a field named "name" with a single
value. When it goes into the index, it will be indexed 2 different ways.
3) A mapping is not required to index data. There is an implied default
mapping that will parse your JSON content and dynamically update the schema
if you don't specify one up-front.
4) You cannot change the shard count after the index is created. You can
change the replica count anytime. The PUT mapping API allows you to change
the replica count.
5) You can specify a single routing value for all documents that you want
to go to a specific shard/location.
6) The number of shards will allow you to scale your content later. So if
your data volume increases, you can add more nodes later and distribute the
shards around. If you only have a single shard and you run out of space,
then you cannot scale out unless you increase storage, or increase the
shard count.
7) Scroll is used to do a snapshot type of search - i.e., results you get
back will not be affected by updates to the index after you start
scrolling. From/size are useful if you want to do paging of search results
(or infinite scrolling but paged at a time).
8) Filters execute fast and yes can be cached.
On Monday, January 20, 2014 6:21:43 AM UTC-5, Ivan Ji wrote:
>
> Hi, all
>
> Recently, I am studying the ElasticSearch. I have several questions about
> it. Hope someone can answer me.
>
> (1) About the multi_field, can it store two type of fields ? such as..
>
> "tweet" : {
> "properties" : {
> "name" : {
> "type" : "multi_field",
> "fields" : {
> "name" : { "type" : "string", "index" : "not_analyzed" },
> "value" : { "type" : "int"}
>
> (2) if it can, what's the query format when post a new document? Could I
> explicit specify the value of these two fields? Or there are some type cast
> operations inside it?
>
> (3) Does there any default configuration file exist that configure the
> default schema mappings of the index and type? Does it only support REST
> API to create index/configure the mappings?
>
> (4)After I configured the number of shards/replicas and post many
> documents into it, can I re-configure it again? And how ? if so, what
> happened when the shard number increase? Do it cost a lots of performance?
>
> (5)About the routing, can I control the documents that must be sent to
> different shards? I know I can use the same routing value to index/search
> in the same shard. But could I control some documents which must be located
> in different shards of the other documents?
>
> (6) Assume I have only one node and one index, what's the difference
> between the size of shard is only one and ten of the same index? Does it
> cost extra memory if the shards size is ten? What's the suggested rule to
> decide this size?
>
> (7) What's the difference between setting the search_type to scroll and
> using the parameters(from/size)?
>
> (8) About the alias filtering, what's the cost about creating a alias
> filter? Are there any cache algorithms to accelerate these operations using
> the alias filter? Or it just append the extra filter condition of the
> filtered alias in the query?
>
>
> Sorry for the newbie questions, could you give me some opinion about these
> questions?
>
> Cheers,
>
> Ivan
>
--
You received this message because you are subscribed to the Google Groups
"elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/elasticsearch/2b4090fd-eb7d-4f92-acf5-6299d0b17d3b%40googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.