DATACMNS-306 - RepositoryBeanDefinitionBuilder not correctly sets source.

Previously, the RepositoryBeanDefinitionBuilder did not forward the repository configuration's source instance into the built BeanDefinitions. This is now fixed to enable STS track the origin of the BeanDefinition back to the configuration source (an @Enable-annotation or an XML namespace element).
This commit is contained in:
Oliver Gierke
2013-03-28 18:53:17 +01:00
parent e8b2db8463
commit 64dada5896
2 changed files with 13 additions and 2 deletions

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012 the original author or authors.
* Copyright 2012-2013 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.
@@ -81,6 +81,7 @@ public class RepositoryBeanDefinitionBuilder {
BeanDefinitionBuilder builder = BeanDefinitionBuilder.rootBeanDefinition(factoryBeanName);
builder.getRawBeanDefinition().setSource(configuration.getSource());
builder.addPropertyValue("repositoryInterface", configuration.getRepositoryInterface());
builder.addPropertyValue("queryLookupStrategyKey", configuration.getQueryLookupStrategyKey());