contacts performance
Signed-off-by: andrey <motor4ik@gmail.com>
This commit is contained in:
parent
074a18c18f
commit
1bbebc9055
|
@ -7,7 +7,6 @@
|
|||
[status-im.chat.models.message-list :as message-list]
|
||||
[taoensso.timbre :as log]
|
||||
[status-im.ethereum.json-rpc :as json-rpc]
|
||||
[clojure.string :as string]
|
||||
[status-im.chat.models.pin-message :as models.pin-message]))
|
||||
|
||||
(defn cursor->clock-value
|
||||
|
@ -99,13 +98,12 @@
|
|||
(get-in db [:pagination-info chat-id :messages-initialized?])))
|
||||
(let [already-loaded-messages (get-in db [:messages chat-id])
|
||||
;; We remove those messages that are already loaded, as we might get some duplicates
|
||||
{:keys [all-messages new-messages senders]}
|
||||
{:keys [all-messages new-messages senders contacts]}
|
||||
(reduce (fn [{:keys [all-messages] :as acc}
|
||||
{:keys [message-id alias from]
|
||||
{:keys [message-id from]
|
||||
:as message}]
|
||||
(cond-> acc
|
||||
(and (not (string/blank? alias))
|
||||
(not (get-in db [:chats chat-id :users from])))
|
||||
(not (get-in db [:chats chat-id :users from]))
|
||||
(update :senders assoc from message)
|
||||
|
||||
(nil? (get all-messages message-id))
|
||||
|
@ -115,6 +113,7 @@
|
|||
(update :all-messages assoc message-id message)))
|
||||
{:all-messages already-loaded-messages
|
||||
:senders {}
|
||||
:contacts {}
|
||||
:new-messages []}
|
||||
messages)
|
||||
current-clock-value (get-in db [:pagination-info chat-id :cursor-clock-value])
|
||||
|
@ -134,7 +133,8 @@
|
|||
(assoc-in [:messages chat-id] all-messages)
|
||||
(update-in [:message-lists chat-id] message-list/add-many new-messages)
|
||||
(assoc-in [:pagination-info chat-id :all-loaded?]
|
||||
(empty? cursor)))})))
|
||||
(empty? cursor))
|
||||
(update :contacts/contacts merge contacts))})))
|
||||
|
||||
(fx/defn load-more-messages
|
||||
{:events [:chat.ui/load-more-messages]}
|
||||
|
|
|
@ -10,11 +10,11 @@
|
|||
[taoensso.timbre :as log]
|
||||
[status-im.chat.models.mentions :as mentions]
|
||||
[clojure.string :as string]
|
||||
[status-im.contact.db :as contact.db]
|
||||
[status-im.utils.types :as types]
|
||||
[status-im.ui.screens.chat.state :as view.state]
|
||||
[status-im.chat.models.loading :as chat.loading]
|
||||
[status-im.utils.platform :as platform]))
|
||||
[status-im.utils.platform :as platform]
|
||||
[status-im.utils.gfycat.core :as gfycat]))
|
||||
|
||||
(defn- message-loaded?
|
||||
[db chat-id message-id]
|
||||
|
@ -39,6 +39,9 @@
|
|||
{:events [:chat/add-senders-to-chat-users]}
|
||||
[{:keys [db]} messages]
|
||||
(reduce (fn [acc {:keys [chat-id alias name identicon from]}]
|
||||
(let [alias (if (string/blank? alias)
|
||||
(gfycat/generate-gfy from)
|
||||
alias)]
|
||||
(update-in acc [:db :chats chat-id :users] assoc
|
||||
from
|
||||
(mentions/add-searchable-phrases
|
||||
|
@ -46,7 +49,7 @@
|
|||
:name (or name alias)
|
||||
:identicon identicon
|
||||
:public-key from
|
||||
:nickname (get-in db [:contacts/contacts from :nickname])})))
|
||||
:nickname (get-in db [:contacts/contacts from :nickname])}))))
|
||||
{:db db}
|
||||
messages))
|
||||
|
||||
|
@ -56,14 +59,14 @@
|
|||
(or
|
||||
(= chat-id (chat-model/my-profile-chat-topic db))
|
||||
(when-let [pub-key (get-in db [:chats chat-id :profile-public-key])]
|
||||
(contact.db/added? db pub-key)))))
|
||||
(get-in db [:contacts/contacts pub-key :added])))))
|
||||
|
||||
(defn get-timeline-message [db chat-id message-js]
|
||||
(when (timeline-message? db chat-id)
|
||||
(data-store.messages/<-rpc (types/js->clj message-js))))
|
||||
|
||||
(defn add-message [{:keys [db] :as acc} message-js chat-id message-id cursor-clock-value]
|
||||
(let [{:keys [alias replace from clock-value] :as message}
|
||||
(let [{:keys [replace from clock-value] :as message}
|
||||
(data-store.messages/<-rpc (types/js->clj message-js))]
|
||||
(if (message-loaded? db chat-id message-id)
|
||||
;; If the message is already loaded, it means it's an update, that
|
||||
|
@ -83,8 +86,7 @@
|
|||
:cursor-clock-value clock-value)
|
||||
|
||||
;;conj sender for add-sender-to-chat-users
|
||||
(and (not (string/blank? alias))
|
||||
(not (get-in db [:chats chat-id :users from])))
|
||||
(not (get-in db [:chats chat-id :users from]))
|
||||
(update :senders assoc from message)
|
||||
|
||||
(not (string/blank? replace))
|
||||
|
|
|
@ -46,8 +46,7 @@
|
|||
(let [contact (-> (contact.db/public-key->contact
|
||||
(:contacts/contacts db)
|
||||
public-key)
|
||||
(assoc :last-updated now)
|
||||
(update :system-tags (fnil conj #{}) :contact/blocked))
|
||||
(assoc :last-updated now :blocked true))
|
||||
from-one-to-one-chat? (not (get-in db [:chats (:current-chat-id db) :group-chat]))]
|
||||
(fx/merge cofx
|
||||
{:db (-> db
|
||||
|
@ -66,8 +65,7 @@
|
|||
{:events [:contact.ui/unblock-contact-pressed]}
|
||||
[{:keys [db now] :as cofx} public-key]
|
||||
(let [contact (-> (get-in db [:contacts/contacts public-key])
|
||||
(assoc :last-updated now)
|
||||
(update :system-tags disj :contact/blocked))]
|
||||
(assoc :last-updated now :blocked false))]
|
||||
(fx/merge cofx
|
||||
{:db (-> db
|
||||
(update :contacts/blocked disj public-key)
|
||||
|
|
|
@ -48,13 +48,13 @@
|
|||
contacts))
|
||||
:dispatch-n (mapcat (fn [{:keys [public-key] :as contact}]
|
||||
(cond-> []
|
||||
(contact.db/added? contact)
|
||||
(:added contact)
|
||||
(conj [:start-profile-chat public-key])
|
||||
|
||||
(contact.db/removed? contact)
|
||||
(not (:added contact))
|
||||
(conj [:offload-messages constants/timeline-chat-id])
|
||||
|
||||
(contact.db/blocked? contact)
|
||||
(:blocked contact)
|
||||
(conj [::contact.block/contact-blocked contact chats])))
|
||||
contacts)})
|
||||
|
||||
|
@ -88,8 +88,7 @@
|
|||
(and nickname (not (string/blank? nickname)))
|
||||
(assoc :nickname nickname)
|
||||
:else
|
||||
(update :system-tags
|
||||
(fnil #(conj % :contact/added) #{})))]
|
||||
(assoc :added true))]
|
||||
(fx/merge cofx
|
||||
{:db (dissoc db :contacts/new-identity)
|
||||
:dispatch-n [[:start-profile-chat public-key]
|
||||
|
@ -100,15 +99,12 @@
|
|||
(fx/defn remove-contact
|
||||
"Remove a contact from current account's contact list"
|
||||
{:events [:contact.ui/remove-contact-pressed]}
|
||||
[{:keys [db] :as cofx} {:keys [public-key] :as contact}]
|
||||
(let [new-contact (update contact
|
||||
:system-tags
|
||||
(fnil #(disj % :contact/added) #{}))]
|
||||
{:db (assoc-in db [:contacts/contacts public-key] new-contact)
|
||||
[{:keys [db]} {:keys [public-key]}]
|
||||
{:db (assoc-in db [:contacts/contacts public-key :added] false)
|
||||
::json-rpc/call [{:method "wakuext_removeContact"
|
||||
:params [public-key]
|
||||
:on-success #(log/debug "contact removed successfully")}]
|
||||
:dispatch [:offload-messages constants/timeline-chat-id]}))
|
||||
:dispatch [:offload-messages constants/timeline-chat-id]})
|
||||
|
||||
(fx/defn create-contact
|
||||
"Create entry in contacts"
|
||||
|
|
|
@ -12,8 +12,7 @@
|
|||
{:alias alias
|
||||
:name alias
|
||||
:identicon (identicon/identicon public-key)
|
||||
:public-key public-key
|
||||
:system-tags #{}}))
|
||||
:public-key public-key}))
|
||||
|
||||
(defn public-key->contact
|
||||
[contacts public-key]
|
||||
|
@ -79,8 +78,6 @@
|
|||
([db public-key]
|
||||
(added? (get-in db [:contacts/contacts public-key]))))
|
||||
|
||||
(def removed? (complement added?))
|
||||
|
||||
(defn blocked?
|
||||
([{:keys [system-tags]}]
|
||||
(contains? system-tags :contact/blocked))
|
||||
|
@ -113,27 +110,25 @@
|
|||
(defn active?
|
||||
"Checks that the user is added to the contact and not blocked"
|
||||
([contact]
|
||||
(and (added? contact)
|
||||
(not (blocked? contact))))
|
||||
(and (:added contact)
|
||||
(not (:blocked contact))))
|
||||
([db public-key]
|
||||
(active? (get-in db [:contacts/contacts public-key]))))
|
||||
|
||||
(defn enrich-contact
|
||||
([contact] (enrich-contact contact nil nil))
|
||||
([{:keys [system-tags public-key] :as contact} setting own-public-key]
|
||||
(let [added? (contains? system-tags :contact/added)]
|
||||
([{:keys [added public-key] :as contact} setting own-public-key]
|
||||
(cond-> (-> contact
|
||||
(dissoc :ens-verified-at :ens-verification-retries)
|
||||
(assoc :pending? (pending? contact)
|
||||
:blocked? (blocked? contact)
|
||||
(assoc :blocked? (:blocked contact)
|
||||
:active? (active? contact)
|
||||
:added? added?)
|
||||
:added? added)
|
||||
(multiaccounts/contact-with-names))
|
||||
(and setting (not= public-key own-public-key)
|
||||
(or (= setting constants/profile-pictures-visibility-none)
|
||||
(and (= setting constants/profile-pictures-visibility-contacts-only)
|
||||
(not added?))))
|
||||
(dissoc :images)))))
|
||||
(not added))))
|
||||
(dissoc :images))))
|
||||
|
||||
(defn enrich-contacts
|
||||
[contacts profile-pictures-visibility own-public-key]
|
||||
|
@ -145,7 +140,7 @@
|
|||
(defn get-blocked-contacts
|
||||
[contacts]
|
||||
(reduce (fn [acc {:keys [public-key] :as contact}]
|
||||
(if (blocked? contact)
|
||||
(if (:blocked contact)
|
||||
(conj acc public-key)
|
||||
acc))
|
||||
#{}
|
||||
|
|
|
@ -19,8 +19,7 @@
|
|||
:identicon "photo1",
|
||||
:last-online 0,
|
||||
:public-key
|
||||
"0x04985040682b77a32bb4bb58268a0719bd24ca4d07c255153fe1eb2ccd5883669627bd1a092d7cc76e8e4b9104327667b19dcda3ac469f572efabe588c38c1985f"
|
||||
:system-tags #{}}}
|
||||
"0x04985040682b77a32bb4bb58268a0719bd24ca4d07c255153fe1eb2ccd5883669627bd1a092d7cc76e8e4b9104327667b19dcda3ac469f572efabe588c38c1985f"}}
|
||||
current-multiaccount {:last-updated 0,
|
||||
:signed-up? true,
|
||||
:sharing-usage-data? false,
|
||||
|
@ -36,8 +35,7 @@
|
|||
:identicon "generated"
|
||||
:alias "generated"
|
||||
:admin? true
|
||||
:public-key "0x04fcf40c526b09ff9fb22f4a5dbd08490ef9b64af700870f8a0ba2133f4251d5607ed83cd9047b8c2796576bc83fa0de23a13a4dced07654b8ff137fe744047917"
|
||||
:system-tags #{}}
|
||||
:public-key "0x04fcf40c526b09ff9fb22f4a5dbd08490ef9b64af700870f8a0ba2133f4251d5607ed83cd9047b8c2796576bc83fa0de23a13a4dced07654b8ff137fe744047917"}
|
||||
{:alias "User A"
|
||||
:identicon "photo2"
|
||||
:public-key "0x048a2f8b80c60f89a91b4c1316e56f75b087f446e7b8701ceca06a40142d8efe1f5aa36bd0fee9e248060a8d5207b43ae98bef4617c18c71e66f920f324869c09f"}
|
||||
|
@ -45,5 +43,4 @@
|
|||
:name "User B"
|
||||
:identicon "photo1"
|
||||
:last-online 0
|
||||
:public-key "0x04985040682b77a32bb4bb58268a0719bd24ca4d07c255153fe1eb2ccd5883669627bd1a092d7cc76e8e4b9104327667b19dcda3ac469f572efabe588c38c1985f"
|
||||
:system-tags #{}}]))))))
|
||||
:public-key "0x04985040682b77a32bb4bb58268a0719bd24ca4d07c255153fe1eb2ccd5883669627bd1a092d7cc76e8e4b9104327667b19dcda3ac469f572efabe588c38c1985f"}]))))))
|
||||
|
|
|
@ -5,32 +5,22 @@
|
|||
[taoensso.timbre :as log]))
|
||||
|
||||
(defn <-rpc [contact]
|
||||
(-> contact
|
||||
(update :systemTags
|
||||
#(reduce (fn [acc s]
|
||||
(conj acc (keyword (subs s 1))))
|
||||
#{}
|
||||
%))
|
||||
(clojure.set/rename-keys {:id :public-key
|
||||
(clojure.set/rename-keys contact {:id :public-key
|
||||
:ensVerifiedAt :ens-verified-at
|
||||
:ensVerified :ens-verified
|
||||
:ensVerificationRetries :ens-verification-retries
|
||||
:lastENSClockValue :last-ens-clock-value
|
||||
:systemTags :system-tags
|
||||
:lastUpdated :last-updated
|
||||
:localNickname :nickname})))
|
||||
:localNickname :nickname}))
|
||||
|
||||
(defn ->rpc [contact]
|
||||
(-> contact
|
||||
(update :system-tags #(mapv str %))
|
||||
(clojure.set/rename-keys {:public-key :id
|
||||
(clojure.set/rename-keys contact {:public-key :id
|
||||
:ens-verified :ensVerified
|
||||
:ens-verified-at :ensVerifiedAt
|
||||
:last-ens-clock-value :lastENSClockValue
|
||||
:ens-verification-retries :ensVerificationRetries
|
||||
:system-tags :systemTags
|
||||
:last-updated :lastUpdated
|
||||
:nickname :localNickname})))
|
||||
:nickname :localNickname}))
|
||||
|
||||
(fx/defn fetch-contacts-rpc
|
||||
[_ on-success]
|
||||
|
|
|
@ -7,33 +7,26 @@
|
|||
:address "address"
|
||||
:name "name"
|
||||
:identicon "identicon"
|
||||
:last-updated 1
|
||||
:system-tags #{:a :b}}
|
||||
:last-updated 1}
|
||||
expected-contact {:id "pk"
|
||||
:address "address"
|
||||
:name "name"
|
||||
:identicon "identicon"
|
||||
|
||||
:lastUpdated 1
|
||||
:systemTags #{":a" ":b"}}]
|
||||
:lastUpdated 1}]
|
||||
(testing "->rpc"
|
||||
(is (= expected-contact (update
|
||||
(c/->rpc contact)
|
||||
:systemTags
|
||||
#(into #{} %)))))))
|
||||
(is (= expected-contact (c/->rpc contact))))))
|
||||
|
||||
(deftest contact<-rpc
|
||||
(let [contact {:id "pk"
|
||||
:address "address"
|
||||
:name "name"
|
||||
:identicon "identicon"
|
||||
:lastUpdated 1
|
||||
:systemTags [":a" ":b"]}
|
||||
:lastUpdated 1}
|
||||
expected-contact {:public-key "pk"
|
||||
:address "address"
|
||||
:name "name"
|
||||
:identicon "identicon"
|
||||
:last-updated 1
|
||||
:system-tags #{:a :b}}]
|
||||
:last-updated 1}]
|
||||
(testing "<-rpc"
|
||||
(is (= expected-contact (c/<-rpc contact))))))
|
||||
|
|
|
@ -6,14 +6,14 @@
|
|||
:address "2f88d65f3cb52605a54a833ae118fb1363acccd2"
|
||||
:name "Darkviolet Lightgreen Halcyon"
|
||||
:identicon "data:image/png;base64iVBORw0KGgoAAAANSUhEUgAAACgAAAAoCAMAAAC7IEhfAAADAFBMVEX///+M2KwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA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AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAY5UBARL8TK8AAAAASUVORK5CYII="
|
||||
:system-tags #{:contact/added}
|
||||
:added true
|
||||
:last-online 0
|
||||
:public-key "0x04d6e56a475cd35f512d6ce0bf76c2c2af435c85ff48c2b9bdefd129f620e051a436f50961eae5717b2a750e59c3f5b60647d927da46d0b8b11621640b5678fc24"}
|
||||
{:last-updated 1547271764000
|
||||
:address "b267ff8336ac10b3a1986c04a70ff91fb03d0b78"
|
||||
:name "rv"
|
||||
:identicon "data:image/png;base64iVBORw0KGgoAAAANSUhEUgAAACgAAAAoCAMAAAC7IEhfAAADAFBMVEX////VjNgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA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AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA6IYA4bRtf+EAAAAASUVORK5CYII="
|
||||
:system-tags #{:contact/added}
|
||||
:added true
|
||||
:last-online 0
|
||||
:public-key "0x043ae31038ff45a31b096a91d3f8290e079366fbbae76a00fbbd349cd0e5b8d7598965d206772ec4504f68908649a08383cdc51a52cdae5e9ccc744ace4d37020f"}])
|
||||
|
||||
|
|
|
@ -1267,7 +1267,7 @@
|
|||
|
||||
(defn filter-selected-contacts
|
||||
[selected-contacts contacts]
|
||||
(filter #(contact.db/added? (contacts %)) selected-contacts))
|
||||
(filter #(:added (contacts %)) selected-contacts))
|
||||
|
||||
(re-frame/reg-sub
|
||||
:selected-contacts-count
|
||||
|
@ -2200,7 +2200,7 @@
|
|||
(fn [contacts]
|
||||
(->> contacts
|
||||
(filter (fn [[_ contact]]
|
||||
(contact.db/blocked? contact)))
|
||||
(:blocked contact)))
|
||||
(contact.db/sort-contacts))))
|
||||
|
||||
(re-frame/reg-sub
|
||||
|
@ -2253,7 +2253,7 @@
|
|||
(fn [[_ identity] _]
|
||||
[(re-frame/subscribe [:contacts/contact-by-identity identity])])
|
||||
(fn [[contact] _]
|
||||
(contact.db/added? contact)))
|
||||
(:added contact)))
|
||||
|
||||
(re-frame/reg-sub
|
||||
:contacts/contact-two-names-by-identity
|
||||
|
@ -2301,8 +2301,7 @@
|
|||
:contacts/all-contacts-not-in-current-chat
|
||||
:<- [::query-current-chat-contacts remove]
|
||||
(fn [contacts]
|
||||
(->> contacts
|
||||
(filter contact.db/added?))))
|
||||
(filter :added contacts)))
|
||||
|
||||
(re-frame/reg-sub
|
||||
:contacts/current-chat-contacts
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
"_comment": "Instead use: scripts/update-status-go.sh <rev>",
|
||||
"owner": "status-im",
|
||||
"repo": "status-go",
|
||||
"version": "v0.89.2",
|
||||
"commit-sha1": "51493d61bdb71cbac06acbd120d23f434082cfa4",
|
||||
"src-sha256": "080rally5qzv9hji753whx409m6ydl1g184s1myc4xr9fwk1hd6d"
|
||||
"version": "v0.89.4",
|
||||
"commit-sha1": "5e83d8e95e38e99ab76d236a28f959af9e93c27f",
|
||||
"src-sha256": "01zqrbqgvsrc55xs3qd8wwcvswqvl7i9xkw5ihkzsp924s326m15"
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue