Enforce correct resource types with annotations.