Commit Graph

13 Commits

Author SHA1 Message Date
Christoph Strobl
02759f58ea DATAKV-99 - Polishing.
Removed dedicated Entry<K,V> interface, since Map.Entry<K,V> is already sufficient. Favoured CloseableIterator over KeyValueIterator since it offers no additional functionality but less generic parameter clutter.
Added missing JavaDoc.
2015-05-13 12:53:44 +02:00
Christoph Strobl
952a901164 DATAKV-101 - Favor Iterable over Collection types for KeyValueOperations.
Change return types for Adapter and Operations from Collection types to Iterable. Added count(keyspace) to KeyValueAdapter.

Original pull request: #8.
2015-05-11 11:39:56 +02:00
Christoph Strobl
16dc4b5e7d DATAKV-99 - Add KeyValueIterator.
We now offer the possibility to iterate through available key/value pairs via a KeyValueIterator. The default implementation for java.util.Map based Adapters is a ForwardingKeyValueIterator delegating to the underlying entrySet iterator.

Original pull request: #7.
2015-05-11 11:26:31 +02:00
Christoph Strobl
07b3a1547c DATAKV-91 - Add support for sending application events.
We now allow definition of event types to be published via the application context.

Original pull request: #5.
2015-05-05 16:09:31 +02:00
Thomas Darimont
c305988582 DATAKV-96 - Added QueryDslPredicateExecutor.findAll(Predicate, Sort).
We now support findAll on QuerydslKeyValueRepository that accepts a Querydsl Predicate and a Sort.

Original pull request: #4.
2015-02-24 10:18:19 +01:00
Oliver Gierke
8f1bc111b4 DATAKV-95 - Added exists(…) method to QuerydslKeyValueRepository.
Renamed QueryDsl… classes to Querydsl… for consistency. Restructured test cases for repositories to make better use of generics.
2015-02-03 11:50:16 +01:00
Oliver Gierke
bc88cb48ac DATAKV-87 - Polished implementation of configurability of Map type on @EnableMapRepositories.
Removed the MapKeyValueAdapterFactory in favor of using instantiating MapKeyValueAdapters directly. Reverted additional hook in KeyValueRepositoryConfigurationExtension as we now rather use inner bean definitions.

Original pull request: #2.
2014-12-05 19:38:13 +01:00
Christoph Strobl
b16a454c6c DATAKV-87 - Allow definition of target Map type via @EnableMapRepositories.
We added the configuration attribute ‘mapType’ to @EnableMapRepositories which allows to change defaulting of the Map structure used by the MapKeyValueAdapter. To do so we now register a MapKeyValueAdapterFactory and delegate creation of the adapter to it. This also allows usage of interface types such as plain java.util.Map which will initialize the adapter with the approximated type resolved via CollectionFactory.

Original pull request #2.
2014-12-05 19:37:55 +01:00
Oliver Gierke
5a14d7bc12 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.
2014-12-01 16:35:28 +01:00
Christoph Strobl
ff1338a99c DATAKV-86 - Move configuration infrastructure for Map-based repositories.
We removed the EnableKeyValueRepositories in favor of store specific implementations. In this case EnableMapRepositories.

The configuration now defaults a KeyValueTemplate with a MapKeyValueAdapter but allows overriding the template in a bean named keyValueTemplate.
2014-12-01 16:13:01 +01:00
Christoph Strobl
4f37a7ecc3 DATAKV-90 - Add findAll variant with QueryDSL OrderSpecifier without a Predicate. 2014-11-28 15:17:51 +01:00
Christoph Strobl
5f62882a3e DATAKV-89 - KeyValueTemplate now throws DuplicateKeyException.
We now throw DuplicateKeyException instead of InvalidDataAccessApiUsageException in case an object with given id already exists.

Original pull request: spring-projects/spring-data-commons#106.
2014-11-27 14:30:22 +01:00
Oliver Gierke
42a13a7403 DATAKV-85 - Ported key-value infrastructure from Spring Data Commons. 2014-11-27 14:19:30 +01:00