Pinned Loading
-
extends JPA searchByExample to compa...
extends JPA searchByExample to compare attribute with null. (by default null means that example does not compare this attribute) 1public abstract class ExtraSpecification {
2public static <T> Specification<T> attributeNull(Example<T> example, String attributeName, boolean isNull) {
3return (root, query, builder) -> {
4List<Predicate> predicates = new ArrayList<>();
5if (isNull)
-
Spring configuration for RestTemplat...
Spring configuration for RestTemplate bean that create new RestTemplate with copy of initial user's AUTHORIZATION header 1import lombok.RequiredArgsConstructor;
2import org.springframework.boot.web.client.RestTemplateBuilder;
3import org.springframework.context.annotation.Bean;
4import org.springframework.context.annotation.Configuration;
5import org.springframework.http.HttpHeaders;
Something went wrong, please refresh the page to try again.
If the problem persists, check the GitHub status page or contact support.
If the problem persists, check the GitHub status page or contact support.