Redshift Data Warehouse Libraries for HSReplay.net
Libraries for ETL and analysis of HSReplay.xml files via Redshift.
Running MRJobs
This section assumes that your working directory is the repository root.
To run a job locally:
$ python <JOB_NAME>.py <INPUT_FILE.TXT>
To generate an inputs.txt data set:
$ PYTHONPATH=$PYTHONPATH:. python ./loaders/emr/generate_inputs.py
By default the file will go to loaders/emr/data/ this will also stage the inputs.txt file on S3 to make launching
the job faster. To bootstrap a cluster:
$ mrjob create-cluster --conf-path ./loaders/emr/mrjob.conf
<CLUSTER-ID>
Then to run the job on the cluster:
$ python my_job.py -r emr --conf-path mrjob.conf --cluster-id <CLUSTER-ID> <INPUT_S3_PATH> --no-output --connection="<upload-db connection string>"
A concrete example might look like:
PYTHONPATH=$PYTHONPATH:. python ./loaders/emr/load_redshift.py -r emr --conf-path ./loaders/emr/mrjob.conf --cluster-id j-2YYNNMRVT35MN s3://hearthsim-mrjob/data/2017-01-05_00-00-00_TO_2017-01-05_00-10-00_inputs.txt --no-output
License
Copyright © HearthSim - All Rights Reserved
Community
This is a HearthSim project. All development
happens on our IRC channel #hearthsim on Freenode.