Gaia/Contacts/Data Refactor: Difference between revisions

Jump to navigation Jump to search
Line 88: Line 88:
This array will usually has a length of one element only. If it contains more than one element, it means that the contact has been passively merged and so the Contact Consumer can safely ignore the rest of the elements of the array because they contain IDs for mozContacts that are an exact copy of the one corresponding to the ID stored in the first position of the array.
This array will usually has a length of one element only. If it contains more than one element, it means that the contact has been passively merged and so the Contact Consumer can safely ignore the rest of the elements of the array because they contain IDs for mozContacts that are an exact copy of the one corresponding to the ID stored in the first position of the array.


The ''owner'' field of the object is the name of the datastore that contains the actual mozContact information the Contact Consumer is interested on. So the Contact Consumer needs to query this datastore with the value of the ''contactId'' field to obtain the mozContact information. Once it gets this information, it can store it locally in its indexedDB and repeat the process for each ID stored in the GCDS.
The ''owner'' field of the object is the name of the datastore that contains the actual mozContact information the Contact Consumer is interested on. So the Contact Consumer needs to query this datastore with the value of the ''contactId'' field to obtain the mozContact information. It is possible that the consumer has not enough privileges to access the provider's datastore. In that case, it should silently fail and continue with the next GCDS record. If it has access to the provider's datastore and once it gets the mozContact information it can store it locally in its indexedDB and repeat the process for each ID stored in the GCDS.


=== Local contact addition or modification ===
=== Local contact addition or modification ===
Line 94: Line 94:


=== External contact addition or modification ===
=== External contact addition or modification ===
[[File:Contactprovideraddmod.png|1000px|x800px]]
=== Contact consumer search ===
=== Contact consumer search ===
=== Contact Provider installation ===
=== Contact Provider installation ===


Confirmed users
483

edits

Navigation menu