Commit Graph

1333 Commits

Author SHA1 Message Date
Oliver Gierke
e79d70cb13 DATACMNS-1215 - Fixed repository lookup for proxy domain classes.
We now consistently use the user class for repository (metadata) lookup in Repositories.
2017-11-17 10:16:59 +01:00
Oliver Gierke
6199fed1c1 DATACMNS-1214 - Fixed AbstractMappingContext.getPersistentEntity(PersistentProperty) to now return null for non-entities.
Previously, a call to AbstractMappingContext.getPersistentEntity(PersistentProperty) would've added potentially leniently added the type of the given PersistentProperty, no matter whether it's actually considered to be an entity in the first place. We now defensively check for whether the given property is to be considered an entity (taking potentially registered converters into account) before the potentially entity-creating by-type lookup.
2017-11-16 16:34:31 +01:00
Oliver Gierke
b07d7a1064 DATACMNS-1185 - Updated changelog. 2017-10-27 16:36:43 +02:00
Oliver Gierke
5edcdefe58 DATACMNS-1180 - Polishing.
Avoid premature resolution of type in TypeDiscoverer.createInfo(…) and thereby simplify constructor in ParameterizedTypeInformation.
2017-10-26 23:35:28 +02:00
Oliver Gierke
ce8d923382 DATACMNS-1180 - Fixed accessor lookup for generic properties.
In AbstractPersistentProperty, we now resolve the potentially generic return and parameter types of getters and setters.
2017-10-26 23:35:22 +02:00
Mark Paluch
14a56dee00 DATACMNS-1201 - Support generated property accessors for types in default packages.
We now support generated property accessors for types that reside in the default package.

Original pull request: #256.
2017-10-25 09:36:43 +02:00
Oliver Gierke
d0d0d72c98 DATACMNS-1196 - Fixed generics lookup for nested generics in ParameterizedTypeInformation.
We now eagerly resolve a generics declaration chain, which we previously - erroneously - expected GenericTypeResolver to do for us. Simplified TypeVariableTypeInformation implementation. Renamed ParameterizedTypeUnitTests to ParameterizedTypeInformationUnitTests.
2017-10-12 18:19:15 +02:00
Oliver Gierke
91fd1a4caf DATACMNS-1155 - After release cleanups. 2017-10-11 19:00:14 +02:00
Oliver Gierke
000596f8d7 DATACMNS-1155 - Prepare next development iteration. 2017-10-11 19:00:09 +02:00
Oliver Gierke
73f4ff3dcf DATACMNS-1155 - Release version 1.13.8 (Ingalls SR8). 2017-10-11 16:42:42 +02:00
Oliver Gierke
a46757efb9 DATACMNS-1155 - Prepare 1.13.8 (Ingalls SR8). 2017-10-11 16:41:07 +02:00
Oliver Gierke
21cdbe8b58 DATACMNS-1155 - Updated changelog. 2017-10-11 16:40:54 +02:00
Oliver Gierke
b7a9b09b7c DATACMNS-901 - AbstractMappingContext publishes entity added events outside the write lock.
Previously, the publication of the event that indicated a PersistentEntity having been added to it took place before the write lock over the entities had been released. We now keep the lock smaller and publish the addition event *after* the lock has been released.
2017-10-10 16:35:44 +02:00
stonio
38d39a47e9 DATACMNS-1193 - Fixed typo in JavaDoc and reference documentation of PageableDefaults.
Original pull request: #218.
2017-10-10 11:51:14 +02:00
Mark Paluch
c634199b7c DATACMNS-1156 - Updated changelog. 2017-10-02 11:41:21 +02:00
Oliver Gierke
cd1efe45fd DATACMNS-1182 - Reinstantiate Java 6 compatibility of QueryExecutionConverters.
Replace reference to JDK 8's Stream through lenient reflection lookup.
2017-10-01 18:36:15 +02:00
Oliver Gierke
8c6c2da0ba DATACMNS-1172 - Polishing.
Tweaked newly introduced RepositoryConfiguration.getImplementationBasePackage() to not require a parameter but use internal information instead (the repository interface in DefaultRepositoryConfiguration).

