[PATCHES] Three patches for image handling

Robert Helling helling at atdotde.de
Sat Jan 9 07:39:34 PST 2016


Hi,

I started into the image loading logic. The first patch just simplifies the logic a bit, the second add an attempt if we do not find the image locally to download it from the cloud server (the URL being currently https://cloud.subsurface-divelog.org/images/HASHVALUE). The last patch adds the possibility to upload images to that server: When we successfully loaded a local file we check if the cloud server knows about an image with that hash and if not uploads it via the  HTTP PUT method.

Nothing so far has been implemented on the server side. So this is totally untested. These patches should not break anything but being conservative, they might be considered a RFC.

Best
Robert

-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: 0001-Simplify-image-hashing-logic.txt
URL: <http://lists.subsurface-divelog.org/pipermail/subsurface/attachments/20160109/53b84fc1/attachment-0003.txt>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: 0002-If-all-else-fails-try-loading-images-from-cloud-server.txt
URL: <http://lists.subsurface-divelog.org/pipermail/subsurface/attachments/20160109/53b84fc1/attachment-0004.txt>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: 0003-Upload-images-to-cloud-server.txt
URL: <http://lists.subsurface-divelog.org/pipermail/subsurface/attachments/20160109/53b84fc1/attachment-0005.txt>
-------------- next part --------------


-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 496 bytes
Desc: Message signed with OpenPGP using GPGMail
URL: <http://lists.subsurface-divelog.org/pipermail/subsurface/attachments/20160109/53b84fc1/attachment-0001.sig>


More information about the subsurface mailing list