code: public static Specification<JpaTarget> hasAssignedDistributionSet(final Long distributionSetId) {
          return (targetRoot, query, cb) -> cb.equal(
                  targetRoot.<JpaDistributionSet> get(JpaTarget_.assignedDistributionSet).get(JpaDistributionSet_.id),
                  distributionSetId);
      }
docs: {@link Specification} for retrieving {@link Target}s by assigned
  distribution set.
  
  @param distributionSetId
  the ID of the distribution set which must be assigned
  @return the {@link Target} {@link Specification}