-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
backport search in shared files to stable5 #5487
backport search in shared files to stable5 #5487
Conversation
@DeepDiver1975 @karlitschek @schiesbn @icewind1991 please review. |
👍 |
Test passed. |
Found a bug that blocks merging. I'll ping you all again when this can be reviewed further. |
@DeepDiver1975 @schiesbn @icewind1991 fixed problem, please review by sharing a folder or file to anohter user and try searching in shared files. If you want to be thorough search for something that will give more than 1000 results. |
Test passed. |
need to create a few test files ❓
|
🔙
|
reducing the chunk count to 998 finally solved the issue on my installation |
$result = $query->execute(array_merge(array($mimetype), $ids)); | ||
return $result->fetchAll(); | ||
|
||
$files = array(); |
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.
This block is a 98% copy of the block above.
@bantu @DeepDiver1975 please review the cleanup |
* @param string $wherevalue | ||
* @return array | ||
*/ | ||
private function searchWithWhere ($sqlwhere, $wherevalue, $chunksize = self::MAX_SQL_CHUNK_SIZE) { |
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.
No space. searchWithWhere ($sqlwhere
Test failed. |
Test passed. |
- extract method, - introduce MAX CHUNK SIZE const with 999 (reduce this by the number of additional query parameters), - fix whitespace
@DeepDiver1975 @bantu @karlitschek more eyes? |
👍 |
Test passed. |
@bantu @DeepDiver1975 cleaned up the last whitespace changes. |
I'm getting this error on Oracle: And it looks like errors are not properly handled:
|
@DeepDiver1975 seems I was counting the wrong array. also need to fix this in master |
Test passed. |
@karlitschek @DeepDiver1975 eyes please! |
I tested it, works as expected 👍 |
…s_to_stable5 backport search in shared files to stable5
just to confirm: retested on oracle and it works |
backport of #4207