Uploaded image for project: 'Jira Software Data Center'
  1. Jira Software Data Center
  2. JSWSERVER-20162

IssueLinkCreatedEvent is fired before the Edit Issue process is completed

    XMLWordPrintable

Details

    • Bug
    • Resolution: Unresolved
    • Low
    • None
    • 7.12.3
    • REST API
    • None

    Description

      Issue Summary

      On plugin development, IssueLinkCreatedEvent is fired before the Edit Issue process is completed.

      The listener is to copy a value from a custom field (Field A) of the linked issue to the linking issue.

      Environment

      -

      Steps to Reproduce

      1. Set up a listener:
            @EventListener
            public void issueLinkCreatedEvent(IssueLinkCreatedEvent issueEvent) {
                Issue sourceIssue = issueEvent.getIssueLink().getSourceObject();
                Issue destinationIssue = issueEvent.getIssueLink().getDestinationObject();
                
                someService.copyField(sourceIssue, destinationIssue);
            }
        
      2. Create a new issue.
      3. Edit the issue and link an Epic.
      4. Let's say the Field A of:
        • the linked Epic has a value of Value A and
        • this newly-created issue has a value of Value B
      5. Save the Edit Issue.
      6. The listener captured the event and copy Value A from the Epic to the newly-created issue.
        Note that the Edit Issue process hasn't completed yet.
      7. Once the Edit Issue process completed, the Value B in the Edit Screen overwrite the Value A copied earlier by the listener.

      Expected Results

      The IssueLinkCreatedEvent is expected to fire after the Edit Issue process is completed.

      Actual Results

      The IssueLinkCreatedEvent is to fire before the Edit Issue process is completed.

      Notes

      -

      Workaround

      Currently there is no known workaround for this behavior. A workaround will be added here when available

      Attachments

        Activity

          People

            Unassigned Unassigned
            bkek Benz Kek (Inactive)
            Votes:
            14 Vote for this issue
            Watchers:
            8 Start watching this issue

            Dates

              Created:
              Updated: