ms = cores;
}
if (cores != null && cores.length > 0) {
StringBuffer buff=new StringBuffer();
for (int i = 0; i < cores.length; i++) {
ShardsList c = cores[i];
buff.append(c.randomGet() + "/solr/" + projectName
+ "@_mdrillshard_,");
// for (String part : partions) {
// rtn.urlShards += c.randomGet() + "/solr/" + projectName
// + "@" + part + ",";
// }
// count++;
}
rtn.urlShards=buff.toString();
}
if (ms != null && ms.length > 0) {
int count = 0;
int r = rdm.nextInt(ms.length);
int r2 = rdm.nextInt(cores.length);
for (ShardsList c : ms) {
if (count == r2) {
rtn.randomShard = c.randomGet() + "/solr/" + projectName;
}
if (count == r) {
rtn.urlMain = "http://" + c.randomGet() + "/solr/"
+ projectName;
}
rtn.urlMSs += c.randomGet() + "/solr/" + projectName + ",";
count++;
}
}
return rtn;