Original pull request: #248.
2017-09-27 13:12:58 +02:00
Mark Paluch
318cf9b1b8 DATACMNS-1172 - Limit repository custom implementation scanning to repository interface packages.
Custom repository implementation scan uses the repository interface package and its subpackages and no longer scans all configured base packages. Scan for fragment implementations defaults to the fragment interface package. Using the interface package for scanning aligns the behavior with the documentation.

Declaring the implementation along with the interface in the same package is an established design pattern allowing to limit the scanning scope. A limited scope improves scanning performance as it can skip elements on the classpath, that do not provide that particular package.

Previously, we scanned for implementations using the configured base packages that were also used to discover repository interfaces. These base packages can be broader for applications that spread repository interfaces across multiple packages.

Original pull request: #248.
2017-09-27 13:12:55 +02:00
Jens Schauder
67adc4e935 DATACMNS-1177 - Polishing.
Removed redundant static keywords on inner enums.

Original pull request: #249.
2017-09-27 11:42:42 +02:00
Oliver Gierke
4de44b4ded DATACMNS-1177 - Polishing.
Formatting. JavaDoc.

Original pull request: #249.
2017-09-27 11:42:39 +02:00
Jens Schauder
c7ba2926bd DATACMNS-1177 - Parameter.isDynamicProjectionParameter() uses unwrapped type instead of actual type.
When trying to determine if a parameter is a dynamic projection parameter, i.e. the parameter of type Class that determines the projection to use, now the type parameter of that method parameter gets compared with the unwrapped return type. Therefore this works now not only for Maps and Collections but also for the various wrappers defined in QueryExecutionConverters.

Moved the method for unwrapping the return type from AbstractRepositoryMetadata to QueryExecutionConverters in order to make it available to every class needing it. This also puts it closer to the data it is working on.

Original pull request: #249.
2017-09-27 11:42:29 +02:00
Oliver Gierke
6b68a5dde1 DATACMNS-1166 - Upgrade to Vavr 0.9.1. 2017-09-21 09:25:26 +02:00
Oliver Gierke
c82344fdb3 DATACMNS-1163 - EventPublishingInterceptor now prefers arguments over return values for event publication.
We now prefer to inspect the arguments handed to save(…) methods over inspecting the return value as the invocation of the actual method is free to exchange the instance handed into it and return a completely new one with the events contained in the parameter completely wiped.
2017-09-20 11:09:50 +02:00
Oliver Gierke
032d693fa1 DATACMNS-1130 - Updated changelog. 2017-09-11 17:42:38 +02:00
Mark Paluch
4564108c62 DATACMNS-1131 - After release cleanups. 2017-09-11 12:23:36 +02:00
Mark Paluch
c9377b719f DATACMNS-1131 - Prepare next development iteration. 2017-09-11 12:23:35 +02:00
Mark Paluch
39091974d4 DATACMNS-1131 - Release version 1.13.7 (Ingalls SR7). 2017-09-11 11:45:05 +02:00
Mark Paluch
4899154bba DATACMNS-1131 - Prepare 1.13.7 (Ingalls SR7). 2017-09-11 11:44:20 +02:00
Mark Paluch
92c4fc5a76 DATACMNS-1131 - Updated changelog. 2017-09-11 11:44:12 +02:00
Oliver Gierke
154db22ade DATACMNS-1011 - Rewrote chapter on repository projections. 2017-09-08 15:45:42 +02:00
Johnny Lim
a8c7de0683 DATACMNS-1153 - Removed unreachable assertion in XmlRepositoryConfigurationSource.
Original pull request: #236.
2017-09-07 15:22:48 +02:00
Oliver Gierke
a2f8dc1676 DATACMNS-1152 - Setup of ProjectingJackson2HttpMessageConverter now tries to use unique ObjectMapper from ApplicationContext.
We're now trying to look up a uniquely available ObjectMapper instance from the application context falling back to a simple new instance in case none can be found.
2017-09-06 18:49:01 +02:00
Mark Paluch
e8fad19bc0 DATACMNS-1151 - Define generated PropertyAccessor classes with the entity protection domain.
We now define generated PropertyAccessor classes using the entities' protection domain. Reusing the same protection domain preserves the same security and visibility rules as if the class was shipped within the source of the class loaded and prevents SecurityExceptions caused by signature certificate mismatch.

