[virgil] r170 committed - Deleted wiki page solr through web user interface.

40 views
Skip to first unread message

virgil.apach...@codespot.com

unread,
Feb 6, 2012, 9:53:10 PM2/6/12
to virgil...@gmail.com
Revision: 170
Author: bone...@gmail.com
Date: Mon Feb 6 18:48:25 2012
Log: Deleted wiki page solr through web user interface.
http://code.google.com/a/apache-extras.org/p/virgil/source/detail?r=170

Deleted:
/wiki/solr.wiki

=======================================
--- /wiki/solr.wiki Sun Nov 20 12:28:10 2011
+++ /dev/null
@@ -1,85 +0,0 @@
-#summary SOLR Integration w/ Cassandra
-#labels SOLR
-
-= Introduction =
-
-Virgil integrates SOLR such that columns and rows added and deleted via
the REST API are automatically indexed by SOLR. The indexing occurs
outside of cassandra.
-
-= Getting Started =
-
-== Install SOLR ==
- # Download [http://lucene.apache.org/solr/ SOLR]
- # Unzip/Untar the install
- # Start the default server with:
-{{{
-cd $SOLR_HOME/example
-java -jar start.jar
-}}}
- # This will start a SOLR instance with the default schema.
-
-= Configure Virgil =
- # Open the virgil.yaml in src/main/resources/ and confirm the hostname is
correct, and indexing is enabled.
-{{{
-solr_host: http://localhost:8983/solr/
-enable_indexing: true
-}}}
- # Start virgil with bin/virgil
-
-= Usage =
-
-Make sure you've followed the
[http://code.google.com/a/apache-extras.org/p/virgil/ getting started
steps] to create a playground keyspace, and toys column family.
-
-To use the indexing, add a query parameter onto your url. For adds, tack
on "index=true". For deletes, tack on "purgeIndex=true".
-
-You can see the contents of the SOLR index with the following URL.
Initially, it should be empty:
-http://localhost:8983/solr/select/?q=*%3A*&version=2.2&start=0&rows=10&indent=on
-
-Then, after each of the following steps, you should be able to refresh and
see the index updated.
-
-=== Insert Row (rowkey = "swingset", columns [ foo:1, bar:22 ]) ===
-{{{
-curl -X PUT
http://localhost:8080/virgil/data/playground/toys/swingset?index=true
-d "{\"foo\":\"1\",\"bar\":\"33\"}"
-}}}
-
-=== Insert Column (rowkey = "swingset", columns [ snaf:lisa ]) ===
-{{{
-curl -X PUT
http://localhost:8080/virgil/data/playground/toys/swingset/snaf?index=true
-d "lisa"
-}}}
-
-=== Delete Column (rowkey = "swingset") ===
-{{{
-curl -X DELETE
http://localhost:8080/virgil/data/playground/toys/swingset/snaf?purgeIndex=true
-}}}
-
-=== Delete Row ===
-{{{
-curl -X DELETE
http://localhost:8080/virgil/data/playground/toys/swingset?purgeIndex=true
-}}}
-
-= Using the Index =
-
-To achieve the integration, Virgil is using the dynamic fields capability
of SOLR. Using the curl commands above, you'll end up with the following
document in SOLR:
-{{{
-<result name="response" numFound="1" start="0">
- <doc>
- <str name="bar_t">37</str>
- <str name="columnFamily_t">toys</str>
- <str name="foo_t">1</str>
- <str name="id">toys.swingset</str>
- <str name="rowKey_t">swingset</str>
- </doc>
-</result>
-}}}
-
-You'll notice that each row becomes a document in SOLR, and each column
becomes a field. Additionally, we include the column family and rowkey as
fields, which is what we combine to generate a unique id for the document.
Since we are using dynamic fields, we tack on a "_t" to each field name,
which allows SOLR to recognize it as text. Based on that, you should be
able to search now in SOLR using your column names + "_t".
-
-Give it a whirl from the admin console:
-http://localhost:8983/solr/admin/
-
-Try plugging in the following as search criteria.
-{{{
-bar_t:37
-}}}
-
-=== IMPORTANT NOTE ===
-Since there is no way to add and delete fields of a document cleanly
within SOLR, there is a penalty for deleting or adding a single column.
Thus, it is best to do row inserts and deletions when you can.

Reply all
Reply to author
Forward
0 new messages