Merge pull request #351 from stianst/constraints

Ensure application and client names are unique within realm