You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucene.apache.org by "Jan Høydahl (JIRA)" <ji...@apache.org> on 2016/10/31 13:05:58 UTC

[jira] [Updated] (SOLR-9370) Add sample code snippet to confluence documentaion for Basic Authentication

     [ https://issues.apache.org/jira/browse/SOLR-9370?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jan Høydahl updated SOLR-9370:
------------------------------
    Fix Version/s: 6.3

> Add sample code snippet to confluence documentaion for Basic Authentication
> ---------------------------------------------------------------------------
>
>                 Key: SOLR-9370
>                 URL: https://issues.apache.org/jira/browse/SOLR-9370
>             Project: Solr
>          Issue Type: Task
>      Security Level: Public(Default Security Level. Issues are Public) 
>          Components: documentation
>            Reporter: Susheel Kumar
>            Assignee: Jan Høydahl
>            Priority: Minor
>             Fix For: 6.3
>
>
> Please add below code snippet to under "Using BasicAuth with SolrJ"  as current code "snippet" doesn't give visibility on how basic authentication can be set when querying
> How to set credentials when querying using SolrJ - Basic Authentication
> =========
> SolrQuery query = new SolrQuery();
> query.setQuery("*:*");
> // Do any other query setup needed.
> SolrRequest<QueryResponse> req = new QueryRequest(query);
> req.setBasicAuthCredentials(userName, password); 
> QueryResponse rsp = req.process(solrClient, collection);



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org