# Null\_pointer\_exception 500 error

**URL:** https://discuss.elastic.co/t/null-pointer-exception-500-error/102534
**Category:** Elasticsearch
**Created:** [October 3, 2017, 9:08am UTC](https://discuss.elastic.co/t/null-pointer-exception-500-error/102534 "2017-10-03T09:08:33Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![doshi\_darshan](https://avatars.discourse-cdn.com/v4/letter/d/a183cd/32.png) [@doshi\_darshan](https://discuss.elastic.co/u/doshi_darshan)
#### Post date: [October 3, 2017, 9:08am UTC](https://discuss.elastic.co/t/null-pointer-exception-500-error/102534/1 "2017-10-03T09:08:33Z")

</div>

I am getting below error in Heroku when i deployed my code. Please help me  
Heroku Redis : Redis Premium 0  
\<- 500  
{  
2017-10-03T07:51:58.485013+00:00 app[web.2]: "error": {  
2017-10-03T07:51:58.485014+00:00 app[web.2]: "root\_cause": [  
2017-10-03T07:51:58.485014+00:00 app[web.2]: {  
2017-10-03T07:51:58.485015+00:00 app[web.2]: "type": "null\_pointer\_exception",  
2017-10-03T07:51:58.485015+00:00 app[web.2]: "reason": null  
2017-10-03T07:51:58.485016+00:00 app[web.2]: }  
2017-10-03T07:51:58.485016+00:00 app[web.2]: ],  
2017-10-03T07:51:58.485017+00:00 app[web.2]: "type": "null\_pointer\_exception",  
2017-10-03T07:51:58.485018+00:00 app[web.2]: "reason": null  
2017-10-03T07:51:58.485018+00:00 app[web.2]: },  
2017-10-03T07:51:58.485019+00:00 app[web.2]: "status": 500  
2017-10-03T07:51:58.485020+00:00 app[web.2]: }  
2017-10-03T07:51:58.485020+00:00 app[web.2]:  
2017-10-03T07:51:58.485257+00:00 app[web.2]: Elasticsearch DEBUG: 2017-10-03T07:51:58Z  
2017-10-03T07:51:58.485259+00:00 app[web.2]: Request complete  
2017-10-03T07:51:58.485260+00:00 app[web.2]:  
2017-10-03T07:51:58.490556+00:00 app[web.2]: error: error: {"msg":"[null\_pointer\_exception] null","path":"/\_bulk","query":{},"body":"","statusCode":500,"response":"{"error":{"root\_cause":[{"type":"null\_pointer\_exception","reason":null}],"type":"null\_pointer\_exception","reason":null},"status":500}"} module=indexer.js

Setting for my indexer is below : [https://BONSAI](https://BONSAI) URL/searchindex/item/\_settings

{  
"analysis": {  
"char\_filter": {  
"replace": {  
"type": "mapping",  
"mappings": [  
"&=\> and "  
]  
}  
},  
"filter": {  
"word\_delimiter" : {  
"type" : "word\_delimiter",  
"split\_on\_numerics" : false,  
"split\_on\_case\_change" : true,  
"generate\_word\_parts" : true,  
"generate\_number\_parts" : true,  
"catenate\_all" : true,  
"preserve\_original":true,  
"catenate\_numbers":true  
}  
},  
"analyzer": {  
"default": {  
"type": "custom",  
"char\_filter": [  
"html\_strip",  
"replace"  
],  
"tokenizer": "whitespace",  
"filter": [  
"lowercase",  
"word\_delimiter"  
]  
}  
}  
}  
}  
Mapping for my indexer :  
[https://BONSAI](https://BONSAI) URL/searchindex/item/\_mapping

{  
"analysis": {  
"char\_filter": {  
"replace": {  
"type": "mapping",  
"mappings": [  
"&=\> and "  
]  
}  
},  
"filter": {  
"word\_delimiter" : {  
"type" : "word\_delimiter",  
"split\_on\_numerics" : false,  
"split\_on\_case\_change" : true,  
"generate\_word\_parts" : true,  
"generate\_number\_parts" : true,  
"catenate\_all" : true,  
"preserve\_original":true,  
"catenate\_numbers":true  
}  
},  
"analyzer": {  
"default": {  
"type": "custom",  
"char\_filter": [  
"html\_strip",  
"replace"  
],  
"tokenizer": "whitespace",  
"filter": [  
"lowercase",  
"word\_delimiter"  
]  
}  
}  
}  
}

---

<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: [October 3, 2017, 1:39pm UTC](https://discuss.elastic.co/t/null-pointer-exception-500-error/102534/2 "2017-10-03T13:39:40Z")

</div>

Please format your code using `</>` icon as explained in [this guide](https://discuss.elastic.co/t/about-the-elasticsearch-category/21). It will make your post more readable.

Or use markdown style like:

````
```
CODE
```

````

Your application is sending empty bulk request apparently. You need to fix your code I believe.

---

<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: [October 31, 2017, 1:40pm UTC](https://discuss.elastic.co/t/null-pointer-exception-500-error/102534/3 "2017-10-31T13:40:17Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
