/JavaEPFImporter

Java version of apple's EPF importer

Primary LanguageJavaApache License 2.0Apache-2.0

Java EPF Importer

A version of apple's EPF importer written in Java. The original scripts can be found at http://www.apple.com/itunes/affiliates/resources/documentation/epfimporter.html#configure-epfimporter.

Current supported ingesters

  • MySQL (original ingestor)
  • DataStore using appengine remote api

There is also a fork here that supports Postgres.

Usage

java -jar epfimporter.jar [-fxrak] [-d db_host] [-u db_user] [-p db_password] [-n db_name]
    [-s record_separator] [-t field_separator] [-w regex [-w regex2 [...]]]
    [-b regex [-b regex2 [...]]] source_directory [source_directory2 ...]
  • f or flat: Import EPF Flat files, using values from EPFFlat.config if not overridden - defaults to false
  • r or resume: Resume the most recent import according to the relevant .json status file (EPFStatusIncremental.json if -i, otherwise EPFStatusFull.json) - defaults to false
  • z or ingestertype: Ingester type name, currently the only ones supported are MySQL and DataStore
  • d or dbhost: The hostname of the database - defaults to localhost
  • u or dbuser: The user which will execute the database commands; must have table create/drop privileges
  • p or dbpassword: The user's password for the database
  • n or dbname: The name of the database to connect to
  • s or recordseparator: The string separating records in the file
  • t or fieldseparator: The string separating fields in the file
  • a or allowextensions: Include files with dots in their names in the import - defaults to false
  • x or tableprefix: Optional prefix which will be added to all table names, e.g. MyPrefix_video_translation
  • w or whitelist: A regular expression to add to the whiteList; repeated -w arguments will append
  • b or blacklist: A regular expression to add to the whiteList; repeated -b arguments will append
  • k or skipkeyviolators: Ignore inserts which would violate a primary key constraint; only applies to full imports - defaults to false

Contribute

Please feel free to raise issues and contribute fixes, but please note that this is a work in progress.