Previously we uses the protection domain of the PersistentEntity class implementation. This mismatch caused SecurityExceptions if the JAR file of the PersistentEntity was signed but not the JAR file where the domain class resides.

Original pull request: #240.
2017-09-05 12:01:21 +02:00
Oliver Gierke
2bfd278861 DATACMNS-1145 - @JsonPath value lookup now returns null for non-existent paths.
If a JSONPath expression is using a path not available in the backing payload we now return null rather than letting the PathNotFoundException propagate.
2017-08-24 15:47:44 +02:00
Oliver Gierke
3ffb18597b DATACMNS-1143 - Improve design of AbstractAggregateRoot.
Methods for domain event registration and access are now not following bean semantics anymore to avoid those accidentally leaking into formats that use the bean spec (e.g. Jackson to produce JSON). 

Deprecated old accessor methods and temporarily add @JsonIgnore to the method to avoid leakage but keep signatures intact.
2017-08-23 15:49:10 +02:00
Oliver Gierke
766c9078f2 DATACMNS-1139 - AbstractPersistentProperty.getRawType() now correctly resolves generics.
We're now favoring the generic TypeInformation over trying to resolve the property type via field or PropertyDescriptor as only the former does proper generic type resolution.
2017-08-14 13:40:52 +02:00
Oliver Gierke
8638d30a00 DATACMNS-1138 - TypeInformation.specialize(…) now only specializes unresolved parameterized types.
Type specialization - i.e. enrichment of a raw type with a current generic context - is now only done if the current type is not yet resolved completely. This allows wildcarded target references to just fall back to the type to specialize, which will then by definition carry more generics information than the one to be specialized.
2017-08-11 15:54:33 +02:00
Oliver Gierke
e7434a0e77 DATACMNS-1135 - Fixed generics lookup for recursively nested container references.
Revert the merging of a parent type's type variable map and only apply the locally available declared generics in case of parameterized types. Moved that augmentation into ParameterizedTypeInformation.
2017-08-03 11:36:45 +02:00
Oliver Gierke
2e633d2a2f DATACMNS-1127 - After release cleanups. 2017-07-27 00:21:37 +02:00
Oliver Gierke
38fdb0aa4f DATACMNS-1127 - Prepare next development iteration. 2017-07-27 00:15:07 +02:00
Oliver Gierke
4734df4860 DATACMNS-1127 - Release version 1.13.6 (Ingalls SR6). 2017-07-26 23:47:19 +02:00
Oliver Gierke
765fea0cda DATACMNS-1127 - Prepare 1.13.6 (Ingalls SR6). 2017-07-26 23:45:51 +02:00
Oliver Gierke
7caf6be1f9 DATACMNS-1127 - Updated changelog. 2017-07-26 23:45:37 +02:00
Oliver Gierke
160681f0e2 DATACMNS-1128 - Updated changelog. 2017-07-25 16:15:39 +02:00
Oliver Gierke
a519e8f8f7 DATACMNS-1090 - Updated changelog. 2017-07-25 10:03:53 +02:00
Oliver Gierke
532d4e4eba DATACMNS-1084 - After release cleanups. 2017-07-24 19:25:07 +02:00
Oliver Gierke
dd56129b02 DATACMNS-1084 - Prepare next development iteration. 2017-07-24 19:25:05 +02:00
Oliver Gierke
9e1dc0dc86 DATACMNS-1084 - Release version 1.13.5 (Ingalls SR5). 2017-07-24 18:44:17 +02:00
Oliver Gierke
a73a62dc8c DATACMNS-1084 - Prepare 1.13.5 (Ingalls SR5). 2017-07-24 18:43:22 +02:00
Oliver Gierke
bbb19ff092 DATACMNS-1084 - Updated changelog. 2017-07-24 18:43:10 +02:00