Bug 463022 - [api] add support for storing usernames on RepositoryPerson
Summary: [api] add support for storing usernames on RepositoryPerson
Status: RESOLVED FIXED
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: Mylyn (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows 7
: P3 enhancement (vote)
Target Milestone: 3.18   Edit
Assignee: Chris Poon CLA
QA Contact:
URL:
Whiteboard:
Keywords: contributed, noteworthy
Depends on:
Blocks:
 
Reported: 2015-03-24 19:25 EDT by Sam Davis CLA
Modified: 2015-11-30 14:55 EST (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Sam Davis CLA 2015-03-24 19:25:45 EDT
In various places we are comparing usernames from task data with the repository username, e.g. to determine whether to decorate comments, attachments, etc. with the PERSON_ME icon. We should create a method isCurrentUser(String) in AbstractRepositoryConnector so that connectors can override this comparison if the user ID stored in TaskData is not the same as the one used to log into the repository.
Comment 1 Sam Davis CLA 2015-10-23 13:58:04 EDT
I think this not needed. Connectors can override get/setRepositoryPerson in TaskAttributeMapper to create person's with the correct username.
Comment 2 Sam Davis CLA 2015-11-27 19:03:23 EST
Reopening because RepositoryPerson provides no way to store the username. We shouldn't store that in the id field, because that is what gets put in the task data. Some systems have two identifiers for a person: a human-readable username and an opaque ID which is stored in task data and in RepositoryPerson. We'll also need to add a method to RepositoryPerson to compare with a username.