solr??????????????????????solr
???????????? ???????[ 2014/1/17 9:17:03 ] ????????????? solr ????
???????????
????1??solr??????????tomcat
????2??????apache-solr-3.6.0.war??tomcat??webapps???£????????solr.war
????3??tomcat??conf??????????conf/Catalina/localhost??????????С????????solr-tomcat/solr??????????У?solr??HOME???????罨??D???????d:/solr-tomcat/solr??solr-tomcat??????????????????????apache-solr-3.6.0examplesolr?μ??????????????п???????????
????4????localhost??????????solr.xml?????????????????
<Context docBase="D: omcat-6.0webappssolr.war" debug="0" crossContext="true" >
<Environment name="solr/home" type="java.lang.String" value="D:/solr-tomcat/solr" override="true" />
</Context>
????5?????????????tomcat???????????:http://localhost:8080/solr/admin???????
????6?????????????????????????á???jdbc????jar??apache-solr-3.6.0distapache-solr-dataimporthandler-3.6.0.jar ????jar??????tomcat??webapps/solr/WEB-INF/lib?????apache-solr-3.6.0exampleexample-DIHsolr?μ??????????????п??????????????solr??HOME??????:d:/solr-tomcat/solr
????7??????solr Home???μ?conf/solrconfig.xml?????????????:
<requestHandler name="/dataimport" class="org.apache.solr.handler.dataimport.DataImportHandler">
<lst name="defaults">
<str name="config">D:solr-tomcatsolrdbconfdb-data-config.xml</str> <!-- ??????????????db-data-config.xml?????·????д -- >
</lst>
</requestHandler>
????8?? ??solr Home???????solrconfig.xml??schema.xml??????db??????????conf?У?????????????????schema.xml?ж???
??????????:<field name="firstname" type="string" stored="true" indexed="true"/>
????9?????dbconfdb-data-config.xml????ο?????:
<dataConfig>
<dataSource type="JdbcDataSource" driver="com.mysql.jdbc.Driver" url="jdbc:mysql://localhost:3306/langsin1" user="root" password="root"/>
<document name="userss">
<entity name="users" pk="id" query="select * from users">
<field column="id" name="id" />
<field column="firstname" name="firstname" />
<field column="lastname" name="lastname" />
<field column="age" name="age" />
</entity>
</document>
</dataConfig>
????10?????TOMCAT???????????е???????????????????????????????
????http://localhost:8080/solr/db/dataimport?command=full-import
????11???????????????tomcat??server.xml???
????<Connector port="8080" protocol="HTTP/1.1"
????connectionTimeout="20000"
????redirectPort="8443" URIEncoding="UTF-8"
????12??????????????:mmseg4j?? ??$SOLR_HOME?????lib??dic??????????mmseg4j-all-1.8.4.jar??????lib??????data???.dic?????????dic??
??????
???·???
??????????????????
2023/3/23 14:23:39???д?ò??????????
2023/3/22 16:17:39????????????????????Щ??
2022/6/14 16:14:27??????????????????????????
2021/10/18 15:37:44???????????????
2021/9/17 15:19:29???·???????·
2021/9/14 15:42:25?????????????
2021/5/28 17:25:47??????APP??????????
2021/5/8 17:01:11