プロフィール同期化

There are two types of profiles. The one for the current account and the ones from contacts. As this vCard contains data, such as the avatar (the profile picture) and the display name, it should be synced as soon as possible. But it must be only sent when required to avoid unnecessary data transmissions. The format used to store the profiles is a vCard (https://datatracker.ietf.org/doc/html/rfc6350).

保存されたプロフィールはどこですか?

自動

It is in the ${idPath_}/profile.vcf e.g.: .local/share/jami/xxxxxx/profile.vcf file on GNU/Linux.

連絡先

Because this logic is still managed per client, it depends on the client. However, on Desktop, this is unified and stored in: ${idPath_}/profiles/${base64(uri)}.vcf

プロフィールが送信されたとき

発信

At the beginning of a call, generally the client sends the vCard. However, this method should be removed in favor of the other located in the daemon.

連絡先のデバイスに送信する

When connecting to new devices, a SIP or a sync channel is opened. When this channel is ready, we check if we need to send the profile. To do this, the hash of the profile is compared to the one in the cache (${cacheDir}/${accId}/vcard/sha3 like ~/.cache/jami/xxxxx/vcard/sha3on GNU/Linux, and the file ${cacheDir}/${accId}/vcard/deviceId is checked). cf. JamiAccount::needToSendProfile(). If not present, the profile of the account is sent. Typically, the name of the channel will be vcard://xxx where the issuer is the one sending the profile.

Multiple devices

If the profile is sent and the device is from the same account, conversations are checked and we send profiles of all members. The channel name will be ${conversationId}/profile/${memberUri}.vcf. Behavior tested in daemon/test/unitTest/syncHistory/syncHistory.cpp