public static Specification<User> nameLike(final String query) {
		return (Specification<User>) (root, criteriaQuery, cb) -> {
			String pattern = ("%" + query + "%").toLowerCase();
			return cb.or(cb.like(cb.lower(root.get("userName").as(String.class)), pattern),
					cb.like(cb.lower(root.get("userId").as(String.class)), pattern));
		};
	}
Create "Name Like" query spec.
@param query query
@return created spec
ngrinder-controller/src/main/java/org/ngrinder/user/repository/UserSpecification.java