Announcement

  •  » Requests
  •  » album synchronization (php) and md5 reset

#1 2024-01-13 12:46:20

fabien35235
Member
2024-01-13
3

album synchronization (php) and md5 reset

Hello piwigo team.

Would it be possible to implement the following feature:
---------------------------------------------------------------------
When an album is synchronized through the management interface,
Then, if a file has been updated, the md5 checksum is deleted

The current behavior is that the 'lastmodified' is set to the new last modification time of the file,
but the md5 is kept unchanged.

How to do it:
---------------
When the album is synchronized,
if lastmodified needs to be updated,
then set md5 to null


Why this is useful
----------------------
Scenario 1:

a picture is edited in place on the piwigo storage,
the album is synchronized,
So, the picture  metadata is up to date

But the md5 checksum is now obsolete, therefore useless.
Furthermore, there is no way to know that the md5 is wrong, either by looking at the file or the database

Scenario 2:

More generally speaking, there is no simple way to verify that the md5 are correct,
except to compute the md5 again, which is very costly for large databases (mine has 80k pictures...)

If this feature is implemented,
any tool can compare lastmodified and the file last-modification-date'

By the way, the thumbnails are also obsolete,
but this can be checked by comparing their date with the picture date,
so any tool can verify this and compute the new thumbnails


How to verify the behavior
---------------------------------
Choose a picture with a md5
Look at md5 and lastmodified with phpMyAdmin
Modify the corresponding file in the picture album: its last modification time, as known by OS, is updated.
perform an album synchronization of the enclosing directory
(ie. https://192.168.1.16/piwigo/admin.php?p … amp;site=1
directories + folders = Y
metadata of pictures already synchronized = Y
simulaiton = N
look into subfolders = Y)
Look at md5 and lastmodified with phpMyAdmin:
md5 is not modified
lastmodified is updated

Offline

 
  •  » Requests
  •  » album synchronization (php) and md5 reset

Board footer

Powered by FluxBB

github twitter newsletter Donate Piwigo.org © 2002-2024 · Contact