-
Notifications
You must be signed in to change notification settings - Fork 18
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
fix: query-patterns-should-not-be-separated DEV-2473 #2786
fix: query-patterns-should-not-be-separated DEV-2473 #2786
Conversation
Codecov ReportPatch coverage has no change and project coverage change:
Additional details and impacted files@@ Coverage Diff @@
## main #2786 +/- ##
==========================================
+ Coverage 18.00% 22.33% +4.33%
==========================================
Files 281 242 -39
Lines 28899 23394 -5505
==========================================
+ Hits 5202 5225 +23
+ Misses 23697 18169 -5528 ☔ View full report in Codecov by Sentry. |
DEV-2473 SAVE PROCESS SLOW
From Stefan Münnich (Webern): DescriptionSaving a new entry or even a small change (typo) sometimes takes a long time (more than 10 seconds). https://dasch.atlassian.net/jira/servicedesk/projects/DSQ/queues/custom/3/DSQ-221 The resource to reproduce the bug with the label "Guido Adler tritt in den Ruhestand": https://ark.dasch.swiss/ark:/72163/1/0806/9pCn9mtsTmSzenpSL4YIcQg.20230806T085533017083949Z Property label: "andere Quellen" Screenshot from Flavie's console log (Firefox, staging server): |
11548d3
to
0863bf4
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for spotting and fixing!
At some point we had a convention to name tests that use ZIO-Test ...ZSpec.scala
- not sure if we still do that? But if we do, you may want to rename the files.
I am happily ignoring this naming convention. Eventually all of our spec should be migrated to zio-test anyway. Also in the webapi/test source set zio-test should be the only available test framework. |
...org/knora/webapi/messages/util/search/gravsearch/transformers/ConstructTransformerSpec.scala
Outdated
Show resolved
Hide resolved
…avsearch/transformers/ConstructTransformerSpec.scala Co-authored-by: Marcin Procyk <marcin.procyk@dasch.swiss>
Pull Request Checklist
Task Description/Number
e351592 introduces a changed behaviour in how query patterns are transformed/optimized.
The create slow down reported in DEV-2473 is caused by this.
The gravsearch query which is used for retrieving the information of the resource to which a value should be created is containing a different optional block whilst the rest of the query still was the same.
The difference in runtime is enormous:
407 results in 0.083 seconds (fixed, old behaviour):
and
88198 results in 5.43 seconds (faulty behaviour):
In the faulty example if a match is found for the first triple pattern, it will return results that include that match, even if there is no match for the second triple pattern, and vice versa.
Basic Requirements
Please check if your PR fulfills the following requirements:
PR Type
What kind of change does this PR introduce?
Does this PR introduce a breaking change?
Does this PR change client-test-data?