Only use count() optimization if there are no joins

The count() helper optimization only works if the current query.statement performs no JOINs.
However, if a relation is set to use joined-load, the current query.statement will perform a
join, and the count() helper will return a number that is the number of objects found for
the current endpoint *multiplied* by the number of objects in the joined-loaded relation.
allow disabling deep results per-request

originally by @johaness
allow fine grained control of relations included in output
bump to 1.current-upstream-version
support deep parameter in PUT/PATCH

follow up to d85b91e0d5d133ddb989d31ce98ae4f385d2432f and dc06ae4ae75994d354db8bbe62532bd04da0b5ac
search: joined load of all deep relations
limit joins to 3 levels
bump version number to Major.minor.revision.1