Collections with dots

Fixes #2548.

- Don't try to read in directories as documents
- Allow collection labels to have dots
Should be fine. Where ever this is used, the full canonicalized path should still be checked before file access.