mirror of
https://github.com/moodle/moodle.git
synced 2025-04-06 08:52:46 +02:00
Due to Solr bug SOLR-15039, uploading files for indexing can fail if it uses multipart upload. This changes it to use direct binary upload. Unfortunately, the direct binary version in PHP curl only supports a string, so we have to load the file into memory. I added extra code to restrict the size of files indexed to (memory limit - 100MB), which is usually 284MB unless configured differently because cron runs under MEMORY_EXTRA.