[TIME-109] Getting wrong user's details in portlet

Issue #109 resolved
Andriy Zhdanov created an issue

This plugin is exactly what a bunch of users have just started asking me for to support their new working practices, thanks so much!

I'm having issues with the portlet though. If add the Time Sheet portlet to my dashboard, it displays the hours worked by another user. If I edit the configuration and specify my user name in the Show Entries Created By User field, then it shows my details. If I then remove my name it then reverts to showing the other user's details. We want to use this portlet on shared dashboards, so getting every user to specify their own name in that field is not an option.

Now, I know that 2.0 of the plugin is documented to work with JIRA 4.1, and not the JIRA 4.0.1 that I'm using, so that may be my problem right there. If so, just tell me, and I'll get the guys to use the reports, but not the portlet.

Thanks

By elgaz/Gary Bauer on Wed, 8 Sep 2010 07:30:09 -0700

Comments (6)

  1. Andriy Zhdanov reporter

    I tried to reproduce this and in my case when I don't put a username in the gadget's preferences I see an empty list. Although there are work log entries for the current user the gadget is empty. When I put a name of the user in preferences everything works fine.

    So seems like something works differently. But that's not a bug - as marked this plugin works with 4.1 and above. I'd suggest closing this one as won't fix.

    Gary you can still use the previous version. There are not functional dependencies except it uses a portlet instead of a gadget.

    By pniewiadomski on Mon, 27 Sep 2010 04:58:04 -0700

  2. Andriy Zhdanov reporter

    This behaviour is present also in JIRA 4.2 (I know, 2.0 is not certified for this version).
    Anyway, here are exact steps:

    1. Start JIRA
    2. Log in as user X
    3. Add portlet to the dashboard
    4. Log in as user Y
    5. Add portlet to the dashboard - it will be portlet for user X

    By dodok1 on Fri, 22 Oct 2010 08:02:48 -0700

  3. Andriy Zhdanov reporter

    This is definitely bug related to gadget response caching. As there is by default 60 minutes caching, all requests with empty username are considered the same, regardless of user identity.

    Therefore are results unpredictable - used is identity of the first user used expired request.

    Attached is the workaround - no caching at all.

    By dodok1 on Thu, 4 Nov 2010 05:58:34 -0700

  4. Andriy Zhdanov reporter

    I've just added this patch: Committed revision 155603.

    Other scenario for this is when just logged work done does not appear in timesheet summary (gadget). I've just noticed that 'Assigned to me' gadget has no such problem (an issue created appears immediately) - I guess this is due to configuration option 'Refresh' set to 0, however this option may also mean automatic gadget refresh periodically (this is more natural for gadgets).

    Note, fix will not take into effect immediately, but after last cache expire (in an hour).

    Thank you Jozef for the patch! And I would really appreciate more light on gadget caching

    By azhdanov on Thu, 4 Nov 2010 08:06:10 -0700

  5. Andriy Zhdanov reporter

    Andrew, when will be there a new version with this patch applied? I can only find 2.0 on the webpage, which does seem to suffer from this bug.

    By eelcobrolman on Fri, 26 Nov 2010 05:53:14 -0800

  6. Andriy Zhdanov reporter

    Fix was applied 4-Nov, so if you still see the problem after re-installing, it must be something different.

    By azhdanov on Fri, 17 Dec 2010 14:23:12 -0800

  7. Log in to comment