Class DefaultHeartbeatManager

java.lang.Object
com.atlassian.confluence.impl.health.DefaultHeartbeatManager
All Implemented Interfaces:
HeartbeatManager

public class DefaultHeartbeatManager extends Object implements HeartbeatManager
Since:
8.0
  • Constructor Details

    • DefaultHeartbeatManager

      public DefaultHeartbeatManager(com.atlassian.vcache.VCacheFactory cacheFactory, ConfluenceUserResolver userResolver)
      Since:
      7.17
  • Method Details

    • getHeartbeatInterval

      public long getHeartbeatInterval()
      Description copied from interface: HeartbeatManager
      Fetches the time at which activities will expire
      Specified by:
      getHeartbeatInterval in interface HeartbeatManager
      Returns:
      The activity timeout in milliseconds
    • getUsersForActivity

      public List<com.atlassian.user.User> getUsersForActivity(String activityKey)
      Description copied from interface: HeartbeatManager
      Fetches a list of users who are participating in a specified activity
      Specified by:
      getUsersForActivity in interface HeartbeatManager
      Parameters:
      activityKey - The key used to identify the activity
      Returns:
      A list of users who are actively engaging in the specified activity
    • startActivity

      public void startActivity(String activityKey, String username)
      Description copied from interface: HeartbeatManager
      Adds a username as an active participant to the specified activity
      Specified by:
      startActivity in interface HeartbeatManager
      Parameters:
      activityKey - The key used to identify the activity
      username - The username of the user who is participating in the activity
    • startActivity

      public void startActivity(String activityKey, com.atlassian.user.User user)
      Description copied from interface: HeartbeatManager
      Adds a username as an active participant to the specified activity
      Specified by:
      startActivity in interface HeartbeatManager
      Parameters:
      activityKey - The key used to identify the activity
      user - The user who is participating in the activity
    • stopActivity

      public void stopActivity(String activityKey, String username)
      Description copied from interface: HeartbeatManager
      Remove a username from the active participants from the specified activity
      Specified by:
      stopActivity in interface HeartbeatManager
      Parameters:
      activityKey - The key used to identify the activity
      username - The username of the user who is participating in the activity
    • stopActivity

      public void stopActivity(String activityKey, com.atlassian.user.User user)
      Description copied from interface: HeartbeatManager
      Remove a user from the active participants from the specified activity
      Specified by:
      stopActivity in interface HeartbeatManager
      Parameters:
      activityKey - The key used to identify the activity
      user - The user who is participating in the activity