# The couchdb river ignores my mapping and creates a dynamic mapping

**URL:** <https://discuss.elastic.co/t/the-couchdb-river-ignores-my-mapping-and-creates-a-dynamic-mapping/11017>\
**Category:** Elasticsearch\
**Created:** [March 5, 2013, 3:31pm UTC](https://discuss.elastic.co/t/the-couchdb-river-ignores-my-mapping-and-creates-a-dynamic-mapping/11017 "2013-03-05T15:31:00Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Daniel\_Gonzalez](https://avatars.discourse-cdn.com/v4/letter/d/ecd19e/32.png) [@Daniel\_Gonzalez](https://discuss.elastic.co/u/Daniel_Gonzalez)\
**Post date:** [March 5, 2013, 3:31pm UTC](https://discuss.elastic.co/t/the-couchdb-river-ignores-my-mapping-and-creates-a-dynamic-mapping/11017/1 "2013-03-05T15:31:00Z")

</div>

Why can that be?

These are my commands:

# [2013-03-05T16:22:16.333515]

curl -XPUT '[http://rhea:9200/test1\_index\_name?pretty=true](http://rhea:9200/test1_index_name?pretty=true)'

# [2013-03-05T16:22:16.807981]

curl -XPUT  
'[http://rhea:9200/test1\_index\_name/test1\_mapping\_id/\_mapping?pretty=true](http://rhea:9200/test1_index_name/test1_mapping_id/_mapping?pretty=true)' -d  
'{"test1\_mapping\_id": {"dynamic": false, "properties": {"answer": {"index":  
"analyzed", "boost": 1.0, "type": "string", "store": "yes"}, "end":  
{"index": "analyzed", "boost": 1.0, "type": "string", "store": "yes"},  
"dialednum": {"index": "analyzed", "boost": 1.0, "type": "string", "store":  
"yes"}, "calldate": {"index": "analyzed", "boost": 1.0, "type": "string",  
"store": "yes"}, "clidnum": {"index": "analyzed", "boost": 1.0, "type":  
"string", "store": "yes"}}}}'

# [2013-03-05T16:22:16.957609]

curl -XPUT '[http://rhea:9200/\_river/test1\_index\_name/\_meta?pretty=true](http://rhea:9200/_river/test1_index_name/_meta?pretty=true)' -d '{"index":  
{"index": "test1\_index\_name", "type": "test1\_index\_type", "name":  
"test1\_index\_name", "bulk\_size": 100}, "couchdb": {"filter": null, "host":  
"localhost", "db": "cdr", "port": 20138}, "type": "couchdb"}'

And this is the log:

