Class StatisticsServiceRemoteImpl

java.lang.Object
org.opencastproject.serviceregistry.api.RemoteBase
org.opencastproject.statistics.remote.StatisticsServiceRemoteImpl
All Implemented Interfaces:
StatisticsService

@Path("/statistics") public class StatisticsServiceRemoteImpl extends RemoteBase implements StatisticsService
A proxy to a remote series service.
  • Constructor Details

    • StatisticsServiceRemoteImpl

      public StatisticsServiceRemoteImpl()
  • Method Details

    • getProviders

      public Set<StatisticsProvider> getProviders()
      Specified by:
      getProviders in interface StatisticsService
      Returns:
      All active providers.
    • getProviders

      public Set<StatisticsProvider> getProviders(ResourceType resourceType)
      Specified by:
      getProviders in interface StatisticsService
      Parameters:
      resourceType - The resource type.
      Returns:
      All active providers for the given resource type.
    • getProvider

      public Optional<StatisticsProvider> getProvider(String providerId)
      Specified by:
      getProvider in interface StatisticsService
      Parameters:
      providerId - The provider id.
      Returns:
      Optionally return the provider with the given id (if any).
    • getTimeSeriesData

      public TimeSeries getTimeSeriesData(StatisticsProvider provider, String resourceId, Instant from, Instant to, DataResolution resolution, ZoneId zoneId)
      Description copied from interface: StatisticsService
      Get time series statistics data from the given Provider.
      Specified by:
      getTimeSeriesData in interface StatisticsService
      Parameters:
      provider - The provider to retrieve statistics from.
      resourceId - The id to access the resource to get statistics for (e.g. episode Id, organization Id or series Id).
      from - The start date to calculate the statistics for.
      to - The end date to calculate the statistics for.
      resolution - The resolution to get the statistics with.
      zoneId - The timezone to use for date calculations.
      Returns:
      The time series data.
    • writeDuration

      public void writeDuration(String organizationId, String measurementName, String retentionPolicy, String organizationIdResourceName, String fieldName, TimeUnit temporalResolution, Duration duration)
      Description copied from interface: StatisticsService
      Write a duration to a statistics data base
      Specified by:
      writeDuration in interface StatisticsService
      Parameters:
      organizationId - Organization ID of the data point
      measurementName - Measurement name of the data point
      retentionPolicy - Retention policy of the data point
      organizationIdResourceName - Resource name for the organization
      fieldName - Field name to write
      temporalResolution - The temporal resolution to store it in
      duration - The actual duration to write
    • setTrustedHttpClient

      public void setTrustedHttpClient(TrustedHttpClient trustedHttpClient)
      Description copied from class: RemoteBase
      Sets the trusted http client
      Overrides:
      setTrustedHttpClient in class RemoteBase
      Parameters:
      trustedHttpClient -
    • setRemoteServiceManager

      public void setRemoteServiceManager(ServiceRegistry serviceRegistry)
      Description copied from class: RemoteBase
      Sets the remote service manager.
      Overrides:
      setRemoteServiceManager in class RemoteBase
      Parameters:
      serviceRegistry -