add spock tests for trial
reorganise packages
add equals and hash methods in model class
experiment with shutdown hook