[2013-03-05 16:27:48,893][INFO][cluster.metadata] [Asmodeus] [  
test1\_index\_name] creating index, cause [api], shards [5]/[1], mappings []  
[2013-03-05 16:27:49,382][INFO][cluster.metadata] [Asmodeus] [  
test1\_index\_name] create\_mapping [test1\_mapping\_id]  
[2013-03-05 16:27:49,435][INFO][cluster.metadata] [Asmodeus] [  
\_river] creating index, cause [auto(index api)], shards [1]/[1], mappings []  
[2013-03-05 16:27:49,714][INFO][cluster.metadata] [Asmodeus] [  
\_river] update\_mapping [test1\_index\_name] (dynamic)  
[2013-03-05 16:27:49,770][INFO][river.couchdb] [Asmodeus] [  
couchdb][test1\_index\_name] starting couchdb stream: host [localhost], port [  
20138], filter [null], db [cdr], indexing to [test1\_index\_name]/[  
test1\_index\_ty  
[2013-03-05 16:27:49,773][INFO][cluster.metadata] [Asmodeus] [  
\_river] update\_mapping [test1\_index\_name] (dynamic)  
[2013-03-05 16:27:49,921][INFO][cluster.metadata] [Asmodeus] [  
\_river] update\_mapping [test1\_index\_name] (dynamic)  
[2013-03-05 16:27:49,936][INFO][cluster.metadata] [Asmodeus] [  
test1\_index\_name] update\_mapping [test1\_index\_type] (dynamic)  
[2013-03-05 16:27:49,980][INFO][cluster.metadata] [Asmodeus] [  
test1\_index\_name] update\_mapping [test1\_index\_type] (dynamic)  
[2013-03-05 16:27:53,679][INFO][cluster.metadata] [Asmodeus] [  
test1\_index\_name] update\_mapping [test1\_index\_type] (dynamic)  
[2013-03-05 16:27:53,704][INFO][cluster.metadata] [Asmodeus] [  
test1\_index\_name] update\_mapping [test1\_index\_type] (dynamic)  
[2013-03-05 16:27:53,707][INFO][cluster.metadata] [Asmodeus] [  
test1\_index\_name] update\_mapping [test1\_index\_type] (dynamic)  
[2013-03-05 16:27:54,354][INFO][cluster.metadata] [Asmodeus] [  
test1\_index\_name] update\_mapping [test1\_index\_type] (dynamic)  
[2013-03-05 16:27:55,406][DEBUG][action.bulk] [Asmodeus] [  
test1\_index\_name][2] failed to bulk item (index) index {[test1\_index\_name][  
test1\_index\_type][ee596d9d3bb846bfba6e9ac9e7c9d2db], source[{"calldate":  
"2011-08  
org.elasticsearch.index.mapper.MapperParsingException: Failed to parse  
[billsec]  
at  
org.elasticsearch.index.mapper.core.AbstractFieldMapper.parse(AbstractFieldMapper.java:308)  
at  
org.elasticsearch.index.mapper.object.ObjectMapper.serializeValue(ObjectMapper.java:577)  
at  
org.elasticsearch.index.mapper.object.ObjectMapper.parse(ObjectMapper.java:443)  
at  
org.elasticsearch.index.mapper.DocumentMapper.parse(DocumentMapper.java:475)  
at  
org.elasticsearch.index.mapper.DocumentMapper.parse(DocumentMapper.java:416)  
at  
org.elasticsearch.index.shard.service.InternalIndexShard.prepareIndex(InternalIndexShard.java:302)  
at  
org.elasticsearch.action.bulk.TransportShardBulkAction.shardOperationOnPrimary(TransportShardBulkAction.java:136)  
at  
org.elasticsearch.action.support.replication.TransportShardReplicationOperationAction$AsyncShardOperationAction.performOnPrimary(TransportShardReplicationOperationAction.java:487)  
at  
org.elasticsearch.action.support.replication.TransportShardReplicationOperationAction$AsyncShardOperationAction$1.run(TransportShardReplicationOperationAction.java:400)  
at  
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)

BR,  
Daniel

--  
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 [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

---

<div class="post-metadata">

**Author:** ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)\
**Post date:** [March 5, 2013, 5:05pm UTC](https://discuss.elastic.co/t/the-couchdb-river-ignores-my-mapping-and-creates-a-dynamic-mapping/11017/2 "2013-03-05T17:05:53Z")

</div>

Hi Daniel,

Try this:  
curl -XPUT '[http://rhea:9200/\_river/test1\_index\_name/\_meta?pretty=true](http://rhea:9200/_river/test1_index_name/_meta?pretty=true)' -d '{"index": {"index": "test1\_index\_name", "type": "test1\_mapping\_id", "name": "test1\_index\_name", "bulk\_size": 100}, "couchdb": {"filter": null, "host": "localhost", "db": "cdr", "port": 20138}, "type": "couchdb"}'

--  
David Pilato | Technical Advocate | [Elasticsearch.com](http://Elasticsearch.com)  
@dadoonet | @elasticsearchfr | @scrutmydocs

Le 5 mars 2013 à 16:31, Daniel Gonzalez [gonvaled@gmail.com](mailto:gonvaled@gmail.com) a écrit :

> Why can that be?
> 
> These are my commands:
> 
> # [2013-03-05T16:22:16.333515]
> 
> curl -XPUT '[http://rhea:9200/test1\_index\_name?pretty=true](http://rhea:9200/test1_index_name?pretty=true)'
> 
> # [2013-03-05T16:22:16.807981]
> 
> curl -XPUT '[http://rhea:9200/test1\_index\_name/test1\_mapping\_id/\_mapping?pretty=true](http://rhea:9200/test1_index_name/test1_mapping_id/_mapping?pretty=true)' -d '{"test1\_mapping\_id": {"dynamic": false, "properties": {"answer": {"index": "analyzed", "boost": 1.0, "type": "string", "store": "yes"}, "end": {"index": "analyzed", "boost": 1.0, "type": "string", "store": "yes"}, "dialednum": {"index": "analyzed", "boost": 1.0, "type": "string", "store": "yes"}, "calldate": {"index": "analyzed", "boost": 1.0, "type": "string", "store": "yes"}, "clidnum": {"index": "analyzed", "boost": 1.0, "type": "string", "store": "yes"}}}}'
> 
> # [2013-03-05T16:22:16.957609]
> 
> curl -XPUT '[http://rhea:9200/\_river/test1\_index\_name/\_meta?pretty=true](http://rhea:9200/_river/test1_index_name/_meta?pretty=true)' -d '{"index": {"index": "test1\_index\_name", "type": "test1\_index\_type", "name": "test1\_index\_name", "bulk\_size": 100}, "couchdb": {"filter": null, "host": "localhost", "db": "cdr", "port": 20138}, "type": "couchdb"}'
> 
> And this is the log:
> 
> [2013-03-05 16:27:48,893][INFO][cluster.metadata] [Asmodeus] [test1\_index\_name] creating index, cause [api], shards [5]/[1], mappings   
> [2013-03-05 16:27:49,382][INFO][cluster.metadata] [Asmodeus] [test1\_index\_name] create\_mapping [test1\_mapping\_id]  
> [2013-03-05 16:27:49,435][INFO][cluster.metadata] [Asmodeus] [\_river] creating index, cause [auto(index api)], shards [1]/[1], mappings   
> [2013-03-05 16:27:49,714][INFO][cluster.metadata] [Asmodeus] [\_river] update\_mapping [test1\_index\_name] (dynamic)  
> [2013-03-05 16:27:49,770][INFO][river.couchdb] [Asmodeus] [couchdb][test1\_index\_name] starting couchdb stream: host [localhost], port [20138], filter [null], db [cdr], indexing to [test1\_index\_name]/[test1\_index\_ty  
> [2013-03-05 16:27:49,773][INFO][cluster.metadata] [Asmodeus] [\_river] update\_mapping [test1\_index\_name] (dynamic)  
> [2013-03-05 16:27:49,921][INFO][cluster.metadata] [Asmodeus] [\_river] update\_mapping [test1\_index\_name] (dynamic)  
> [2013-03-05 16:27:49,936][INFO][cluster.metadata] [Asmodeus] [test1\_index\_name] update\_mapping [test1\_index\_type] (dynamic)  
> [2013-03-05 16:27:49,980][INFO][cluster.metadata] [Asmodeus] [test1\_index\_name] update\_mapping [test1\_index\_type] (dynamic)  
> [2013-03-05 16:27:53,679][INFO][cluster.metadata] [Asmodeus] [test1\_index\_name] update\_mapping [test1\_index\_type] (dynamic)  
> [2013-03-05 16:27:53,704][INFO][cluster.metadata] [Asmodeus] [test1\_index\_name] update\_mapping [test1\_index\_type] (dynamic)  
> [2013-03-05 16:27:53,707][INFO][cluster.metadata] [Asmodeus] [test1\_index\_name] update\_mapping [test1\_index\_type] (dynamic)  
> [2013-03-05 16:27:54,354][INFO][cluster.metadata] [Asmodeus] [test1\_index\_name] update\_mapping [test1\_index\_type] (dynamic)  
> [2013-03-05 16:27:55,406][DEBUG][action.bulk] [Asmodeus] [test1\_index\_name][2] failed to bulk item (index) index {[test1\_index\_name][test1\_index\_type][ee596d9d3bb846bfba6e9ac9e7c9d2db], source[{"calldate":"2011-08  
> org.elasticsearch.index.mapper.MapperParsingException: Failed to parse [billsec]  
> at org.elasticsearch.index.mapper.core.AbstractFieldMapper.parse(AbstractFieldMapper.java:308)  
> at org.elasticsearch.index.mapper.object.ObjectMapper.serializeValue(ObjectMapper.java:577)  
> at org.elasticsearch.index.mapper.object.ObjectMapper.parse(ObjectMapper.java:443)  
> at org.elasticsearch.index.mapper.DocumentMapper.parse(DocumentMapper.java:475)  
> at org.elasticsearch.index.mapper.DocumentMapper.parse(DocumentMapper.java:416)  
> at org.elasticsearch.index.shard.service.InternalIndexShard.prepareIndex(InternalIndexShard.java:302)  
> at org.elasticsearch.action.bulk.TransportShardBulkAction.shardOperationOnPrimary(TransportShardBulkAction.java:136)  
> at org.elasticsearch.action.support.replication.TransportShardReplicationOperationAction$AsyncShardOperationAction.performOnPrimary(TransportShardReplicationOperationAction.java:487)  
> at org.elasticsearch.action.support.replication.TransportShardReplicationOperationAction$AsyncShardOperationAction$1.run(TransportShardReplicationOperationAction.java:400)  
> at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
> 
> BR,  
> Daniel
> 
> --  
> 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 [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

--  
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 [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

---

<div class="post-metadata">

**Author:** ![Daniel\_Gonzalez](https://avatars.discourse-cdn.com/v4/letter/d/ecd19e/32.png) [@Daniel\_Gonzalez](https://discuss.elastic.co/u/Daniel_Gonzalez)\
**Post date:** [March 5, 2013, 9:06pm UTC](https://discuss.elastic.co/t/the-couchdb-river-ignores-my-mapping-and-creates-a-dynamic-mapping/11017/3 "2013-03-05T21:06:01Z")

</div>

Thanks, that worked!

On Tuesday, March 5, 2013 6:05:53 PM UTC+1, David Pilato wrote:

> Hi Daniel,
> 
> Try this:  
> curl -XPUT '[http://rhea:9200/\_river/test1\_index\_name/\_meta?pretty=true](http://rhea:9200/_river/test1_index_name/_meta?pretty=true)' -  
> d '{"index": {"index": "test1\_index\_name", "type": "_test1\_mapping\_id_",  
> "name": "test1\_index\_name", "bulk\_size": 100}, "couchdb": {"filter": null,  
> "host": "localhost", "db": "cdr", "port": 20138}, "type": "couchdb"}'
> 
> --  
> _David Pilato_ | _Technical Advocate_ | _[Elasticsearch.com](http://Elasticsearch.com)_  
> @dadoonet [https://twitter.com/dadoonet](https://twitter.com/dadoonet) | @elasticsearchfr[https://twitter.com/elasticsearchfr](https://twitter.com/elasticsearchfr)  
> | @scrutmydocs [https://twitter.com/scrutmydocs](https://twitter.com/scrutmydocs)
> 
> Le 5 mars 2013 à 16:31, Daniel Gonzalez \<[gonv...@gmail.com](mailto:gonv...@gmail.com) \<javascript:\>\>  
> a écrit :
> 
> Why can that be?
> 
> These are my commands:
> 
> # [2013-03-05T16:22:16.333515]
> 
> curl -XPUT '[http://rhea:9200/test1\_index\_name?pretty=true](http://rhea:9200/test1_index_name?pretty=true)'
> 
> # [2013-03-05T16:22:16.807981]
> 
> curl -XPUT '  
> [http://rhea:9200/test1\_index\_name/test1\_mapping\_id/\_mapping?pretty=true](http://rhea:9200/test1_index_name/test1_mapping_id/_mapping?pretty=true)' -d  
> '{"test1\_mapping\_id": {"dynamic": false, "properties": {"answer":  
> {"index": "analyzed", "boost": 1.0, "type": "string", "store": "yes"},  
> "end": {"index": "analyzed", "boost": 1.0, "type": "string", "store":  
> "yes"}, "dialednum": {"index": "analyzed", "boost": 1.0, "type": "string",  
> "store": "yes"}, "calldate": {"index": "analyzed", "boost": 1.0, "type":  
> "string", "store": "yes"}, "clidnum": {"index": "analyzed", "boost": 1.0,  
> "type": "string", "store": "yes"}}}}'
> 
> # [2013-03-05T16:22:16.957609]
> 
> curl -XPUT '[http://rhea:9200/\_river/test1\_index\_name/\_meta?pretty=true](http://rhea:9200/_river/test1_index_name/_meta?pretty=true)' -d  
> '{"index": {"index": "test1\_index\_name", "type": "test1\_index\_type",  
> "name": "test1\_index\_name", "bulk\_size": 100}, "couchdb": {"filter": null,  
> "host": "localhost", "db": "cdr", "port": 20138}, "type": "couchdb"}'
> 
> And this is the log:
> 
> [2013-03-05 16:27:48,893][INFO][cluster.metadata] [Asmodeus] [  
> test1\_index\_name] creating index, cause [api], shards [5]/[1], mappings   
> [2013-03-05 16:27:49,382][INFO][cluster.metadata] [Asmodeus] [  
> test1\_index\_name] create\_mapping [test1\_mapping\_id]  
> [2013-03-05 16:27:49,435][INFO][cluster.metadata] [Asmodeus] [  
> \_river] creating index, cause [auto(index api)], shards [1]/[1], mappings  
>   
> [2013-03-05 16:27:49,714][INFO][cluster.metadata] [Asmodeus] [  
> \_river] update\_mapping [test1\_index\_name] (dynamic)  
> [2013-03-05 16:27:49,770][INFO][river.couchdb] [Asmodeus] [  
> couchdb][test1\_index\_name] starting couchdb stream: host [localhost],port  
> [20138], filter [null], db [cdr], indexing to [test1\_index\_name]/[  
> test1\_index\_ty  
> [2013-03-05 16:27:49,773][INFO][cluster.metadata] [Asmodeus] [  
> \_river] update\_mapping [test1\_index\_name] (dynamic)  
> [2013-03-05 16:27:49,921][INFO][cluster.metadata] [Asmodeus] [  
> \_river] update\_mapping [test1\_index\_name] (dynamic)  
> [2013-03-05 16:27:49,936][INFO][cluster.metadata] [Asmodeus] [  
> test1\_index\_name] update\_mapping [test1\_index\_type] (dynamic)  
> [2013-03-05 16:27:49,980][INFO][cluster.metadata] [Asmodeus] [  
> test1\_index\_name] update\_mapping [test1\_index\_type] (dynamic)  
> [2013-03-05 16:27:53,679][INFO][cluster.metadata] [Asmodeus] [  
> test1\_index\_name] update\_mapping [test1\_index\_type] (dynamic)  
> [2013-03-05 16:27:53,704][INFO][cluster.metadata] [Asmodeus] [  
> test1\_index\_name] update\_mapping [test1\_index\_type] (dynamic)  
> [2013-03-05 16:27:53,707][INFO][cluster.metadata] [Asmodeus] [  
> test1\_index\_name] update\_mapping [test1\_index\_type] (dynamic)  
> [2013-03-05 16:27:54,354][INFO][cluster.metadata] [Asmodeus] [  
> test1\_index\_name] update\_mapping [test1\_index\_type] (dynamic)  
> [2013-03-05 16:27:55,406][DEBUG][action.bulk] [Asmodeus] [  
> test1\_index\_name][2] failed to bulk item (index) index {[test1\_index\_name  
> ][test1\_index\_type][ee596d9d3bb846bfba6e9ac9e7c9d2db], source[{"calldate":  
> "2011-08  
> org.elasticsearch.index.mapper.MapperParsingException: Failed to parse  
> [billsec]  
> at  
> org.elasticsearch.index.mapper.core.AbstractFieldMapper.parse(AbstractFieldMapper.java:308)  
> at  
> org.elasticsearch.index.mapper.object.ObjectMapper.serializeValue(ObjectMapper.java:577)  
> at  
> org.elasticsearch.index.mapper.object.ObjectMapper.parse(ObjectMapper.java:443)  
> at  
> org.elasticsearch.index.mapper.DocumentMapper.parse(DocumentMapper.java:475)  
> at  
> org.elasticsearch.index.mapper.DocumentMapper.parse(DocumentMapper.java:416)  
> at  
> org.elasticsearch.index.shard.service.InternalIndexShard.prepareIndex(InternalIndexShard.java:302)  
> at  
> org.elasticsearch.action.bulk.TransportShardBulkAction.shardOperationOnPrimary(TransportShardBulkAction.java:136)  
> at  
> org.elasticsearch.action.support.replication.TransportShardReplicationOperationAction$AsyncShardOperationAction.performOnPrimary(TransportShardReplicationOperationAction.java:487)  
> at  
> org.elasticsearch.action.support.replication.TransportShardReplicationOperationAction$AsyncShardOperationAction$1.run(TransportShardReplicationOperationAction.java:400)  
> at  
> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
> 
> BR,  
> Daniel
> 
> --  
> 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 [elasticsearc...@googlegroups.com](mailto:elasticsearc...@googlegroups.com) \<javascript:\>.  
> For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

--  
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 [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [July 6, 2017, 2:48am UTC](https://discuss.elastic.co/t/the-couchdb-river-ignores-my-mapping-and-creates-a-dynamic-mapping/11017/4 "2017-07-06T02:48:12Z")

</div>


