some simplification of resource construction from query and container construction