Removed documentation on Elasticsearch.
Elasticsearch is no longer planned for debshots. Full-text search using PostgreSQL is sufficient.
This commit is contained in:
parent
bdfad36cc1
commit
369837a6d7
1 changed files with 0 additions and 73 deletions
73
README.rdoc
73
README.rdoc
|
|
@ -107,76 +107,3 @@ TODO
|
||||||
|
|
||||||
/rss
|
/rss
|
||||||
* Return an RSS feed of new uploads of screenshots
|
* Return an RSS feed of new uploads of screenshots
|
||||||
|
|
||||||
|
|
||||||
== Using Xapian
|
|
||||||
|
|
||||||
Ruby gem "xapian" does not exist. Debian only has bindings for Ruby 1.9.x.
|
|
||||||
Xapian may be lightweight and nice but is too much hassle.
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
== Elasticsearch
|
|
||||||
|
|
||||||
= Install
|
|
||||||
|
|
||||||
Get it from https://download.elasticsearch.org/elasticsearch/elasticsearch/elasticsearch-0.90.6.deb
|
|
||||||
|
|
||||||
Also: apt-get install openjdk-7-jre-headless
|
|
||||||
|
|
||||||
= Configure
|
|
||||||
|
|
||||||
Edit /etc/elasticsearch/elasticsearch.yml for single-server usage:
|
|
||||||
- cluster.name: ...
|
|
||||||
- node.name: ...
|
|
||||||
- index.number_of_shards: 1
|
|
||||||
- index.number_of_replicas: 0
|
|
||||||
- discovery.zen.ping.multicast.enabled: false
|
|
||||||
|
|
||||||
= Add useful plugins
|
|
||||||
|
|
||||||
/usr/share/elasticsearch/bin/plugin -install mobz/elasticsearch-head
|
|
||||||
URL: serve:9200/_plugin/head
|
|
||||||
|
|
||||||
/usr/share/elasticsearch/bin/plugin -install lukas-vlcek/bigdesk
|
|
||||||
URL: serve:9200/_plugin/bigdesk
|
|
||||||
|
|
||||||
= Install River (that feeds PostgreSQL data into ElasticSearch):
|
|
||||||
|
|
||||||
Get the PostgreSQL ODBC driver from
|
|
||||||
wget http://jdbc.postgresql.org/download/postgresql-9.3-1100.jdbc41.jar
|
|
||||||
(according to http://jdbc.postgresql.org/download.html)
|
|
||||||
|
|
||||||
cp postgresql-9.3-1100.jdbc41.jar /usr/share/elasticsearch/plugins/river-jdbc
|
|
||||||
|
|
||||||
/usr/share/elasticsearch/bin/plugin -install river-jdbc -url http://bit.ly/1iovWV9
|
|
||||||
(according to https://github.com/jprante/elasticsearch-river-jdbc)
|
|
||||||
|
|
||||||
Fix permissions after plugin installation:
|
|
||||||
chown -R elasticsearch:elasticsearch /usr/share/elasticsearch/plugins
|
|
||||||
|
|
||||||
Restart Elasticsearch.
|
|
||||||
|
|
||||||
curl -XPUT 'localhost:9200/_river/debshots_jdbc_river/_meta' -d '{
|
|
||||||
"type" : "jdbc",
|
|
||||||
"jdbc" : {
|
|
||||||
"driver" : "org.postgresql.Driver",
|
|
||||||
"url" : "jdbc:postgresql://localhost:5432/debshots",
|
|
||||||
"user" : "debshots",
|
|
||||||
"password" : "shootme",
|
|
||||||
"sql" : "select id as _id,name,description from packages",
|
|
||||||
"strategy" : "simple",
|
|
||||||
"poll" : "5m"
|
|
||||||
},
|
|
||||||
"index" : {
|
|
||||||
"index" : "debshots",
|
|
||||||
"type" : "jdbc"
|
|
||||||
}
|
|
||||||
}'
|
|
||||||
|
|
||||||
Should return:
|
|
||||||
|
|
||||||
{"ok":true,"_index":"_river","_type":"my_jdbc_river","_id":"_meta","_version":1}
|
|
||||||
|
|
||||||
|
|
||||||
TODO: Tire versus Rivers
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue