Uploaded image for project: 'DSpace'
  1. DSpace
  2. DS-264

XMLUI misses logging UsageEvent on requests fulfilled from the cache (with proposed fix)

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 1.5.2, 1.6.0
    • Fix Version/s: 1.6.0
    • Component/s: XMLUI
    • Labels:
      None
    • Environment:
      MacOSX/java1.5/oracle, 1.5.2
    • Attachments:
      1
    • Comments:
      2
    • Documentation Status:
      Needed

      Description

      The calls to generate UsageEvents in the XMLUI are in the addBody() method, which never get called when the request is satisfied out of cocoon's cache. In a quiescent test environment this resulted in only one usage event for each distinct Collection, Community, and Item, no matter whether it was requested by different logged-in users or from different IP addresses. Even in a busy production environment, it would probably miss counting many of the requests for a popular Item.

      The patch moves UsageEvent calls up to the getValidity method, which also calls the system log that seems to reflect activity accurately. Someone who really knows the XMLUI internals ought to check it over, though.

      Also, the UsageEvent in CommunityViewer.java was incorrectly identifying the object type as an ITEM; the patch fixes that too.

        Attachments

          Activity

            People

            Assignee:
            mdiggory Mark Diggory
            Reporter:
            lcs Larry Stone
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: