- Java 8
- PostgreSQL 9.3
- Only JPEG files are supported. If a different file type is detected, a warning is logged.
- Updated files will not be re-processed.
This solution requires a number of environment variables for runtime configuration.
$ export WALDO_PHOTOS_JDBC_URL="jdbc:postgresql://server/database"
$ export WALDO_PHOTOS_JDBC_USER="username"
$ export WALDO_PHOTOS_JDBC_PASSWORD="password"
Build the project using Maven 3.3
mvn clean install
Create the database schema:
mvn flyway:migrate
Finally run the project:
mvn exec:java
- Improve performance refactoring the naming convention of the file keys by adding the the timestamp prefix (e.g.
YYYYMMDD-hhmmss
) and retrieving only new files - Implement unit and integration tests.
- Integrate with Netflix's Archaius to allow dynamic configuration.