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

Agile Gadget doesn't work when using in Confluence or other Gadget containers

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Medium
    • 5.7.2
    • 5.6.8
    • Gadget

    Description

      When adding the GH agile gadget to a confluence page it will display one chart the first time it's being viewed, but it will fail for any consecutive attempts.
      Only after 2 hours it will work once and then stop to work again for two hours.

      This issue is due a missing NO-CACHE header on the response of the gadget resource which generates the image.
      Adding the header Cache-Control: NO-Cache will fix this problem.

      GreenhopperRessource.java (IMHO: java class should be renamed to GreenhopperResource)
      Line 129

      return !errors.isEmpty() ? createValidationResponse(errors) : Response.ok(new GHGadget(preferences)).cacheControl(com.pyxis.greenhopper.gadget.CacheControl.NO_CACHE).build();
      

      As part of this issue, I suggest you review all other responses which contain dynamic data and make sure they have the required NO-CACHE header.
      If no caching behavior is specified inside JIRA the response will not have any caching information, but when going through the gadget proxy it will add a default cache timeout of 2 hours. Which means these gadgets will stop to work in external gadget containers.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              fschmitz Felix Schmitz [Atlassian]
              Votes:
              2 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: