Skip to content

Commit ca32f74

Browse files
docs: update meta invalidation comment for file events
Signed-off-by: Josh <josh.t.richards@gmail.com>
1 parent 3d83fe1 commit ca32f74

1 file changed

Lines changed: 8 additions & 8 deletions

File tree

lib/Service/MetaService.php

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -28,25 +28,25 @@
2828
* Therefore, the Notes app maintains this information on its own. It is saved
2929
* in the database table `notes_meta`. To be honest, we do not store the exact
3030
* changed time, but a time `t` that is at some point between the real changed
31-
* time and the next synchronization time. However, this is totally sufficient
31+
* time and next synchronization time. However, this is totally sufficient
3232
* for this purpose.
3333
*
34-
* Therefore, on synchronization, the method `MetaService.getAll` is called.
35-
* It generates an ETag for each note and compares it with the ETag from
34+
* Therefore, on synchronization, the method `MetaService::getAll` is called.
35+
* It generates an ETag for each note and compares it with the ETag from the
3636
* `notes_meta` database table in order to detect changes (or creates an entry
3737
* if not existent). If there are changes, the ETag is updated and `LastUpdate`
3838
* is set to the current time. The ETag is a hash over all note attributes
3939
* (except content, see below).
4040
*
4141
* But in order to further speed up synchronization, the content is not
42-
* compared every time (this would be very expensive!). Instead, a file hook
43-
* (see `OCA\Notes\NotesHook`) deletes the meta entry on every file change. As
44-
* a consequence, a new entry in `note_meta` is created on next
42+
* compared every time (this would be very expensive!). Instead, a file event
43+
* listener invalidates the meta entry on every relevant file change. As a
44+
* consequence, a new entry in `notes_meta` is created on the next
4545
* synchronization.
4646
*
4747
* Hence, instead of using the real content for generating the note's ETag, it
48-
* uses a "content ETag" which is a hash over the content. Additionaly to the
49-
* file hooks, this "content ETag" is updated if Nextcloud's "file ETag" has
48+
* uses a "content ETag" which is a hash over the content. Additionally to the
49+
* file events, this "content ETag" is updated if Nextcloud's "file ETag" has
5050
* changed (but again, the "file ETag" is just an indicator, since it is not a
5151
* hash over the content).
5252
*

0 commit comments

Comments
 (0)