If you are used to working with Lucene and want to interface Solr directly
from within a java application, you can take a look at DirectSolrConnection
from EmbeddedSolr, check the wiki page
http://wiki.apache.org/solr/EmbeddedSolr for more info.

cheers,
Tristan


On 7/6/07, Kijiji Xu, Ping <[EMAIL PROTECTED]> wrote:

i) In lucene we add document  by using java. But here they given in xml
format and posting them using  POST.jar. How can i add document in java?
In java ,there have a class named org.apache.solr.util.SimplePostTool ,you
can look at the source code of it,and you'll know how it worked for posting
xml data to solr

ii) How can i send the http request n get response in a standalone java
program?
In my opinion, you can use the java HttpURLConnection class to request and
get response from the solr server

iii) Whether i have to add any xml or i have to modify the xml
(server.xml,web.xml) files for solr server configuration?
NO, but there have two type of configuration for solr .
First of all, the solr configuration file locate in the solr/conf,there
are solrconfig.xml and schema.xml ,you would change them for your
application .
Second, you have to deploy solr application itself to Tomcat, and you
would put a configuration file like this in the tomcat ,the path
is  /home/tomcat/conf/Catalina/localhost/:
<Context docBase="/home/tomcat/webapps/solr.war" debug="0"
crossContext="true" >
   <Environment name="solr/home" type="java.lang.String"
value="/home/tomcat/solr" override="true" />
</Context>

That's all,if you have any question,feel free to ask me:)
-----Original Message-----
From: nithyavembu [mailto:[EMAIL PROTECTED]
Sent: 2007年7月6日 13:27
To: solr-user@lucene.apache.org
Subject: Solr Server Configuration


Hi All,

  I am new to Solr. But i am familiar with lucene.
I am stuggling in solr server configuation.I am using Tomcat 5. I have
worked with the "example"   standalone given with solr while i download.
But my doubt is
  i) In lucene we add document  by using java. But here they given in xml
format and posting them using  POST.jar. How can i add document in java?
ii) How can i send the http request n get response in a standalone java
program?
iii) Whether i have to add any xml or i have to modify the xml
(server.xml,web.xml) files for solr server configuration?


Best,
Nithya.V.
--
View this message in context:
http://www.nabble.com/Solr-Server-Configuration-tf4033748.html#a11458997
Sent from the Solr - User mailing list archive at Nabble.com.

Reply via email to