This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"responseHeader":{ | |
"status":0, | |
"QTime":0, | |
"params":{ | |
"facet":"true", | |
"indent":"true", | |
"q":"*:*", | |
"facet.limit":"1", | |
"facet.field":["name", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
curl http://localhost:8983/solr/update -H 'Content-type:application/json' -d ' | |
[ | |
{ | |
"id": "1", | |
"title": "Doc 1" | |
}, | |
{ | |
"id": "2", | |
"title": "Doc 2" | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SourceOptions | |
XPath/RenderXSL | |
<response> | |
<lst name="responseHeader"> | |
<int name="status">500</int> | |
<int name="QTime">571882</int> | |
</lst> | |
<lst name="error"> | |
<str name="msg">KeeperErrorCode = Session expired for /overseer/collection-queue-work/qnr-0000000106</str> | |
<str name="trace">org.apache.zookeeper.KeeperException$SessionExpiredException: KeeperErrorCode = Session expired for /overseer/collection-queue-work/qnr-0000000106 at org.apache.zookeeper.KeeperException.create(KeeperException.java:127) at org.apache.zookeeper.KeeperException.create(KeeperException.java:51) at org.apache.zookeeper.ZooKeeper.getData(ZooKeeper.java:1155) at org.apache.solr.common.cloud.SolrZkClient$7.execute(SolrZkClient.java:276) at org.apache.solr.common.cloud.SolrZkClient$7.execute(SolrZkClient.java:273) at org.apache.solr.common.cloud.ZkCmdExecutor.retryOperation(ZkCmdExecutor.java:73) at org.apache.solr.common.cloud.SolrZkClient.getData(SolrZkClient.java:273) at org.apache.solr.cloud.DistributedQueue.offer(DistributedQueue.java:313 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-rw-r--r-- 1 varun wheel 162B Apr 29 17:29 _0.cfe | |
-rw-r--r-- 1 varun wheel 328B Apr 29 17:29 _0.cfs | |
-rw-r--r-- 1 varun wheel 259B Apr 29 17:29 _0.si | |
-rw-r--r-- 1 varun wheel 162B Apr 29 17:29 _1.cfe | |
-rw-r--r-- 1 varun wheel 1.7M Apr 29 17:29 _1.cfs | |
-rw-r--r-- 1 varun wheel 259B Apr 29 17:29 _1.si | |
-rw-r--r-- 1 varun wheel 162B Apr 29 17:29 _2.cfe | |
-rw-r--r-- 1 varun wheel 1.7M Apr 29 17:29 _2.cfs | |
-rw-r--r-- 1 varun wheel 259B Apr 29 17:29 _2.si | |
-rw-r--r-- 1 varun wheel 162B Apr 29 17:29 _3.cfe |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import org.apache.solr.client.solrj.impl.CloudSolrServer; | |
import org.apache.solr.client.solrj.request.UpdateRequest; | |
import org.apache.solr.common.SolrInputDocument; | |
import org.apache.solr.common.params.CoreAdminParams; | |
import java.net.MalformedURLException; | |
import java.util.Random; | |
import java.util.concurrent.ExecutorService; | |
import java.util.concurrent.Executors; | |
import java.util.concurrent.TimeUnit; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.test; | |
import java.util.List; | |
import java.util.ArrayList; | |
import org.apache.lucene.document.Field; | |
import org.apache.solr.common.SolrDocument; | |
import org.apache.solr.common.params.SolrParams; | |
import org.apache.solr.common.util.NamedList; | |
import org.apache.solr.request.SolrQueryRequest; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import org.apache.lucene.analysis.Analyzer; | |
import org.apache.lucene.analysis.standard.StandardAnalyzer; | |
import org.apache.lucene.codecs.Codec; | |
import org.apache.lucene.codecs.DocValuesFormat; | |
import org.apache.lucene.codecs.diskdv.DiskDocValuesFormat; | |
import org.apache.lucene.codecs.lucene42.Lucene42Codec; | |
import org.apache.lucene.codecs.lucene45.Lucene45DocValuesFormat; | |
import org.apache.lucene.codecs.lucene46.Lucene46Codec; | |
import org.apache.lucene.codecs.memory.DirectDocValuesFormat; | |
import org.apache.lucene.document.*; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.test; | |
import org.apache.lucene.queries.function.FunctionValues; | |
import org.apache.lucene.queries.function.ValueSource; | |
import org.apache.lucene.queries.function.valuesource.SimpleFloatFunction; | |
import org.apache.solr.common.util.NamedList; | |
import org.apache.solr.search.FunctionQParser; | |
import org.apache.solr.search.SyntaxError; | |
import org.apache.solr.search.ValueSourceParser; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.io.IOException; | |
import java.nio.charset.Charset; | |
import java.nio.file.Files; | |
import java.nio.file.Paths; | |
import java.nio.file.StandardOpenOption; | |
import java.util.ArrayList; | |
import java.util.List; | |
public class ParseWordNet { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
static String getBestCreateUrl(ZkStateReader zkStateReader, DownReplica badReplica, Integer maxCoreCount) { | |
assert badReplica != null; | |
assert badReplica.collection != null; | |
assert badReplica.slice != null; | |
Map<String,Counts> counts = new HashMap<>(); | |
ValueComparator vc = new ValueComparator(counts); | |
Set<String> liveNodes = new HashSet<>(zkStateReader.getClusterState().getLiveNodes()); | |
Map<String, Integer> coresPerNode = new HashMap<>(); |
OlderNewer