Hi Jens,

The Attachments directory is a content-addressable store. Attachments are 
> named by their SHA-1 digests, and any attachments with the same contents in 
> a database (even if they have different filenames or types) will be stored 
> as the same file. That should make it clear why attachment files should 
> never be modified!


Interesting. So if I allow the user to say, double-click on an attachment 
to view it in Preview (for say a PDF file), then they make a change to the 
file such as mark it up and then save it, what would happen in CBL? A user 
could theoretically just navigate directly to the file and edit it too. I 
couldn't stop that from happening. Would the sync system still push an 
update to the gateway with the changes?

Also, can you have multiple attachments with the same name? Currently my 
attachments are stored in separate folders, so you can have the same file 
name attached, but in different folders. But I'm seriously thinking about 
using CB attachments because then I don't have to worry about syncing file 
attachments independently of the database syncing.

Thanks!

Brendan

 


-- 
You received this message because you are subscribed to the Google Groups 
"Couchbase Mobile" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/mobile-couchbase/05b3b0d0-6010-413d-9b44-f9c88f1da2d0%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to