Create a checksum of the config file in memory#34146
Create a checksum of the config file in memory#34146ativarsoft wants to merge 3 commits intonextcloud:stable24from
Conversation
Signed-off-by: Mateus de Lima Oliveira <mateus@ativarsoft.com>
Check if config file exists before trying to read it. Signed-off-by: Mateus de Lima Oliveira <mateus@ativarsoft.com>
Changed comment style to make the linter like it. Signed-off-by: Mateus de Lima Oliveira <mateus@ativarsoft.com>
|
As reference: #34099 Thanks for creating a new version of your pull request 👍 Our usual workflow is that pull request target master as branch. Please don't forget to add the logging output (as requsted in the old pull request) to figure out what the actual issue is. The configuration file is only rewritten (and the opcache cleared) when a change is detected: Lines 158 to 164 in c2dafb0 |
|
The log is empty, Daniel. |
|
Hey, when you change the target branch you may need to rebase your pull request. Right now all commits from stable24 which are not in master are also referenced. |
|
@kesselb, I have no idea how to resolve those rebase conflicts. |
|
It depends a bit on your local setup. When people are working with a fork they usually add another remote "upstream".
Then run Afterwards rebase your local branch with the upstream changes GitHub documentation: https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/working-with-forks |
| $data = var_export($this->cache, true); | ||
| $currentChecksum = crc32($data); | ||
|
|
||
| if ($this->getLastChecksum() == $currentChecksum) |
There was a problem hiding this comment.
This will never be true, the checksum computed from file use the whole file content while the current one use only the data.
|
Any reason this PR is against stable24? Do we have a equivalent for master? |
|
Closing the pull request due to inactivity. |
This fixes a massive performance bug when opcache is enabled.
Signed-off-by: Mateus de Lima Oliveira mateus@ativarsoft.com