Permalink
Switch branches/tags
Commits on Jul 21, 2017
  1. DATACMNS-1122 - Improve message for absent required property in Persi…

    …stentEntity.getRequiredPersistentProperty(…).
    
    Exception message now contains the property name.
    mp911de committed Jul 21, 2017
Commits on Jul 20, 2017
  1. DATACMNS-1118 - Inherit Project Reactor version from dependency manag…

    …ement.
    
    Adapt to BOM import in Spring Data Build pom.
    mp911de committed Jul 20, 2017
  2. DATACMNS-1121 - ProxyProjectionFactory now returns instance as is if …

    …it implements the target.
    
    If you previously asked ProxyProjectionFactory for a proxy of an interface which the target instance already implements, it created a proxy although it could've returned the instance as is. It's now actually doing that avoiding superfluous proxy creation.
    olivergierke committed Jul 20, 2017
  3. DATACMNS-1120 - Introduced caching of PropertyPath instances.

    olivergierke committed Jul 20, 2017
  4. DATACMNS-1119 - Cache for ClassTypeInformation is now a ConcurrentRef…

    …erenceHashMap.
    olivergierke committed Jul 20, 2017
  5. DATACMNS-1117 - Fixed creation of RepositoryInformation in Repository…

    …FactoryBeanSupport.
    
    RepositoryFactoryBeanSupport.getRepositoryInformation() previously didn't consider any store-specific compositions (incl. store-specific fragments like the Querydsl support) as it just handed a fragment with the custom implementation to RepositoryFactorySupport.
    
    This is now fixed by improving the API in RepositoryFactorySupport which now exposes a getRepositoryInformation(RepositoryMetadata, RepositoryFragments) which creates a fresh RepositoryComposition from the given RepositoryMetadata. Intermediate setup methods are still kept around but private as RepositoryFactorySupport.getRepository(…) still needs to forward the base RepositoryComposition to method interceptors for query result mapping.
    olivergierke committed Jul 20, 2017
Commits on Jul 19, 2017
  1. DATACMNS-1116 - AbstractMappingContext now caches PersistentPropertyP…

    …aths.
    
    As the calculation of a PersistentPropertyPath instances is rather expensive and they're heavily used in downstream mapping operations (e.g. query and fields mapping in MongoDB) we now cache the instances created per base type and property path.
    olivergierke committed Jul 19, 2017
Commits on Jul 18, 2017
  1. DATACMNS-1115 - Improve RepositoryBeanNameGenerator to properly resol…

    …ve bean names for indexed BeanDefinitions.
    
    Previously, RepositoryBeanNameGenerator applied the custom bean name lookup if the BeanDefinition given was not a ScannedGenericBeanDefinition. That in turn had been the case for custom implementation classes that were obtained through classpath scanning. With Spring 5 an index file can be used by the scanner, which in turn will cause AnnotatedGenericBeanDefinition instances being returned. That caused the code path to lookup the first constructor argument to kick in (usually used to obtain the repository interface from repository factory beans) and cause a NullPointerException.
    
    We now forward AnnotatedBeanDefinitions as is and only apply the custom lookup for everything else, i.e. the bean definitions used for the factories.
    olivergierke committed Jul 18, 2017
Commits on Jul 17, 2017
  1. DATACMNS-1113 - Deprecated MappingContext.getPersistentPropertyPath(I…

    …nvalidPersistentPropertyPath).
    
    Deprecated the additional method in favor if a lookup via MappingContext.getPersistentPropertyPath(PropertyPath) using the resolvable PropertyPath exposed by InvalidPersistentPropertyPath.
    olivergierke committed Jul 17, 2017
Commits on Jul 12, 2017
  1. DATACMNS-1109 - Reinstantiate support for all date/time APIs in audit…

    …ing.
    
    Re-enabled test cases for handling of different date/time APIs in auditing. Tweaked the lookup of the last modified value to try to convert to LocalDateTime as well in case it's a subtype of the type requested. In combination with two newly introduced converters for local date type times in JodaTime and ThreeTenBP, this allows us to still convert legacy JodaTime and ThreeTenBP types to be used as well.
    olivergierke committed Jul 12, 2017
  2. DATACMNS-1112 - Cache instances of ReturnedType to avoid repeated ref…

    …lection inspection.
    
    We now keep instances of ReturnedType around to avoid the repeated reflection inspection for constructor and parameter name detection for class types and projection information for interfaces.
    olivergierke committed Jul 12, 2017
  3. DATACMNS-1110 - Introduced StreamUtils.createStreamFromIterator(Close…

    …ableIterator).
    
    This is an overload for the already existing method taking a plain Iterator so that we only apply the close callback to the Stream in the newly introduced one.
    olivergierke committed Jul 12, 2017
