abstract message texts

make thrown exceptions configurable
make it possible to add replacements