-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Return details for a project namespace
The solr query is amended with another subquery to resolve existing `namespace` fields in the search results. This is only interesting for projects, as these entities use that field denoting "being in that namespace". `Group` and `User` entities on the other hand use the `namespace` field to *define* this namespace. So the sub-query is constraint to only `User` or `Group` entities. Solr applies this to all result documents, but it is only decoded for projects. `User` and `Group` entities resolve to themselves. So we potentially transfer lots of data from solr only to discard it, sadly. I couldn't find a way around it with the current model. It would be nice to have a clear distinction between defining the namespace and being a member of it (using different fields), but unfortunately we decided against that in the past. The search http api *replaces* the value of the `namespace` field with the full object of either `User` or `Group` in its results, making this a breaking change wrt the search api result structure. Since SOLR cannot guarantee to have a `User` or `Group` being resolved given a namespace, the result is defined as optional. When this happens an error is logged and `None` is returned as a result.
- Loading branch information
Showing
14 changed files
with
194 additions
and
69 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Oops, something went wrong.