Package org.apache.solr.client.solrj.response

Examples of org.apache.solr.client.solrj.response.SolrResponseBase


      context.put("page", new PageTool(request, response))// page tool only makes sense for a SearchHandler request... *sigh*
    } catch (ClassCastException e) {
      // known edge case where QueryResponse's extraction assumes "response" is a SolrDocumentList
      // (AnalysisRequestHandler emits a "response")
      e.printStackTrace();
      rsp = new SolrResponseBase();
      rsp.setResponse(parsedResponse);
    }
    context.put("response", rsp);

    // Velocity context tools - TODO: make these pluggable
View Full Code Here


    return BlurClient.getClient(connectionString);
  }

  @SuppressWarnings("unchecked")
  private <T extends SolrResponseBase> T respond(Class<T> typ, Command command) throws SolrServerException {
    SolrResponseBase response;
    long start = System.currentTimeMillis();
    try {
      response = typ.newInstance();

      command.process();
    } catch (Exception e) {
      throw new SolrServerException("Unable to complete update request.", e);
    }
    response.setElapsedTime((System.currentTimeMillis() - start));
    return (T) response;
  }
View Full Code Here

      // page only injected if QueryResponse works
      context.put("page",new PageTool(request,response))// page tool only makes sense for a SearchHandler request... *sigh*
    } catch (ClassCastException e) {
      // known edge case where QueryResponse's extraction assumes "response" is a SolrDocumentList
      // (AnalysisRequestHandler emits a "response")
      rsp = new SolrResponseBase();
      rsp.setResponse(parsedResponse);
    }
    context.put("response", rsp);

    // Velocity context tools - TODO: make these pluggable
View Full Code Here

TOP

Related Classes of org.apache.solr.client.solrj.response.SolrResponseBase

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.