I am trying to determine the value of a complex array, but I keep getting values like 0,1,2,3,4,5 as answers.
Here is the code snippet I am using to retrieve the state value of the array:
var shardState = Object.keys(mydata.cluster.collections[collectionName].shards[String(shardName)].state);
alert(shardState);
Below is the representation of the array:
{
"responseHeader":{
"status":0,
"QTime":4},
"cluster":{
"collections":{
"college":{
"pullReplicas":"0",
"replicationFactor":"1",
"shards":{"shard1":{
"range":"80000000-7fffffff",
"state":"active",