Added exception and error count to have correct non zero-exit code in Jenkins. Replaced "return 1"s with exceptions. Restructured file system for upstream merge.