Commits on Jul 11, 2017
  1. DATACMNS-1107 - Polishing.

    Moved methods around in ProjectionFactory implementations to follow the coding guidelines.
    olivergierke committed Jul 11, 2017
  2. DATACMNS-1107 - ProxyProjectionFactory now caches ProjectionInformati…

    …on instances.
    
    To avoid the repeated scanning of projection interfaces for property descriptors we now cache the ProjectionInformation instances created via ProjectionFactory.getProjectionInformation(…). Adapted SpelAwareProxyProjectionFactory to now apply its customizations in newly introduced createProjectionInformation(…).
    olivergierke committed Jul 11, 2017
  3. DATACMNS-1106 - Removed deprecations in ProjectionFactory.

    Removed the deprecated implementation of ResourceLoaderAware in favor of BeanClassLoaderAware. Removed deprecated ProjectionFactory.getInputProperties() in favor of ….getProjectionInformation(). Removed the Java conditional to add a MethodInterceptor for default methods. Adapted test cases.
    olivergierke committed Jul 11, 2017
Commits on Jul 7, 2017
  1. DATACMNS-1104 - Changed scope of Degraph dependency to 'test’.

    schauder committed Jul 7, 2017
Commits on Jul 6, 2017
  1. DATACMNS-1097 - Polishing.

    Updated Sonargraph architecture description. Polished imports in domain package to avoid unnecessary imports (mostly due to Javadoc references).
    
    Removed manually declared constructor in ExampleMatcherAccessor in favor of Lombok's @RequiredArgsConstructor. Removed deprecations in type information subsystem. Moved to different way of class loading to avoid null pointer warnings in ReflectionUtils.
    olivergierke committed Jul 5, 2017
  2. DATACMNS-1097 - Move classes to better matching packages.

    Introduced new ExampleMatcherAccessor in data.support in favor of the now deprecated one in data.repository.core to avoid a dependency into the repositories subsystem to work with examples in general.
    
    Added Degraph based test in order to avoid future cyclic package dependency violations.
    
    Original pull request: #230.
    Related ticket: DATAMONGO-1721.
    schauder committed with olivergierke Jun 22, 2017
Commits on Jul 5, 2017
  1. DATACMNS-1102 - Reuse ConversionService in ProjectingMethodIntercepto…

    …rs created by ProxyProjectionFactory.
    
    Applied the same to internals of MapDataBinder.
    olivergierke committed Jul 5, 2017
Commits on Jul 4, 2017
  1. DATACMNS-1101 - Use dedicated type to cache custom conversion targets…

    … without requested target type.
    
    We now use a marker interface to store cache hits for conversion targets without requesting a conversion target in the conversion query. The dedicated marker type has an individual cache view and does not interfere with other types.
    
    Previously we used Object as cache key which caused false positives due to assignability checks. If an earlier conversion query with a requested target type yielded a hit (e.g. negative hit), subsequent queries without a target type received the same answer. This might happen although the non-cached answer would return a different result.
    mp911de committed with olivergierke Jul 3, 2017
  2. DATACMNS-1101 - Remove getPersistentProperties/Associations from Pers…

    …istentEntity.
    
    Remove lately introduced getPersistentProperties / getAssociations and rather extend Iterable<? extends PersistentProperty<P>>
    christophstrobl committed with olivergierke Jul 3, 2017
  3. DATACMNS-1101 - Polishing.

    Move MappingException from o.s.d.mapping.model to o.s.d.mapping package and use it for getRequired* methods in MappingContext instead of throwing IllegalArgumentException. Further on we’ve consolidated usage of IllegalArgumentException and IllegalStateException. Along that IllegalMappingException was removed in favor or MappingException.
    
    BasicPersistentEntity now looks up all properties by annotation instead of just returning the first one found. We’ve kept the original methods behavior and updated the comment as well as introduced getPersistentProperties returning all matching properties.
    christophstrobl committed with olivergierke Jun 30, 2017
  4. DATACMNS-1101 - Adapt API changes in PropertyAccessor from MappingAud…

    …itableBeanWrapperFactory.
    
    We now avoid wrapping the value into an Optional as PropertyAccessor now takes Object as parameter right away.
    olivergierke committed Jul 3, 2017
  5. DATACMNS-1101 - Remove Optional from PersistentProperty.getComponentT…

    …ype(…)/getMapValueType(…).
    mp911de committed with olivergierke Jun 29, 2017
  6. DATACMNS-1101 - Remove Alias.ofOptional(…).

    Refactored type alias detection invocation in BasicPersistentEntity into separate method and avoid the factory method Alias.ofOptional(…) so that it can be removed.
    olivergierke committed Jul 3, 2017
  7. DATACMNS-1101 - Alias is no longer based on Optional.

    Remove internal Optional usage from Alias so it's a pure value object that does not create Optional instances during its usage.
    mp911de committed with olivergierke Jun 28, 2017
  8. DATACMNS-1101 - Replace Stream usage in SimpleTypeHolder with loops.

    Use loops to prevent Stream allocation in isSimpleType(…). Use WeakHashMap for type caching for improved contains(…) performance and GC behavior.
    mp911de committed with olivergierke Jun 28, 2017
  9. DATACMNS-1101 - Apply caching to frequently used flags in AnnotationB…

    …asedPersistentProperty.
    mp911de committed with olivergierke Jun 28, 2017
  10. DATACMNS-1101 - Use construction object array pooling.

    Use a thread-local object pool for constructor arguments to reduce object allocations.
    mp911de committed with olivergierke Jun 28, 2017
  11. DATACMNS-1101 - Refactor CustomConversion to use two-level caching.

    We now use a two-level cache instead of using a composite cache key to reduce object allocations.
    mp911de committed with olivergierke Jun 28, 2017