When a patch is rebased via the Gerrit graphical interface, it sends an event of type patchset-created to stream-events listener. The event has an uploader field which used to be the person doing the action, since Gerrit 2.8.1 the uploader field points to the patch author.
An example is change https://gerrit.wikimedia.org/r/#/c/109891/ . The change has been authored and is owned by untrusted user Tinaj1234, hence tests are not run. I have rebased patchset 3 to trigger the tests did not get triggered.
Looking at Zuul debug log for Gerrit events, the change structure is roughly:
change:
owner: name: Tinaj1234 project: mediawiki/core patchset: author: name: Tinaj1234 uploader: name: Tinaj1234 type: patchset-created uploader: name: Tinaj1234
The uploader field should have pointed to myself, aka hashar. That was the behavior before our switch to Gerrit 2.8.1.
For each type of event we had a field representing the authenticated person doing the action. The corresponding map is:
'patchset-created': 'uploader', 'draft-published': 'uploader', # Gerrit 2.5/2.6 'change-abandoned': 'abandoner', 'change-restored': 'restorer', 'change-merged': 'submitter', 'merge-failed': 'submitter', # Gerrit 2.5/2.6 'comment-added': 'author', 'ref-updated': 'submitter', 'reviewer-added': 'reviewer', # Gerrit 2.5/2.6
Aka for the event type 'patchset-created', the account that have done the action is mentioned in the 'uploader' field.
Version: wmf-deployment
Severity: normal
See Also:
http://code.google.com/p/gerrit/issues/detail?id=2493