Re-write of config handling. Now uses annotations