mirror of https://github.com/apache/cassandra
Update pig readme
This commit is contained in:
parent
db68e03f7d
commit
2dc27a1756
|
|
@ -1,7 +1,8 @@
|
|||
A Pig storage class that reads all columns from a given ColumnFamily, or writes
|
||||
properly formatted results into a ColumnFamily.
|
||||
|
||||
Setup:
|
||||
Getting Started
|
||||
===============
|
||||
|
||||
First build and start a Cassandra server with the default
|
||||
configuration and set the PIG_HOME and JAVA_HOME environment
|
||||
|
|
@ -31,7 +32,6 @@ for input and output:
|
|||
* PIG_OUTPUT_RPC_PORT : the port thrift is listening on for writing
|
||||
* PIG_OUTPUT_PARTITIONER : cluster partitioner for writing
|
||||
|
||||
|
||||
Then you can run it like this:
|
||||
|
||||
examples/pig$ bin/pig_cassandra -x local example-script.pig
|
||||
|
|
@ -70,3 +70,18 @@ Which will copy the ColumnFamily. Note that the destination ColumnFamily must
|
|||
already exist for this to work.
|
||||
|
||||
See the example in test/ to see how schema is inferred.
|
||||
|
||||
Advanced Options
|
||||
================
|
||||
|
||||
The following environment variables default to false but can be set to true to enable them:
|
||||
|
||||
PIG_WIDEROW_INPUT: this enables loading of rows with many columns without
|
||||
incurring memory pressure. All columns will be in a bag and indexes are not
|
||||
supported.
|
||||
|
||||
PIG_USE_SECONDARY: this allows easy use of secondary indexes within your
|
||||
script, by appending every index to the schema as 'index_$name', allowing
|
||||
filtering of loaded rows with a statement like "FILTER rows BY index_color eq
|
||||
'blue'" if you have an index called 'color' defined.
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue