"Cannot read property 'group' of undefined" with MongoDB

Hi everyone, I'm currently testing Packetbeat, elasticsearch and Kibana with MongoDB queries. Everything seems to work fine, except that I have a fair amount of unexcpected "otherCommand" queries, and when I try to launch the "MongoDB Performance" dashboard nothing appears, except an error message : "Cannot read property 'group' of undefined". The problem appears even when there is no data in the "Discover" tab. Any help is welcomed.
Here's the log :

TypeError: Cannot read property 'group' of undefined
    at http://myserver:5601/index.js?_b=5930:118288:26
    at http://myserver:5601/index.js?_b=5930:35382:47
    at forEach (http://myserver:5601/index.js?_b=5930:34649:15)
    at Function.sortBy (http://myserver:5601/index.js?_b=5930:35377:7)
    at AggConfigsFactory.AggConfigs.getRequestAggs (http://myserver:5601/index.js?_b=5930:118287:16)
    at VisFactory.Vis.requesting (http://myserver:5601/index.js?_b=5930:118424:26)
    at http:/myserver:5601/index.js?_b=5930:148579:20
    at SearchSourceFactory.SearchSource._mergeProp (http://myserver:5601/index.js?_b=5930:44624:29)
    at ittr (http://myserver:5601/index.js?_b=5930:43445:27)
    at http://myserver:5601/index.js?_b=5930:34865:29

I'll move this over to Beats for now, hopefully the team there can help :slight_smile:

Can you somehow send us a sample of those "otherCommand"? I'd be curious to see what they are. We might be able to do a better job at figuring out what command it is.

I'm not sure about the JS error. Is it happening when you set a filter that doesn't match anything?

Hi tudor,

never mind about the otherCommands, they were created by a GUI client I was using with MongoDB.
The JS error appears when I try to load the full "MongoDB performance" dashboard that is available here : https://github.com/elastic/packetbeat-dashboards

I didn't set any filters, I just tried to load the dashboard.

EDIT : I found the panes that were causing the problem. Those are the panes "MongoDB response times by collection" and "Number of MongoDB transactions with writeConcern w=0". If I remove them from the dashboard, the data is displayed and I have no more errors.