fixes and tests for batch-loader and registry