diff --git a/spring-data-rest-webmvc/pom.xml b/spring-data-rest-webmvc/pom.xml
index 10bb4cd11..4e31622bb 100644
--- a/spring-data-rest-webmvc/pom.xml
+++ b/spring-data-rest-webmvc/pom.xml
@@ -88,6 +88,15 @@
json-patch
1.7
+
+
+
+
+ com.mysema.querydsl
+ querydsl-core
+ ${querydsl}
+ true
+
@@ -450,6 +459,33 @@
+
+
+ com.mysema.maven
+ apt-maven-plugin
+ ${apt}
+
+
+ com.mysema.querydsl
+ querydsl-apt
+ ${querydsl}
+
+
+
+
+ generate-test-sources
+
+ test-process
+
+
+ target/generated-sources/annotations
+ org.springframework.data.mongodb.repository.support.MongoAnnotationProcessor
+ true
+
+
+
+
+
diff --git a/spring-data-rest-webmvc/src/main/java/org/springframework/data/rest/webmvc/config/QuerydslAwareRootResourceInformationHandlerMethodArgumentResolver.java b/spring-data-rest-webmvc/src/main/java/org/springframework/data/rest/webmvc/config/QuerydslAwareRootResourceInformationHandlerMethodArgumentResolver.java
new file mode 100644
index 000000000..722a84b2a
--- /dev/null
+++ b/spring-data-rest-webmvc/src/main/java/org/springframework/data/rest/webmvc/config/QuerydslAwareRootResourceInformationHandlerMethodArgumentResolver.java
@@ -0,0 +1,109 @@
+/*
+ * Copyright 2015 the original author or authors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.springframework.data.rest.webmvc.config;
+
+import java.util.Arrays;
+import java.util.Map;
+
+import org.springframework.data.querydsl.QueryDslPredicateExecutor;
+import org.springframework.data.querydsl.QuerydslRepositoryInvokerAdapter;
+import org.springframework.data.querydsl.binding.QuerydslBindings;
+import org.springframework.data.querydsl.binding.QuerydslBindingsFactory;
+import org.springframework.data.querydsl.binding.QuerydslPredicateBuilder;
+import org.springframework.data.repository.support.Repositories;
+import org.springframework.data.repository.support.RepositoryInvoker;
+import org.springframework.data.repository.support.RepositoryInvokerFactory;
+import org.springframework.data.rest.webmvc.RootResourceInformation;
+import org.springframework.data.util.ClassTypeInformation;
+import org.springframework.util.LinkedMultiValueMap;
+import org.springframework.util.MultiValueMap;
+import org.springframework.web.method.support.HandlerMethodArgumentResolver;
+
+import com.mysema.query.types.Predicate;
+
+/**
+ * {@link HandlerMethodArgumentResolver} to create {@link RootResourceInformation} for injection into Spring MVC
+ * controller methods.
+ *
+ * @author Oliver Gierke
+ * @since 2.4
+ */
+class QuerydslAwareRootResourceInformationHandlerMethodArgumentResolver
+ extends RootResourceInformationHandlerMethodArgumentResolver {
+
+ private final Repositories repositories;
+ private final QuerydslPredicateBuilder predicateBuilder;
+ private final QuerydslBindingsFactory factory;
+
+ /**
+ * Creates a new {@link QuerydslAwareRootResourceInformationHandlerMethodArgumentResolver} using the given
+ * {@link Repositories}, {@link RepositoryInvokerFactory} and {@link ResourceMetadataHandlerMethodArgumentResolver}.
+ *
+ * @param repositories must not be {@literal null}.
+ * @param invokerFactory must not be {@literal null}.
+ * @param resourceMetadataResolver must not be {@literal null}.
+ */
+ public QuerydslAwareRootResourceInformationHandlerMethodArgumentResolver(Repositories repositories,
+ RepositoryInvokerFactory invokerFactory, ResourceMetadataHandlerMethodArgumentResolver resourceMetadataResolver,
+ QuerydslPredicateBuilder predicateBuilder, QuerydslBindingsFactory factory) {
+
+ super(repositories, invokerFactory, resourceMetadataResolver);
+
+ this.repositories = repositories;
+ this.predicateBuilder = predicateBuilder;
+ this.factory = factory;
+ }
+
+ /*
+ * (non-Javadoc)
+ * @see org.springframework.data.rest.webmvc.config.RootResourceInformationHandlerMethodArgumentResolver#postProcess(org.springframework.data.repository.support.RepositoryInvoker, java.lang.Class, java.util.Map)
+ */
+ @Override
+ @SuppressWarnings({ "unchecked" })
+ protected RepositoryInvoker postProcess(RepositoryInvoker invoker, Class> domainType,
+ Map parameters) {
+
+ Object repository = repositories.getRepositoryFor(domainType);
+
+ if (!QueryDslPredicateExecutor.class.isInstance(repository)) {
+ return invoker;
+ }
+
+ ClassTypeInformation> type = ClassTypeInformation.from(domainType);
+
+ QuerydslBindings bindings = factory.createBindingsFor(null, type);
+ Predicate predicate = predicateBuilder.getPredicate(type, toMultiValueMap(parameters), bindings);
+
+ return new QuerydslRepositoryInvokerAdapter(invoker, (QueryDslPredicateExecutor