Skip to content
Snippets Groups Projects
Unverified Commit a033cd04 authored by Ian Costanzo's avatar Ian Costanzo Committed by GitHub
Browse files

Merge pull request #2116 from Indicio-tech/feature/fix_record_loading_size

Fix multi-use invitation performance
parents 987cc0f0 67da623e
No related branches found
No related tags found
No related merge requests found
v0.8.0:
resave_records:
base_record_path:
- "aries_cloudagent.connections.models.conn_record.ConnRecord"
update_existing_records: false
v0.7.2:
resave_records:
base_record_path:
......
......@@ -174,6 +174,7 @@ class ConnRecord(BaseRecord):
"invitation_key",
"their_public_did",
"invitation_msg_id",
"state",
"their_role",
}
......@@ -322,11 +323,15 @@ class ConnRecord(BaseRecord):
invitation_key: The key on the originating invitation
initiator: Filter by the initiator value
"""
tag_filter = {"invitation_key": invitation_key}
tag_filter = {
"invitation_key": invitation_key,
"state": cls.State.INVITATION.rfc160,
}
post_filter = {"state": cls.State.INVITATION.rfc160}
if their_role:
post_filter["their_role"] = cls.Role.get(their_role).rfc160
tag_filter["their_role"] = cls.Role.get(their_role).rfc160
return await cls.retrieve_by_tag_filter(session, tag_filter, post_filter)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment