In Puppet 4, resource collectors cannot use resource references in the search expression. This is an ability that did work in Puppet 3 and is currently in the documentation for Puppet 4.
The following code in Puppet,
File<| notify == Service['foo'] |>
produces the error,
Error: Evaluation Error: Error while evaluating a Virtual Query, Cannot transform object of class Puppet::Pops::Model::AccessExpression at /private/tmp/collection.pp:1:1 on node tom-mbp