DATAVK-86 - Improved auto-template-registration infrastructure.
KeyValueRepositoryConfigurationExtension now need to report the default value for the KeyValueTemplate reference. We now only register a default template if the reference has not been customized. Changed the default reference value for Maps to mapKeyValueTemplate to allow individual defaults per store. Removed obsolete RepositoryNamespaceHandler. Original pull request: #1.
This commit is contained in:
@@ -114,7 +114,7 @@ public @interface EnableMapRepositories {
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
String keyValueTemplateRef() default "keyValueTemplate";
|
||||
String keyValueTemplateRef() default "mapKeyValueTemplate";
|
||||
|
||||
/**
|
||||
* Configures whether nested repository-interfaces (e.g. defined as inner classes) should be discovered by the
|
||||
|
||||
@@ -44,6 +44,15 @@ public class MapRepositoryConfigurationExtension extends KeyValueRepositoryConfi
|
||||
return "map";
|
||||
}
|
||||
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.data.keyvalue.repository.config.KeyValueRepositoryConfigurationExtension#getDefaultKeyValueTemplateRef()
|
||||
*/
|
||||
@Override
|
||||
protected String getDefaultKeyValueTemplateRef() {
|
||||
return "mapKeyValueTemplate";
|
||||
}
|
||||
|
||||
/*
|
||||
* (non-Javadoc)
|
||||
* @see org.springframework.data.keyvalue.repository.config.KeyValueRepositoryConfigurationExtension#getDefaultKeyValueTemplateBeanDefinition()
|
||||
|
||||
Reference in New Issue
Block a user