- Notifications
You must be signed in to change notification settings - Fork 1.1k
DATAMONGO-899, DATAMONGO-909, DATAMONGO-827 - Overhaul index creation. #168
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Closed
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
christophstrobl added a commit that referenced this pull request Apr 14, 2014
… entities. Index creation did not consider the properties path when creating the index. This lead to broken index creation when nesting entities that might require index structures. Off now index creation traverses the entities property path for all top level entities (namely those holding the @document annotation) and creates the index using the full property path. This is a breaking change as having an entity to carry the @document annotation has not been required by now. Original Pull Request: #168
christophstrobl added a commit that referenced this pull request Apr 15, 2014
… entities. Index creation did not consider the properties path when creating the index. This lead to broken index creation when nesting entities that might require index structures. Off now index creation traverses the entities property path for all top level entities (namely those holding the @document annotation) and creates the index using the full property path. This is a breaking change as having an entity to carry the @document annotation has not been required by now. Original Pull Request: #168
Member
| Looks decent to me. Would you mind giving the |
christophstrobl added a commit that referenced this pull request Apr 23, 2014
… entities. Index creation did not consider the properties path when creating the index. This lead to broken index creation when nesting entities that might require index structures. Off now index creation traverses the entities property path for all top level entities (namely those holding the @document annotation) and creates the index using the full property path. This is a breaking change as having an entity to carry the @document annotation has not been required by now. Original Pull Request: #168
Prepare issue branch.
… entities. Index creation did not consider the properties path when creating the index. This lead to broken index creation when nesting entities that might require index structures. Off now index creation traverses the entities property path for all top level entities (namely those holding the @document annotation) and creates the index using the full property path. This is a breaking change as having an entity to carry the @document annotation has not been required by now. Original Pull Request: #168
…orrectly. With the overhaul of the index creation done in DATAMONGO-899 the CompoundIndex annotation is not longer just looked up at the concrete type but rather all its interfaces and super classes. So we just added an additional test to verify this behaviour.
We now support letting MongoDB generate index names by introducing the attribute "useGeneratedName" to the @indexed, @GeoSpatialIndex, @CompoundIndex annotations.
christophstrobl added a commit that referenced this pull request Apr 28, 2014
… entities. Index creation did not consider the properties path when creating the index. This lead to broken index creation when nesting entities that might require index structures. Off now index creation traverses the entities property path for all top level entities (namely those holding the @document annotation) and creates the index using the full property path. This is a breaking change as having an entity to carry the @document annotation has not been required by now. Original Pull Request: #168
odrotbohm added a commit that referenced this pull request Apr 28, 2014
Removed the introduction of the IndexDefinition being collection aware again. The collection an index is created in is now held in the IndexDefinitionHolder. This is mostly due to the fact that the IndexDefinition implementations can be used with MongoTemplate and the index opoerations take a collection alongside the index definition. Made the IndexResolver API package protected so that we can further change it going forward. We should think about deprecating the collectionName attributes on index annotations as it doesn't make too much sense to manually configure the collection name for the indexes as the collection is predefined through the domain type setting here. This would allow us to remove the entire collection handling code inside the IndexResolver implementation. Turned IndexDefinitionHolder into a value object. Original pull request: #168.
This was referenced Dec 30, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Add this suggestion to a batch that can be applied as a single commit. This suggestion is invalid because no changes were made to the code. Suggestions cannot be applied while the pull request is closed. Suggestions cannot be applied while viewing a subset of changes. Only one suggestion per line can be applied in a batch. Add this suggestion to a batch that can be applied as a single commit. Applying suggestions on deleted lines is not supported. You must change the existing code in this line in order to create a valid suggestion. Outdated suggestions cannot be applied. This suggestion has been applied or marked resolved. Suggestions cannot be applied from pending reviews. Suggestions cannot be applied on multi-line comments. Suggestions cannot be applied while the pull request is queued to merge. Suggestion cannot be applied right now. Please check back later.
Index creation did not consider the properties path when creating the index. This lead to broken index creation when nesting entities that might require index structures.
Off now index creation traverses the entities property path for all top level entities (namely those holding the
@Documentannotation) and creates the index using the full property path.This is a breaking change as having an entity to carry the
@Documentannotation has not been required by now.We ensure that
@CompoundIndexis properly looked up on both interfaces and super classes.We introduced
useGeneratedName(defaulted to false) on@Indexed,@CompoundIndexand@GeoSpatialIndexedto allow mongodb auto creating the index name.