buggy_function
stringlengths
1
391k
fixed_function
stringlengths
0
392k
public void testRollingUpdates() throws Exception { final MockDirectoryWrapper dir = newDirectory(); dir.setCheckIndexOnClose(false); // we use a custom codec provider final LineFileDocs docs = new LineFileDocs(random); //provider.register(new MemoryCodec()); if ( (!"Lucene3x".equals(Codec.getDef...
public void testRollingUpdates() throws Exception { final MockDirectoryWrapper dir = newDirectory(); dir.setCheckIndexOnClose(false); // we use a custom codec provider final LineFileDocs docs = new LineFileDocs(random, defaultCodecSupportsDocValues()); //provider.register(new MemoryCodec()); if (...
public void test() throws Exception { final LineFileDocs docs = new LineFileDocs(random); final Directory d = newDirectory(); final RandomIndexWriter w = new RandomIndexWriter(random, d); final int numDocs = atLeast(10); for(int docCount=0;docCount<numDocs;docCount++) { w.addDocument(docs.ne...
public void test() throws Exception { final LineFileDocs docs = new LineFileDocs(random, defaultCodecSupportsDocValues()); final Directory d = newDirectory(); final RandomIndexWriter w = new RandomIndexWriter(random, d); final int numDocs = atLeast(10); for(int docCount=0;docCount<numDocs;docCount...
public void test() throws Exception { final Directory d = newDirectory(); final MyIndexWriter w = new MyIndexWriter(d, newIndexWriterConfig(TEST_VERSION_CURRENT, new MockAnalyzer(random))); // Try to make an index that requires merging: w.getConfig().setMaxBufferedDocs(_TestUtil.nextInt(random, 2, 11...
public void test() throws Exception { final Directory d = newDirectory(); final MyIndexWriter w = new MyIndexWriter(d, newIndexWriterConfig(TEST_VERSION_CURRENT, new MockAnalyzer(random))); // Try to make an index that requires merging: w.getConfig().setMaxBufferedDocs(_TestUtil.nextInt(random, 2, 11...
private static void writeCapability(Capability c, Document doc, Element resource) throws IOException { logger.debug(LOG_ENTRY, "writeCapability", new Object[]{c, doc, resource}); Element capability = doc.createElement("capability"); capability.setAttribute("name", c.getName()); resource.appendChild...
private static void writeCapability(Capability c, Document doc, Element resource) throws IOException { logger.debug(LOG_ENTRY, "writeCapability", new Object[]{c, doc, resource}); Element capability = doc.createElement("capability"); capability.setAttribute("name", c.getName()); resource.appendChild...
private static void load() throws IOException { String file = Table.TableMetadata.getFileName(); File f = new File(file); if ( f.exists() ) { DataOutputBuffer bufOut = new DataOutputBuffer(); DataInputBuffer bufI...
private static void load() throws IOException { String file = Table.TableMetadata.getFileName(); File f = new File(file); if ( f.exists() ) { DataOutputBuffer bufOut = new DataOutputBuffer(); DataInputBuffer bufI...
private ColumnFamily getTopLevelColumns(QueryFilter filter, int gcBefore) { // we are querying top-level columns, do a merging fetch with indexes. List<IColumnIterator> iterators = new ArrayList<IColumnIterator>(); final ColumnFamily returnCF = ColumnFamily.create(table_, columnFamily_);...
private ColumnFamily getTopLevelColumns(QueryFilter filter, int gcBefore) { // we are querying top-level columns, do a merging fetch with indexes. List<IColumnIterator> iterators = new ArrayList<IColumnIterator>(); final ColumnFamily returnCF = ColumnFamily.create(table_, columnFamily_);...
protected User buildUser(String id, List<Preference> prefs) { if (!prefs.isEmpty() || prefs.get(0) instanceof BooleanPreference) { // If first is a BooleanPreference, assuming all are, so, want to use BooleanPrefUser FastSet<Object> itemIDs = new FastSet<Object>(prefs.size()); for (Preference pr...
protected User buildUser(String id, List<Preference> prefs) { if (!prefs.isEmpty() && prefs.get(0) instanceof BooleanPreference) { // If first is a BooleanPreference, assuming all are, so, want to use BooleanPrefUser FastSet<Object> itemIDs = new FastSet<Object>(prefs.size()); for (Preference pr...
public List<DecoratedKey> getSortedKeys() { assert !columnFamilies_.isEmpty(); logger_.info("Sorting " + this); List<DecoratedKey> keys = new ArrayList<DecoratedKey>(columnFamilies_.keySet()); Collections.sort(keys, partitioner_.getDecoratedKeyComparator()); return keys; ...
public List<DecoratedKey> getSortedKeys() { assert !columnFamilies_.isEmpty(); logger_.info("Sorting " + this); List<DecoratedKey> keys = new ArrayList<DecoratedKey>(columnFamilies_.keySet()); Collections.sort(keys); return keys; }
public int compareTo(IteratingRow o) { return partitioner.getDecoratedKeyComparator().compare(key, o.key); }
public int compareTo(IteratingRow o) { return key.compareTo(o.key); }
public int compare(String o1, String o2) { IPartitioner p = StorageService.getPartitioner(); return p.getDecoratedKeyComparator().compare(p.decorateKey(o1), p.decorateKey(o2)); } };
public int compare(String o1, String o2) { IPartitioner p = StorageService.getPartitioner(); return p.decorateKey(o1).compareTo(p.decorateKey(o2)); } };
private void validateRoleType(Role role, int roleType) throws IOException { if (role.getType() != roleType) { throw new IllegalArgumentException("Unexpected role type. Expected " + roleType + " but got " + role.getType()); } }
private void validateRoleType(Role role, int roleType) throws IOException { if (role.getType() != roleType) { throw new IOException("Unexpected role type. Expected " + roleType + " but got " + role.getType()); } }
public void boot(boolean create, Properties startParams) throws StandardException { jbmsVersion = Monitor.getMonitor().getEngineVersion(); dataDirectory = startParams.getProperty(PersistentService.ROOT); UUIDFactory uf = Monitor.getMonitor().getUUIDFactory(); identifier = uf.createUUID(); Persiste...
public void boot(boolean create, Properties startParams) throws StandardException { jbmsVersion = Monitor.getMonitor().getEngineVersion(); dataDirectory = startParams.getProperty(PersistentService.ROOT); UUIDFactory uf = Monitor.getMonitor().getUUIDFactory(); identifier = uf.createUUID(); Persiste...
public boolean validate(String key, Serializable value, Dictionary p) throws StandardException { if (value == null) return true; else if (key.equals(Property.DEFAULT_CONNECTION_MODE_PROPERTY)) { String value_s = (String)value; if (value_s != null && !StringUtil.SQLEqualsIgnoreCase(va...
public boolean validate(String key, Serializable value, Dictionary p) throws StandardException { if (value == null) return true; else if (key.equals(Property.DEFAULT_CONNECTION_MODE_PROPERTY)) { String value_s = (String)value; if (value_s != null && !StringUtil.SQLEqualsIgnoreCase(va...
private InputStream getAsStream(long generationId) throws StandardException { try { return fr.getAsStream(JarDDL.mkExternalName(schemaName, sqlName, fr.getSeparatorChar()), generationId); } catch (IOException ioe) { throw StandardException.newException(SQLState.LANG_FILE_ERROR, ioe.toString(),ioe); } }
private InputStream getAsStream(long generationId) throws StandardException { try { return fr.getAsStream(JarDDL.mkExternalName(schemaName, sqlName, fr.getSeparatorChar()), generationId); } catch (IOException ioe) { throw StandardException.newException(SQLState.LANG_FILE_ERROR, ioe, ioe.toString()); } }
public Object readJarFile(String schemaName, String sqlName) throws StandardException { DataDictionaryContext ddc = (DataDictionaryContext) ContextService.getContext(DataDictionaryContext.CONTEXT_ID); DataDictionary dd = ddc.getDataDictionary(); SchemaDescriptor sd = dd.getSchemaDescriptor(schemaName, nul...
public Object readJarFile(String schemaName, String sqlName) throws StandardException { DataDictionaryContext ddc = (DataDictionaryContext) ContextService.getContext(DataDictionaryContext.CONTEXT_ID); DataDictionary dd = ddc.getDataDictionary(); SchemaDescriptor sd = dd.getSchemaDescriptor(schemaName, nul...
private void updateStatistics() throws StandardException { ConglomerateDescriptor[] cds; td = dd.getTableDescriptor(tableId); if (updateStatisticsAll) { cds = td.getConglomerateDescriptors(); } else { cds = new ConglomerateDescriptor[1]; ...
private void updateStatistics() throws StandardException { ConglomerateDescriptor[] cds; td = dd.getTableDescriptor(tableId); if (updateStatisticsAll) { cds = null; } else { cds = new ConglomerateDescriptor[1]; cds[0] = dd.getConglomer...
public void command() {} }); if (line.getOptionValue(CMD).equals(BOOTSTRAP)) { if (!line.hasOption(SOLRHOME)) { System.out.println("-" + SOLRHOME + " is required for " + BOOTSTRAP); System.exit(1); } CoreCo...
public void command() {} }); if (line.getOptionValue(CMD).equals(BOOTSTRAP)) { if (!line.hasOption(SOLRHOME)) { System.out.println("-" + SOLRHOME + " is required for " + BOOTSTRAP); System.exit(1); } CoreCo...
public static void checkXATransactionView(Connection conn,String[][] expectedRows) throws SQLException { Statement s = conn.createStatement(); ResultSet rs = s.executeQuery( "select * from XATESTUTIL.global_xactTable where gxid is not null order by gxid"); if (expectedRow...
public static void checkXATransactionView(Connection conn,String[][] expectedRows) throws SQLException { Statement s = conn.createStatement(); ResultSet rs = s.executeQuery( "select * from XATESTUTIL.global_xactTable where gxid is not null order by gxid"); if (expectedRow...
public ReadResponseResolver(String table, int responseCount) { assert 1 <= responseCount && responseCount <= DatabaseDescriptor.getReplicationFactor() : "invalid response count " + responseCount; this.responseCount = responseCount; this.table = table; }
public ReadResponseResolver(String table, int responseCount) { assert 1 <= responseCount && responseCount <= DatabaseDescriptor.getReplicationFactor(table) : "invalid response count " + responseCount; this.responseCount = responseCount; this.table = table; }
public void printRing(PrintStream outs) { Map<Range, List<String>> rangeMap = probe.getRangeToEndPointMap(); List<Range> ranges = new ArrayList<Range>(rangeMap.keySet()); Collections.sort(ranges); Set<String> liveNodes = probe.getLiveNodes(); Set<String> deadNodes = probe...
public void printRing(PrintStream outs) { Map<Range, List<String>> rangeMap = probe.getRangeToEndPointMap(null); List<Range> ranges = new ArrayList<Range>(rangeMap.keySet()); Collections.sort(ranges); Set<String> liveNodes = probe.getLiveNodes(); Set<String> deadNodes = p...
private void doCleanupCompaction(ColumnFamilyStore cfs) throws IOException { Collection<SSTableReader> originalSSTables = cfs.getSSTables(); List<SSTableReader> sstables = doAntiCompaction(cfs, originalSSTables, StorageService.instance.getLocalRanges(), null); if (!sstables.isEmpty()) ...
private void doCleanupCompaction(ColumnFamilyStore cfs) throws IOException { Collection<SSTableReader> originalSSTables = cfs.getSSTables(); List<SSTableReader> sstables = doAntiCompaction(cfs, originalSSTables, StorageService.instance.getLocalRanges(cfs.getTable().name), null); if (!sst...
public void doVerb(Message message) { byte[] body = message.getMessageBody(); /* Obtain a Read Context from TLS */ ReadContext readCtx = tls_.get(); if ( readCtx == null ) { readCtx = new ReadContext(); tls_.set(readCtx); } readCtx....
public void doVerb(Message message) { byte[] body = message.getMessageBody(); /* Obtain a Read Context from TLS */ ReadContext readCtx = tls_.get(); if ( readCtx == null ) { readCtx = new ReadContext(); tls_.set(readCtx); } readCtx....
private static boolean sendMessage(InetAddress endPoint, String tableName, String key) throws IOException { if (!Gossiper.instance.isKnownEndpoint(endPoint)) { logger_.warn("Hints found for endpoint " + endPoint + " which is not part of the gossip network. discarding."); ...
private static boolean sendMessage(InetAddress endPoint, String tableName, String key) throws IOException { if (!Gossiper.instance.isKnownEndpoint(endPoint)) { logger_.warn("Hints found for endpoint " + endPoint + " which is not part of the gossip network. discarding."); ...
public void doVerb(Message message) { if (logger_.isDebugEnabled()) logger_.debug("Received a StreamRequestMessage from " + message.getFrom()); byte[] body = message.getMessageBody(); ByteArrayInputStream bufIn = new ByteArrayInputStream(body); try { ...
public void doVerb(Message message) { if (logger_.isDebugEnabled()) logger_.debug("Received a StreamRequestMessage from " + message.getFrom()); byte[] body = message.getMessageBody(); ByteArrayInputStream bufIn = new ByteArrayInputStream(body); try { ...
private static List<Node> retrieveRingData(String seedAddress, String remoteHost, int port) throws IOException { JMXServiceURL jmxUrl = new JMXServiceURL(String.format(fmtUrl, remoteHost, port)); JMXConnector jmxc = JMXConnectorFactory.connect(jmxUrl, null); StorageServiceMBean ssProxy; ...
private static List<Node> retrieveRingData(String seedAddress, String remoteHost, int port) throws IOException { JMXServiceURL jmxUrl = new JMXServiceURL(String.format(fmtUrl, remoteHost, port)); JMXConnector jmxc = JMXConnectorFactory.connect(jmxUrl, null); StorageServiceMBean ssProxy; ...
public NamedVector(Vector delegate, String name) { if (delegate == null) { throw new IllegalArgumentException(); } this.delegate = delegate; this.name = name; }
public NamedVector(Vector delegate, String name) { if (delegate == null || name == null) { throw new IllegalArgumentException(); } this.delegate = delegate; this.name = name; }
public static UUID getLastMigrationId() { Table defs = Table.open(Table.DEFINITIONS); ColumnFamilyStore cfStore = defs.getColumnFamilyStore(SCHEMA_CF); QueryFilter filter = QueryFilter.getNamesFilter(LAST_MIGRATION_KEY, new QueryPath(SCHEMA_CF), LAST_MIGRATION_KEY.getBytes()); Co...
public static UUID getLastMigrationId() { Table defs = Table.open(Table.DEFINITIONS); ColumnFamilyStore cfStore = defs.getColumnFamilyStore(SCHEMA_CF); QueryFilter filter = QueryFilter.getNamesFilter(LAST_MIGRATION_KEY, new QueryPath(SCHEMA_CF), LAST_MIGRATION_KEY.getBytes()); Co...
public Object call() throws Exception { latch.await(); return null; } }); // Open the searcher *before* the update handler so we don't end up opening // one in the middle. // With lockless commits in Lucene now, this probably shouldn't be an issue anymore ...
public Object call() throws Exception { latch.await(); return null; } }); // Open the searcher *before* the update handler so we don't end up opening // one in the middle. // With lockless commits in Lucene now, this probably shouldn't be an issue anymore ...
private TypeDescriptor typeDescriptorWithCorrectCollation(TypeDescriptor changeTD) throws StandardException { TypeId compTypeId = TypeId.getBuiltInTypeId(changeTD.getTypeName()); //No work to do if type id does not correspond to a character string if (compTypeId != null && compTypeId.isStringTypeId()) { Data...
private TypeDescriptor typeDescriptorWithCorrectCollation(TypeDescriptor changeTD) throws StandardException { TypeId compTypeId = TypeId.getBuiltInTypeId(changeTD.getTypeName()); //No work to do if type id does not correspond to a character string if (compTypeId != null && compTypeId.isStringTypeId()) { Data...
private AtomicInteger id = new AtomicInteger(); static { // no ssl currently because distrib updates read scheme from zk and no zk in this test sslConfig = null; }
private AtomicInteger id = new AtomicInteger(); static { // no ssl currently because distrib updates read scheme from zk and no zk in this test ALLOW_SSL = false; }
private static final String CONF_DIR = "solr" + File.separator + "collection1" + File.separator + "conf" + File.separator; JettySolrRunner masterJetty, slaveJetty, repeaterJetty; SolrServer masterClient, slaveClient, repeaterClient; SolrInstance master = null, slave = null, repeater = null; stat...
private static final String CONF_DIR = "solr" + File.separator + "collection1" + File.separator + "conf" + File.separator; JettySolrRunner masterJetty, slaveJetty, repeaterJetty; SolrServer masterClient, slaveClient, repeaterClient; SolrInstance master = null, slave = null, repeater = null; stat...
private void supportIJProperties(ConnectionEnv env) { //check if the property is set to not show select count and set the static variable //accordingly. boolean showNoCountForSelect = Boolean.valueOf(util.getSystemProperty("ij.showNoCountForSelect")).booleanValue(); JDBCDisplayUtil.showSele...
private void supportIJProperties(ConnectionEnv env) { //check if the property is set to not show select count and set the static variable //accordingly. boolean showNoCountForSelect = Boolean.valueOf(util.getSystemProperty("ij.showNoCountForSelect")).booleanValue(); JDBCDisplayUtil.setShowS...
public void addPosition(int position, BytesRef payload) throws IOException { assert !omitTF; final int delta = position - lastPosition; assert delta > 0 || position == 0: "position=" + position + " lastPosition=" + lastPosition; // not quite right (if pos=0 is repeated twice we don't catch it)...
public void addPosition(int position, BytesRef payload) throws IOException { assert !omitTF; final int delta = position - lastPosition; assert delta >= 0: "position=" + position + " lastPosition=" + lastPosition; // not quite right (if pos=0 is repeated twice we don't catch it) lastPositio...
public void addPosition(int position, BytesRef payload) throws IOException { //System.out.println("StandardW: addPos pos=" + position + " payload=" + (payload == null ? "null" : (payload.length + " bytes")) + " proxFP=" + proxOut.getFilePointer()); assert !omitTermFreqAndPositions: "omitTermFreqAndPositio...
public void addPosition(int position, BytesRef payload) throws IOException { //System.out.println("StandardW: addPos pos=" + position + " payload=" + (payload == null ? "null" : (payload.length + " bytes")) + " proxFP=" + proxOut.getFilePointer()); assert !omitTermFreqAndPositions: "omitTermFreqAndPositio...
private Cassandra.Client getClient() throws TTransportException { TTransport tr = new TSocket("localhost", 9170); TProtocol proto = new TBinaryProtocol(tr); Cassandra.Client client = new Cassandra.Client(proto); tr.open(); return client; }
private Cassandra.Client getClient() throws TTransportException { TTransport tr = new TSocket("localhost", DatabaseDescriptor.getRpcPort()); TProtocol proto = new TBinaryProtocol(tr); Cassandra.Client client = new Cassandra.Client(proto); tr.open(); return client; }
public SystemColumn[] buildColumnList() { SystemColumn[] columnList = new SystemColumn[SYSVIEWS_COLUMN_COUNT]; columnList[0] = new SystemColumnImpl( convertIdCase( "TABLEID"), // name SYSVIEWS_TABLEID, // column number 0, // precision 0, // scale false, // null...
public SystemColumn[] buildColumnList() { SystemColumn[] columnList = new SystemColumn[SYSVIEWS_COLUMN_COUNT]; columnList[0] = new SystemColumnImpl( convertIdCase( "TABLEID"), // name SYSVIEWS_TABLEID, // column number 0, // precision 0, // scale false, // null...
public void boot(boolean create, Properties startParams) throws StandardException { softwareVersion = new DD_Version(this, DataDictionary.DD_VERSION_DERBY_10_2); /* There is a bootstrapping problem here. We would like to use * a language connection context to find the name of the system and default ...
public void boot(boolean create, Properties startParams) throws StandardException { softwareVersion = new DD_Version(this, DataDictionary.DD_VERSION_DERBY_10_3); /* There is a bootstrapping problem here. We would like to use * a language connection context to find the name of the system and default ...
public void test_errorcode() throws Exception { ResultSet rs = null; Statement s = createStatement(); s.executeUpdate( "create table t(i int, s smallint)"); s.executeUpdate( "insert into t values (1,2)"); s.executeUpdate("insert i...
public void test_errorcode() throws Exception { ResultSet rs = null; Statement s = createStatement(); s.executeUpdate( "create table t(i int, s smallint)"); s.executeUpdate( "insert into t values (1,2)"); s.executeUpdate("insert i...
private void doDelete(DeleteUpdateCommand cmd, List<Node> nodes, ModifiableSolrParams params) { flushAdds(1); DeleteUpdateCommand clonedCmd = clone(cmd); DeleteRequest deleteRequest = new DeleteRequest(); deleteRequest.cmd = clonedCmd; deleteRequest.params = params; for (Node n...
private void doDelete(DeleteUpdateCommand cmd, List<Node> nodes, ModifiableSolrParams params) { flushAdds(1); DeleteUpdateCommand clonedCmd = clone(cmd); DeleteRequest deleteRequest = new DeleteRequest(); deleteRequest.cmd = clonedCmd; deleteRequest.params = params; for (Node n...
@Override public int advance(int target) throws IOException { return doc = target <= 3000 ? 3000 : NO_MORE_DOCS; } }}; BooleanScorer bs = new BooleanScorer(sim, 1, Arrays.asList(scorers), null); assertEquals("should have received 3000", 3000, bs.nextDoc()); assertEquals("...
@Override public int advance(int target) throws IOException { return doc = target <= 3000 ? 3000 : NO_MORE_DOCS; } }}; BooleanScorer bs = new BooleanScorer(sim, 1, Arrays.asList(scorers), null, scorers.length); assertEquals("should have received 3000", 3000, bs.nextDoc()); ...
public void clearUnsafe() { columnFamilies_.clear(); }
public void remove() { throw new UnsupportedOperationException(); } }; } void clearUnsafe() { columnFamilies_.clear(); }
public int numFeatures() { return userFeatures[0].length; }
public int numFeatures() { return userFeatures.length > 0 ? userFeatures[0].length : 0; }
public static String string(ByteBuffer buffer, int offset, int length, Charset charset) { if (buffer.hasArray()) return new String(buffer.array(), buffer.arrayOffset() + offset, length + buffer.arrayOffset(), charset); byte[] buff = getArray(buffer, offset, length); return n...
public static String string(ByteBuffer buffer, int offset, int length, Charset charset) { if (buffer.hasArray()) return new String(buffer.array(), buffer.arrayOffset() + offset, length, charset); byte[] buff = getArray(buffer, offset, length); return new String(buff, charset...
public DecoratedKey<BigIntegerToken> convertFromDiskFormat(ByteBuffer fromdisk) { // find the delimiter position int splitPoint = -1; for (int i = fromdisk.position(); i < fromdisk.limit(); i++) { if (fromdisk.get(i) == DELIMITER_BYTE) { sp...
public DecoratedKey<BigIntegerToken> convertFromDiskFormat(ByteBuffer fromdisk) { // find the delimiter position int splitPoint = -1; for (int i = fromdisk.position(); i < fromdisk.limit(); i++) { if (fromdisk.get(i) == DELIMITER_BYTE) { sp...
public static synchronized Collection<KSMetaData> loadFromStorage(UUID version) throws IOException { DecoratedKey vkey = StorageService.getPartitioner().decorateKey(Migration.toUTF8Bytes(version)); Table defs = Table.open(Table.SYSTEM_TABLE); ColumnFamilyStore cfStore = defs.getColumnFam...
public static synchronized Collection<KSMetaData> loadFromStorage(UUID version) throws IOException { DecoratedKey vkey = StorageService.getPartitioner().decorateKey(Migration.toUTF8Bytes(version)); Table defs = Table.open(Table.SYSTEM_TABLE); ColumnFamilyStore cfStore = defs.getColumnFam...
public void apply() throws IOException { // We need to transform all CounterUpdateColumn to CounterColumn and we need to deepCopy. Both are done // below since CUC.asCounterColumn() does a deep copy. RowMutation rm = new RowMutation(rowMutation.getTable(), ByteBufferUtil.clone(rowMutati...
public void apply() throws IOException { // We need to transform all CounterUpdateColumn to CounterColumn and we need to deepCopy. Both are done // below since CUC.asCounterColumn() does a deep copy. RowMutation rm = new RowMutation(rowMutation.getTable(), ByteBufferUtil.clone(rowMutati...
public void close() { this.isClosed = true; syncStrategy.close(); } /* * weAreReplacement: has someone else been the leader already? */ @Override void runLeaderProcess(boolean weAreReplacement) throws KeeperException, InterruptedException, IOException { log.info("Running the leade...
public void close() { this.isClosed = true; syncStrategy.close(); } /* * weAreReplacement: has someone else been the leader already? */ @Override void runLeaderProcess(boolean weAreReplacement) throws KeeperException, InterruptedException, IOException { log.info("Running the leade...
protected void handleRequestSyncAction(SolrQueryRequest req, SolrQueryResponse rsp) throws IOException { final SolrParams params = req.getParams(); log.info("I have been requested to sync up my shard"); ZkController zkController = coreContainer.getZkController(); if (zkController == null) { ...
protected void handleRequestSyncAction(SolrQueryRequest req, SolrQueryResponse rsp) throws IOException { final SolrParams params = req.getParams(); log.info("I have been requested to sync up my shard"); ZkController zkController = coreContainer.getZkController(); if (zkController == null) { ...
public boolean acceptsURL(String url) throws SQLException { // // We don't want to accidentally boot the engine just because // the application is looking for a connection from some other // driver. // return ( isBooted() && InternalDriver.embeddedDriverAcceptsURL(url) ); }
public boolean acceptsURL(String url) throws SQLException { // // We don't want to accidentally boot the engine just because // the application is looking for a connection from some other // driver. // return InternalDriver.embeddedDriverAcceptsURL(url); }
public String toString() { if (cachedString == null) { cachedString = ccsidManager.convertToUCS2(buffer); } return cachedString; }
public String toString() { if (cachedString == null) { cachedString = ccsidManager.convertToJavaString(buffer); } return cachedString; }
private void nonDbaTest() throws Exception { String reservedToDBO = "2850A"; Connection conn = openUserConnection( NON_DBO_USER ); assertTrue( "Initially, should be able to read property.", canReadProperty() ); // Now prove that the non-DBO can't reload the po...
private void nonDbaTest() throws Exception { String reservedToDBO = "42504"; Connection conn = openUserConnection( NON_DBO_USER ); assertTrue( "Initially, should be able to read property.", canReadProperty() ); // Now prove that the non-DBO can't reload the po...
public SQLException getSQLException (String message, String sqlState, int errCode) { SQLException ex = null; if (sqlState == null) { ex = new SQLException(message, sqlState, errCode); } else if (sqlState.startsWith(SQ...
public SQLException getSQLException (String message, String sqlState, int errCode) { SQLException ex = null; if (sqlState == null) { ex = new SQLException(message, sqlState, errCode); } else if (sqlState.startsWith(SQ...
public SQLException getSQLException(String message, String messageId, SQLException next, int severity, Throwable t, Object[] args) { String sqlState = StandardException.getSQLStateFromIdentifier(messageId); // // Create dummy exception which ferries arguments needed to serialize // SQLExc...
public SQLException getSQLException(String message, String messageId, SQLException next, int severity, Throwable t, Object[] args) { String sqlState = StandardException.getSQLStateFromIdentifier(messageId); // // Create dummy exception which ferries arguments needed to serialize // SQLExc...
public IntermediateFacetResult fetchPartitionResult(FacetArrays arrays, int offset) throws IOException { // get the root of the result tree to be returned, and the depth of that result tree // (depth means number of node levels excluding the root). int rootNode = this.taxonomyReader.getOrdinal(this.face...
public IntermediateFacetResult fetchPartitionResult(FacetArrays arrays, int offset) throws IOException { // get the root of the result tree to be returned, and the depth of that result tree // (depth means number of node levels excluding the root). int rootNode = this.taxonomyReader.getOrdinal(this.face...
protected boolean isSelfPartition (int ordinal, FacetArrays facetArrays, int offset) { int partitionSize = facetArrays.getArraysLength(); return ordinal / partitionSize == offset / partitionSize; }
protected boolean isSelfPartition (int ordinal, FacetArrays facetArrays, int offset) { int partitionSize = facetArrays.arrayLength; return ordinal / partitionSize == offset / partitionSize; }
protected Weight createWeight(Searcher searcher) { return new SpanWeight(this, searcher); } }
protected Weight createWeight(Searcher searcher) throws IOException { return new SpanWeight(this, searcher); } }
public Collection<ModelledResource> resolve(String appName, String appVersion, Collection<ModelledResource> byValueBundles, Collection<Content> inputs) throws ResolverException { log.debug(LOG_ENTRY, "resolve", new Object[]{appName, appVersion,byValueBundles, inputs}); Collection<ImportedBundle> imp...
public Collection<ModelledResource> resolve(String appName, String appVersion, Collection<ModelledResource> byValueBundles, Collection<Content> inputs) throws ResolverException { log.debug(LOG_ENTRY, "resolve", new Object[]{appName, appVersion,byValueBundles, inputs}); Collection<ImportedBundle> imp...
public static IStemmer createStemmer() { try { return new LuceneStemmerAdapter(); } catch (Throwable e) { return IdentityStemmer.INSTANCE; } } }
public static IStemmer createStemmer() { try { return new LuceneStemmerAdapter(); } catch (Exception e) { return IdentityStemmer.INSTANCE; } } }
private void buildDocument(VariableResolver vr, DocWrapper doc, Map<String, Object> pk, EntityProcessorWrapper epw, boolean isRoot, ContextImpl parentCtx, List<EntityProcessorWrapper> entitiesToDestroy) { ContextImpl ctx = new ContextImpl(epw, vr, null, ...
private void buildDocument(VariableResolver vr, DocWrapper doc, Map<String, Object> pk, EntityProcessorWrapper epw, boolean isRoot, ContextImpl parentCtx, List<EntityProcessorWrapper> entitiesToDestroy) { ContextImpl ctx = new ContextImpl(epw, vr, null, ...
public Map<String, Object> readIndexerProperties() { Properties props = new Properties(); try { byte[] data = zkClient.getData(path, null, null, false); if (data != null) { props.load(new StringReader(new String(data, "UTF-8"))); } } catch (Throwable e) { log.warn( ...
public Map<String, Object> readIndexerProperties() { Properties props = new Properties(); try { byte[] data = zkClient.getData(path, null, null, false); if (data != null) { props.load(new StringReader(new String(data, "UTF-8"))); } } catch (Exception e) { log.warn( ...
public void inform(SolrCore core) { try { //hack to get the name of this handler for (Map.Entry<String, SolrRequestHandler> e : core.getRequestHandlers().entrySet()) { SolrRequestHandler handler = e.getValue(); //this will not work if startup=lazy is set if( this == handler) { ...
public void inform(SolrCore core) { try { //hack to get the name of this handler for (Map.Entry<String, SolrRequestHandler> e : core.getRequestHandlers().entrySet()) { SolrRequestHandler handler = e.getValue(); //this will not work if startup=lazy is set if( this == handler) { ...
public void run() { try { if (zkProps.getServers().size() > 1) { QuorumPeerMain zkServer = new QuorumPeerMain(); zkServer.runFromConfig(zkProps); } else { ServerConfig sc = new ServerConfig(); sc.readFrom(zkProps); ZooKeeperSe...
public void run() { try { if (zkProps.getServers().size() > 1) { QuorumPeerMain zkServer = new QuorumPeerMain(); zkServer.runFromConfig(zkProps); } else { ServerConfig sc = new ServerConfig(); sc.readFrom(zkProps); ZooKeeperSe...
public static SimpleOrderedMap<Object> getSystemInfo() { SimpleOrderedMap<Object> info = new SimpleOrderedMap<Object>(); OperatingSystemMXBean os = ManagementFactory.getOperatingSystemMXBean(); info.add( "name", os.getName() ); info.add( "version", os.getVersion() ); info.add( "arch", os.getA...
public static SimpleOrderedMap<Object> getSystemInfo() { SimpleOrderedMap<Object> info = new SimpleOrderedMap<Object>(); OperatingSystemMXBean os = ManagementFactory.getOperatingSystemMXBean(); info.add( "name", os.getName() ); info.add( "version", os.getVersion() ); info.add( "arch", os.getA...
public ShardResponse call() throws Exception { ShardResponse srsp = new ShardResponse(); if (sreq.nodeName != null) { srsp.setNodeName(sreq.nodeName); } srsp.setShardRequest(sreq); srsp.setShard(shard); SimpleSolrResponse ssr = new SimpleSolrResponse(); ...
public ShardResponse call() throws Exception { ShardResponse srsp = new ShardResponse(); if (sreq.nodeName != null) { srsp.setNodeName(sreq.nodeName); } srsp.setShardRequest(sreq); srsp.setShard(shard); SimpleSolrResponse ssr = new SimpleSolrResponse(); ...
public void close() { try { ExecutorUtil.shutdownAndAwaitTermination(updateExecutor); } catch (Throwable e) { SolrException.log(log, e); } finally { clientConnectionManager.shutdown(); } }
public void close() { try { ExecutorUtil.shutdownAndAwaitTermination(updateExecutor); } catch (Exception e) { SolrException.log(log, e); } finally { clientConnectionManager.shutdown(); } }
public void warm(SolrIndexSearcher searcher, SolrCache old) { if (regenerator == null) return; long warmingStartTime = System.currentTimeMillis(); LFUCache other = (LFUCache) old; // warm entries if (autowarmCount != 0) { int sz = other.size(); if (autowarmCount != -1) sz = Math.min(sz...
public void warm(SolrIndexSearcher searcher, SolrCache old) { if (regenerator == null) return; long warmingStartTime = System.currentTimeMillis(); LFUCache other = (LFUCache) old; // warm entries if (autowarmCount != 0) { int sz = other.size(); if (autowarmCount != -1) sz = Math.min(sz...
public void warm(SolrIndexSearcher searcher, SolrCache<K,V> old) { if (regenerator==null) return; long warmingStartTime = System.currentTimeMillis(); LRUCache<K,V> other = (LRUCache<K,V>)old; // warm entries if (isAutowarmingOn()) { Object[] keys,vals = null; // Don't do the autowarm...
public void warm(SolrIndexSearcher searcher, SolrCache<K,V> old) { if (regenerator==null) return; long warmingStartTime = System.currentTimeMillis(); LRUCache<K,V> other = (LRUCache<K,V>)old; // warm entries if (isAutowarmingOn()) { Object[] keys,vals = null; // Don't do the autowarm...
public void warm(SolrIndexSearcher searcher, SolrCache old) { if (regenerator == null) return; long warmingStartTime = System.currentTimeMillis(); FastLRUCache other = (FastLRUCache) old; // warm entries if (isAutowarmingOn()) { int sz = autowarm.getWarmCount(other.size()); Map items =...
public void warm(SolrIndexSearcher searcher, SolrCache old) { if (regenerator == null) return; long warmingStartTime = System.currentTimeMillis(); FastLRUCache other = (FastLRUCache) old; // warm entries if (isAutowarmingOn()) { int sz = autowarm.getWarmCount(other.size()); Map items =...
private boolean createCollection(ClusterState clusterState, ZkNodeProps message) { String collectionName = message.getStr("name"); if (clusterState.getCollections().contains(collectionName)) { SolrException.log(log, "collection already exists: " + collectionName); return false; } try ...
private boolean createCollection(ClusterState clusterState, ZkNodeProps message) { String collectionName = message.getStr("name"); if (clusterState.getCollections().contains(collectionName)) { SolrException.log(log, "collection already exists: " + collectionName); return false; } try ...
public String toString(){ StringBuffer sb = new StringBuffer(); sb.append("{"); boolean first=true; for(Map.Entry<N, V> entry : this.entrySet()){ if(!first)sb.append(","); first=false; sb.append(entry.getKey()+"->"+entry.getValue()); } sb.append("}"); ...
public String toString(){ StringBuilder sb = new StringBuilder(); sb.append("{"); boolean first=true; for(Map.Entry<N, V> entry : this.entrySet()){ if(!first)sb.append(","); first=false; sb.append(entry.getKey()+"->"+entry.getValue()); } sb.append("}"); ...
private synchronized void acquireTestLock() { if (tested) return; tested = true; // Ensure that lockDir exists and is a directory. if (!lockDir.exists()) { if (!lockDir.mkdirs()) throw new RuntimeException("Cannot create directory: " + lockDir.getAbsolu...
private synchronized void acquireTestLock() { if (tested) return; tested = true; // Ensure that lockDir exists and is a directory. if (!lockDir.exists()) { if (!lockDir.mkdirs()) throw new RuntimeException("Cannot create directory: " + lockDir.getAbsolu...
public String[] suggestSimilar(String word, int numSug, IndexReader ir, String field, boolean morePopular) throws IOException { float min = this.minScore; final TRStringDistance sd = new TRStringDistance(word); final int lengthWord = word.length(); final int freq = (ir != null && field != null...
public String[] suggestSimilar(String word, int numSug, IndexReader ir, String field, boolean morePopular) throws IOException { float min = this.minScore; final TRStringDistance sd = new TRStringDistance(word); final int lengthWord = word.length(); final int freq = (ir != null && field != null...
private static CFMetaData jdbcCFMD(String ksName, String cfName, AbstractType comp) { return new CFMetaData(ksName, cfName, ColumnFamilyType.Standard, comp, comp); }
private static CFMetaData jdbcCFMD(String ksName, String cfName, AbstractType comp) { return new CFMetaData(ksName, cfName, ColumnFamilyType.Standard, comp, null).defaultValidator(comp); }
public int compare(String o1, String o2) { return dc.compare(partitioner.decorateKey(o1), partitioner.decorateKey(o2)); } }); DataOutputBuffer buffer = new DataOutputBuffer(); for (String key : orderedKeys) { buffer.reset();...
public int compare(String o1, String o2) { return dc.compare(partitioner.decorateKey(o1), partitioner.decorateKey(o2)); } }); DataOutputBuffer buffer = new DataOutputBuffer(); for (String key : orderedKeys) { buffer.reset();...
protected double processNominal(String label, String data) { double result; Map<String,Integer> classes = nominalMap.get(label); if (classes != null) { Integer ord = classes.get(data); if (ord != null) { result = ord; } else { throw new IllegalStateException("Invalid nomi...
protected double processNominal(String label, String data) { double result; Map<String,Integer> classes = nominalMap.get(label); if (classes != null) { Integer ord = classes.get(ARFFType.removeQuotes(data)); if (ord != null) { result = ord; } else { throw new IllegalState...
public T get() { if (serviceObject == null && ref.getBundle() != null) { serviceObject = (T) ctx.getService(ref); } return serviceObject; }
public T get() { if (serviceObject == null && ref.getBundle() != null) { serviceObject = (T) Utils.getServicePrivileged(ctx, ref); } return serviceObject; }
public void processDelete(DeleteUpdateCommand cmd) throws IOException { if( cmd.id != null ) { updateHandler.delete(cmd); } else { updateHandler.deleteByQuery(cmd); } super.processDelete(cmd); changesSinceCommit = true; }
public void processDelete(DeleteUpdateCommand cmd) throws IOException { if( cmd.isDeleteById()) { updateHandler.delete(cmd); } else { updateHandler.deleteByQuery(cmd); } super.processDelete(cmd); changesSinceCommit = true; }
public void deleteDoc(Object id) { try { log.info("Deleting document: " + id); DeleteUpdateCommand delCmd = new DeleteUpdateCommand(req); delCmd.id = id.toString(); processor.processDelete(delCmd); } catch (IOException e) { log.error("Exception while deleteing: " + id, e); } ...
public void deleteDoc(Object id) { try { log.info("Deleting document: " + id); DeleteUpdateCommand delCmd = new DeleteUpdateCommand(req); delCmd.setId(id.toString()); processor.processDelete(delCmd); } catch (IOException e) { log.error("Exception while deleteing: " + id, e); ...
public List<KeySlice> get_range_slices(ColumnParent column_parent, SlicePredicate predicate, KeyRange range, ConsistencyLevel consistency_level) throws InvalidRequestException, UnavailableException, TException, TimedOutException { logger.debug("range_slice"); String keyspace = state().getKe...
public List<KeySlice> get_range_slices(ColumnParent column_parent, SlicePredicate predicate, KeyRange range, ConsistencyLevel consistency_level) throws InvalidRequestException, UnavailableException, TException, TimedOutException { logger.debug("range_slice"); String keyspace = state().getKe...
public void reload(SolrCore core, SolrIndexSearcher searcher) throws IOException { LOG.info("reload()"); if (dictionary == null && storeDir != null) { // this may be a firstSearcher event, try loading it if (lookup.load(storeDir)) { return; // loaded ok } } // dictionary bas...
public void reload(SolrCore core, SolrIndexSearcher searcher) throws IOException { LOG.info("reload()"); if (dictionary == null && storeDir != null) { // this may be a firstSearcher event, try loading it if (lookup.load(storeDir)) { return; // loaded ok } } // dictionary bas...
public float getFloat() throws StandardException { if (Math.abs(value) > Float.MAX_VALUE) throw StandardException.newException(SQLState.LANG_OUTSIDE_RANGE_FOR_DATATYPE, TypeId.REAL_NAME); return (float) value; }
public float getFloat() throws StandardException { if (Float.isInfinite((float)value)) throw StandardException.newException(SQLState.LANG_OUTSIDE_RANGE_FOR_DATATYPE, TypeId.REAL_NAME); return (float) value; }
private final byte[] setBytesFromStream(java.io.InputStream is, int length) throws SqlException { java.io.ByteArrayOutputStream baos = new java.io.ByteArrayOutputStream(); int totalRead = 0; try { int read = is.read(); while (read != -1) { totalRead++...
private final byte[] setBytesFromStream(java.io.InputStream is, int length) throws SqlException { java.io.ByteArrayOutputStream baos = new java.io.ByteArrayOutputStream(); int totalRead = 0; try { int read = is.read(); while (read != -1) { totalRead++...
public synchronized long push(FrozenBufferedDeletes packet) { /* * The insert operation must be atomic. If we let threads increment the gen * and push the packet afterwards we risk that packets are out of order. * With DWPT this is possible if two or more flushes are racing for pushing * updat...
public synchronized long push(FrozenBufferedDeletes packet) { /* * The insert operation must be atomic. If we let threads increment the gen * and push the packet afterwards we risk that packets are out of order. * With DWPT this is possible if two or more flushes are racing for pushing * updat...
private void deleteCollection(ZkNodeProps message, NamedList results) throws KeeperException, InterruptedException { String collection = message.getStr("name"); try { ModifiableSolrParams params = new ModifiableSolrParams(); params.set(CoreAdminParams.ACTION, CoreAdminAction.UNLOAD.toString(...
private void deleteCollection(ZkNodeProps message, NamedList results) throws KeeperException, InterruptedException { String collection = message.getStr("name"); try { ModifiableSolrParams params = new ModifiableSolrParams(); params.set(CoreAdminParams.ACTION, CoreAdminAction.UNLOAD.toString(...
public int get(int pos) throws IOException { //System.out.println(" get pos=" + pos + " nextPos=" + nextPos + " count=" + count); if (pos == nextPos) { if (end) { return -1; } final int ch = reader.read(); if (ch == -1) { end = true; return -1; } ...
public int get(int pos) throws IOException { //System.out.println(" get pos=" + pos + " nextPos=" + nextPos + " count=" + count); if (pos == nextPos) { if (end) { return -1; } final int ch = reader.read(); if (ch == -1) { end = true; return -1; } ...
public final void read(Directory directory, String segmentFileName) throws CorruptIndexException, IOException { boolean success = false; // Clear any previous segments: this.clear(); generation = generationFromSegmentsFileName(segmentFileName); lastGeneration = generation; ChecksumIndexInp...
public final void read(Directory directory, String segmentFileName) throws CorruptIndexException, IOException { boolean success = false; // Clear any previous segments: this.clear(); generation = generationFromSegmentsFileName(segmentFileName); lastGeneration = generation; ChecksumIndexInp...
private void defragmentRows(TransactionController tc) throws StandardException { GroupFetchScanController base_group_fetch_cc = null; int num_indexes = 0; int[][] index_col_map = null; ScanController[] index_sc...
private void defragmentRows(TransactionController tc) throws StandardException { GroupFetchScanController base_group_fetch_cc = null; int num_indexes = 0; int[][] index_col_map = null; ScanController[] index_sc...
private static void executeCAPreferSubTrans (CreateSchemaConstantAction csca, TransactionController tc, Activation activation) throws StandardException { TransactionController useTc = null; TransactionController nestedTc = null; try { nestedTc = tc.startNestedUserTransaction(false); useTc = ne...
private static void executeCAPreferSubTrans (CreateSchemaConstantAction csca, TransactionController tc, Activation activation) throws StandardException { TransactionController useTc = null; TransactionController nestedTc = null; try { nestedTc = tc.startNestedUserTransaction(false, true); useT...
protected InternalXact( XactFactory xactFactory, LogFactory logFactory, DataFactory dataFactory, DataValueFactory dataValueFactory) { super( xactFactory, logFactory, dataFactory, dataValueFactory, false, null); // always want to hold latc...
protected InternalXact( XactFactory xactFactory, LogFactory logFactory, DataFactory dataFactory, DataValueFactory dataValueFactory) { super( xactFactory, logFactory, dataFactory, dataValueFactory, false, null, false); // always want to ho...
public void purgeConglomerate( TransactionManager xact_manager, Transaction rawtran) throws StandardException { OpenConglomerate open_for_ddl_lock = null; HeapController heapcontroller = null; TransactionManager ne...
public void purgeConglomerate( TransactionManager xact_manager, Transaction rawtran) throws StandardException { OpenConglomerate open_for_ddl_lock = null; HeapController heapcontroller = null; TransactionManager ne...
public Message getMessage(int version) throws IOException; }
public Message getMessage(Integer version) throws IOException; }
private void createTestObjects(Statement st) throws SQLException { conn = getConnection(); conn.setAutoCommit(false); CleanDatabaseTestSetup.cleanDatabase(conn, false); st.executeUpdate("set isolation to rr"); st.executeUpdate( " CREATE FUNCTION ...
private void createTestObjects(Statement st) throws SQLException { conn = getConnection(); conn.setAutoCommit(false); CleanDatabaseTestSetup.cleanDatabase(conn, false); st.executeUpdate("set isolation to rr"); st.executeUpdate( " CREATE FUNCTION ...
public void doTest() throws Exception { handle.clear(); handle.put("QTime", SKIPVAL); handle.put("timestamp", SKIPVAL); waitForThingsToLevelOut(15); del("*:*"); createCollection("collection2", 2, 1, 10); List<Integer> numShardsNumReplicaList = new ArrayList<Integer>(2)...
public void doTest() throws Exception { handle.clear(); handle.put("QTime", SKIPVAL); handle.put("timestamp", SKIPVAL); waitForThingsToLevelOut(15); del("*:*"); createCollection("collection2", 2, 1, 10); List<Integer> numShardsNumReplicaList = new ArrayList<Integer>(2)...
public void testSSLBasicDSPlainConnect() throws Exception { DataSource ds = JDBCDataSource.getDataSource(); JDBCDataSource.setBeanProperty(ds,"createDatabase","create"); try { Connection c2 = ds.getConnection(); c2.close(); fail(); ...
public void testSSLBasicDSPlainConnect() throws Exception { DataSource ds = JDBCDataSource.getDataSource(); JDBCDataSource.setBeanProperty(ds,"createDatabase","create"); try { Connection c2 = ds.getConnection(); c2.close(); fail(); ...
public Memtable(ColumnFamilyStore cfs) { this.cfs = cfs; creationTime = System.currentTimeMillis(); THRESHOLD = cfs.getMemtableThroughputInMB() * 1024 * 1024; THRESHOLD_COUNT = (long) (cfs.getMemtableOperationsInMillions() * 1024 * 1024); }
public Memtable(ColumnFamilyStore cfs) { this.cfs = cfs; creationTime = System.currentTimeMillis(); THRESHOLD = cfs.getMemtableThroughputInMB() * 1024L * 1024L; THRESHOLD_COUNT = (long) (cfs.getMemtableOperationsInMillions() * 1024 * 1024); }
public void postCreate(BooleanQuery q) { BooleanClause[] c =q.getClauses(); int opt=0; for (int i=0; i<c.length;i++) { if (c[i].getOccur() == BooleanClause.Occur.SHOULD) opt++; } q.setMinimumNumberShouldMatch(random.nextInt(opt+2)); } }...
public void postCreate(BooleanQuery q) { BooleanClause[] c =q.getClauses(); int opt=0; for (int i=0; i<c.length;i++) { if (c[i].getOccur() == BooleanClause.Occur.SHOULD) opt++; } q.setMinimumNumberShouldMatch(random.nextInt(opt+2)); } }...
protected Object createValue(AtomicReader reader, CacheKey key, boolean setDocsWithField /* ignored */) throws IOException { return new DocTermOrds(reader, key.field); } }
protected Object createValue(AtomicReader reader, CacheKey key, boolean setDocsWithField /* ignored */) throws IOException { return new DocTermOrds(reader, null, key.field); } }
public ColumnFamily getColumnFamily() { return reader.getEmptyColumnFamily(); }
public ColumnFamily getColumnFamily() { return reader == null ? null : reader.getEmptyColumnFamily(); }
public CharsRef indexedToReadable(BytesRef input, CharsRef output) { input.utf8ToChars(output); return output; }
public CharsRef indexedToReadable(BytesRef input, CharsRef output) { UnicodeUtil.UTF8toUTF16(input, output); return output; }
public static void initHostContext() { // Can't use randomRealisticUnicodeString because unescaped unicode is // not allowed in URL paths // Can't use URLEncoder.encode(randomRealisticUnicodeString) because // Jetty freaks out and returns 404's when the context uses escapes StringBuilder hostCon...
public static void initHostContext() { // Can't use randomRealisticUnicodeString because unescaped unicode is // not allowed in URL paths // Can't use URLEncoder.encode(randomRealisticUnicodeString) because // Jetty freaks out and returns 404's when the context uses escapes StringBuilder hostCon...