prepare envirement:
jdk 1.4.2 tomcat 5.0.28
1. download software via:
http://www.zilverline.org/zilverlineweb/space/Getting+Zilverline
2. deploy the software as a project in tomcat
2.1 rename the software from zilverline-1.5.0.war to zilverline.wa and move it to the folder %tomcat%/webapps
2.2 restart tomcat and visit the search engine's interface via (http://localhost:8080/zilverline/search.htm)
2.3 log in the system
2.3.1 search string "change the passwords" in file %tomcat%/webapps/zilverline/WEB-INF/acegi-security.xml
then you will get the default account and password is: admin/password
2.4 create collection and index
connection: it means which files we should search with the keyword
index: the software will show refere links to match the keyword's search result according to the index
2.4.1 after log in, we can click the link: "Collections"
2.4.2 click "Add Collection" and insert refere value to create the collection
2.4.3 the search results will not have a url until we set the Collection's property
log in ---> add collection ---> click the collection we need to modify ----> select the radio button
2.4.4 click the button "Create Index" to create index
3. some basic knowledge
http://www.zilverline.org/zilverlineweb/space/faq
4. about the schedule for update collection and index
4.1 refere to the page http://www.zilverline.org/zilverlineweb/space/scheduling
4.2 the 's setting: (about the schedule to update collecton and index)
please refere to the link below
http://www.opensymphony.com/quartz/api/org/quartz/CronTrigger.html
4.3
setup schedule-context.xml to update the index with a brand new index
(refer to source file org.zilverline.service.IndexServiceImpl)
class="org.springframework.scheduling.quartz.MethodInvokingJobDetailFactoryBean">
reIndex
4.4 setup
multiple schedules
http://www.zilverline.org/zilverlineweb/space/scheduling
example
search string " enableLookups="false" redirectPort="8443" acceptCount="100"
debug="0"
connectionTimeout="20000" disableUploadTimeout="true" URIEncoding="UTF-8" />
6. enlarge the engine's search scope
example:
the engine doesn't search the key in the jsp files, so we need to update the setting in the preference-----> 摘取器映像
7. source code's online api document
http://www.zilverline.org/build/apidocs/
8. refere configuration files's usage
please search string "getConfigLocations" in every source files
8.1 we can grep all the source files
8.2 we can search in google or baidu like this keyword:
getConfigLocations Zilverline acegi-security.xml
8.3 then we can read the source code to learn some things which will help us
9. some things not sure
9.1 where does the engine store the collection and index and how to modify these config
refer to collectionManager.xml's
9.2 does the engine search in the sensitivity files in the project, such like the files in WEB-INF
yes, we need further action to forbid this condition
9.3 why some links in the search result can't be click?
9.4 does the engine surpport the function that: search the pages in the other company's server via their projects' url?
9.5 if a file had a string "hello" then we search "he" but there are no results?!
9.5.1 this problem maybe caused by this condition: the collection and index havn't be updated before we search
9.5.2 if we had updated the collection and index, but the problem still exist,
so it maybe refer to the search method in the core of the engine's search regular
9.6 sometime we add some new files in the collection's folders, but after we updated the index, it just can't show the new files add? it just seem like update failed but not tips showed?!
10 attention:
10.1 the search engine will ignore the link created by command 'ln', so we should use the
real path to create index!
10.2 edit the config file: applicationContext.xml to setup the project's based-directory
C:/Program Files/Apache Software Foundation/Tomcat 5.0/webapps/zilverline/WEB-INF/db
10.3 the engine would stop update the index once some search reqest was triggered during
the engine updating the index incremently, but if update a brand new index, this
condition would never happened.
10.4 once the search engine can't start correctly because of the search engine complaint some default value had been setted, we should add the string below to the config file: web.xml
11
other search engine's introduction
http://www.zgcol.net/thread-37224-1-1.html
12. Exception's solution:
- 2009-01-05 10:58:53,905 [*IndexingThread] [ERROR] org.zilverline.core.AbstractCollection Can't succesfully finish background indexing process
- org.zilverline.core.IndexException: Error indexing *. Possibly unable to remove old index
- at org.zilverline.core.FileSystemCollection.index(FileSystemCollection.java:179)
- at org.zilverline.core.AbstractCollection$1.run(AbstractCollection.java:509)
- at java.lang.Thread.run(Thread.java:595)
- Caused by: java.io.IOException: Lock obtain timed out: Lock@/usr/local/tomcat/temp/lucene-ee1683f9af41386be10b6bc43b69c29e-write.lock
- at org.apache.lucene.store.Lock.obtain(Lock.java:58)
- at org.apache.lucene.index.IndexWriter.(IndexWriter.java:255)
- at org.apache.lucene.index.IndexWriter.(IndexWriter.java:225)
- at org.zilverline.core.FileSystemCollection.index(FileSystemCollection.java:142)
- ... 2 more
原因: 某個文件被鎖,所以在訪問時發生錯誤
解決方法: 備分並刪除被鎖的文件 /usr/local/tomcat/temp/lucene-ee1683f9af41386be10b6bc43b69c29e-write