Null_pointer_exception 500 error

Please format your code using </> icon as explained in this guide. 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.